Skip to contentSkip to conversation

USB OHCI IRQ on Digital PWS500

PATCH Peter De Schrijver 1 participant 1 message Oct 28, 2001 Alpha port

lore
Share & tools
lore
#0 lore raw

Hi,

The IRQ for the 82c693 USB function is not assigned correctly to an interrupt. This is because it's the only PCI device which has it's IRQ line connected to the 8259 interrupt controllers iso to the PYXIS. The following patch solves this problem.

Comments welcome,

Peter.

arch/alpha/kernel/sys_miata.c renamed from linux/arch/alpha/kernel/sys_miata.c +13 -0
@@ -176,6 +176,19 @@
 		{   -1,    -1,    -1,    -1,    -1},  /* IdSel 31,  PCI-PCI */
         };
 	const long min_idsel = 3, max_idsel = 20, irqs_per_slot = 5;
+	
+	/* the USB function of the 82c693 has it's interrupt connected to 
+           the 2nd 8259 controller. So we have to check for it first. */
+
+	if((slot == 7) && (PCI_FUNC(dev->devfn) == 3)) {
+		u8 irq=0;
+
+		if(pci_read_config_byte(pci_find_slot(dev->bus->number, dev->devfn & ~(7)), 0x40,&irq)!=PCIBIOS_SUCCESSFUL)
+			return -1;
+		else	
+			return irq;
+	}
+
 	return COMMON_TABLE_LOOKUP;
 }