|
|
|
|
|
|
|
|
|
|
xen-ia64-devel
Re: [Xen-ia64-devel] [Patch] Follow new interrupt deliver mechanism for
On Tue, 2006-12-19 at 20:01 +0900, DOI Tsunehisa wrote:
> --- a/unmodified_drivers/linux-2.6/platform-pci/platform-pci.c Mon Dec
> 18 10:56:34 2006 -0700
> +++ b/unmodified_drivers/linux-2.6/platform-pci/platform-pci.c Tue Dec
> 19 18:22:05 2006 +0900
> @@ -182,12 +182,16 @@ static int get_callback_irq(struct pci_d
> static int get_callback_irq(struct pci_dev *pdev)
> {
> #ifdef __ia64__
> - int irq;
> + int irq, rid;
> for (irq = 0; irq < 16; irq++) {
> if (isa_irq_to_vector(irq) == pdev->irq)
> return irq;
> }
> - return 0;
> + /* use Requester-ID as callback_irq */
> + /* RID: '<#bus(8)><#dev(5)><#func(3)>' (cf. PCI-Express spec) */
> + rid = ((pdev->bus->number & 0xff) << 8) | pdev->devfn;
> + printk(KERN_INFO DRV_NAME ":use Requester-ID(%04x) as callback irq\n",
> rid);
> + return rid | (1 << 31); /* with RID marker(MSB) */
Ok, except (1 << 31) needs to be defined in a common header somewhere
so it's not just a random magic bit. Thanks,
Alex
--
Alex Williamson HP Open Source & Linux Org.
_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel
|
|
|
|
|