aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/pci/irq.c39
-rw-r--r--include/linux/pci_ids.h3
2 files changed, 42 insertions, 0 deletions
diff --git a/arch/x86/pci/irq.c b/arch/x86/pci/irq.c
index d98c6b096f8e..c52150fdf82b 100644
--- a/arch/x86/pci/irq.c
+++ b/arch/x86/pci/irq.c
@@ -492,6 +492,26 @@ static int pirq_amd756_set(struct pci_dev *router, struct pci_dev *dev, int pirq
492 return 1; 492 return 1;
493} 493}
494 494
495/*
496 * PicoPower PT86C523
497 */
498static int pirq_pico_get(struct pci_dev *router, struct pci_dev *dev, int pirq)
499{
500 outb(0x10 + ((pirq - 1) >> 1), 0x24);
501 return ((pirq - 1) & 1) ? (inb(0x26) >> 4) : (inb(0x26) & 0xf);
502}
503
504static int pirq_pico_set(struct pci_dev *router, struct pci_dev *dev, int pirq,
505 int irq)
506{
507 unsigned int x;
508 outb(0x10 + ((pirq - 1) >> 1), 0x24);
509 x = inb(0x26);
510 x = ((pirq - 1) & 1) ? ((x & 0x0f) | (irq << 4)) : ((x & 0xf0) | (irq));
511 outb(x, 0x26);
512 return 1;
513}
514
495#ifdef CONFIG_PCI_BIOS 515#ifdef CONFIG_PCI_BIOS
496 516
497static int pirq_bios_set(struct pci_dev *router, struct pci_dev *dev, int pirq, int irq) 517static int pirq_bios_set(struct pci_dev *router, struct pci_dev *dev, int pirq, int irq)
@@ -721,6 +741,24 @@ static __init int amd_router_probe(struct irq_router *r, struct pci_dev *router,
721 return 1; 741 return 1;
722} 742}
723 743
744static __init int pico_router_probe(struct irq_router *r, struct pci_dev *router, u16 device)
745{
746 switch (device) {
747 case PCI_DEVICE_ID_PICOPOWER_PT86C523:
748 r->name = "PicoPower PT86C523";
749 r->get = pirq_pico_get;
750 r->set = pirq_pico_set;
751 return 1;
752
753 case PCI_DEVICE_ID_PICOPOWER_PT86C523BBP:
754 r->name = "PicoPower PT86C523 rev. BB+";
755 r->get = pirq_pico_get;
756 r->set = pirq_pico_set;
757 return 1;
758 }
759 return 0;
760}
761
724static __initdata struct irq_router_handler pirq_routers[] = { 762static __initdata struct irq_router_handler pirq_routers[] = {
725 { PCI_VENDOR_ID_INTEL, intel_router_probe }, 763 { PCI_VENDOR_ID_INTEL, intel_router_probe },
726 { PCI_VENDOR_ID_AL, ali_router_probe }, 764 { PCI_VENDOR_ID_AL, ali_router_probe },
@@ -732,6 +770,7 @@ static __initdata struct irq_router_handler pirq_routers[] = {
732 { PCI_VENDOR_ID_VLSI, vlsi_router_probe }, 770 { PCI_VENDOR_ID_VLSI, vlsi_router_probe },
733 { PCI_VENDOR_ID_SERVERWORKS, serverworks_router_probe }, 771 { PCI_VENDOR_ID_SERVERWORKS, serverworks_router_probe },
734 { PCI_VENDOR_ID_AMD, amd_router_probe }, 772 { PCI_VENDOR_ID_AMD, amd_router_probe },
773 { PCI_VENDOR_ID_PICOPOWER, pico_router_probe },
735 /* Someone with docs needs to add the ATI Radeon IGP */ 774 /* Someone with docs needs to add the ATI Radeon IGP */
736 { 0, NULL } 775 { 0, NULL }
737}; 776};
diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h
index 3948708c42ca..c88234d46506 100644
--- a/include/linux/pci_ids.h
+++ b/include/linux/pci_ids.h
@@ -829,6 +829,9 @@
829#define PCI_DEVICE_ID_UMC_UM8886BF 0x673a 829#define PCI_DEVICE_ID_UMC_UM8886BF 0x673a
830#define PCI_DEVICE_ID_UMC_UM8886A 0x886a 830#define PCI_DEVICE_ID_UMC_UM8886A 0x886a
831 831
832#define PCI_VENDOR_ID_PICOPOWER 0x1066
833#define PCI_DEVICE_ID_PICOPOWER_PT86C523 0x0002
834#define PCI_DEVICE_ID_PICOPOWER_PT86C523BBP 0x8002
832 835
833#define PCI_VENDOR_ID_MYLEX 0x1069 836#define PCI_VENDOR_ID_MYLEX 0x1069
834#define PCI_DEVICE_ID_MYLEX_DAC960_P 0x0001 837#define PCI_DEVICE_ID_MYLEX_DAC960_P 0x0001