From: Len Brown Date: Sat, 30 Jul 2005 03:31:17 +0000 (-0400) Subject: /home/lenb/src/to-linus branch 'acpi-2.6.12' X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=d6ac1a7910d22626bc77e73db091e00b810715f4;p=GitHub%2Fmt8127%2Fandroid_kernel_alcatel_ttab.git /home/lenb/src/to-linus branch 'acpi-2.6.12' --- d6ac1a7910d22626bc77e73db091e00b810715f4 diff --cc arch/i386/pci/irq.c index 766b104ac1a1,66e4149ef189..187350ccf864 --- a/arch/i386/pci/irq.c +++ b/arch/i386/pci/irq.c @@@ -56,36 -56,8 +56,37 @@@ struct irq_router_handler }; int (*pcibios_enable_irq)(struct pci_dev *dev) = NULL; + void (*pcibios_disable_irq)(struct pci_dev *dev) = NULL; +/* + * Check passed address for the PCI IRQ Routing Table signature + * and perform checksum verification. + */ + +static inline struct irq_routing_table * pirq_check_routing_table(u8 *addr) +{ + struct irq_routing_table *rt; + int i; + u8 sum; + + rt = (struct irq_routing_table *) addr; + if (rt->signature != PIRQ_SIGNATURE || + rt->version != PIRQ_VERSION || + rt->size % 16 || + rt->size < sizeof(struct irq_routing_table)) + return NULL; + sum = 0; + for (i=0; i < rt->size; i++) + sum += addr[i]; + if (!sum) { + DBG("PCI: Interrupt Routing Table found at 0x%p\n", rt); + return rt; + } + return NULL; +} + + + /* * Search 0xf0000 -- 0xfffff for the PCI IRQ Routing Table. */