Skip to contentSkip to conversation

invalid irqs accepted in serial pci driver

PATCH New Brian Murphy 1 participant 1 message Nov 4, 2002

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 invalid irqs accepted in serial pci driver

Hi,
the pci serial driver should not allow the configuration of
devices which return an irq of 255 - it is illegal according to the standard and means the device has not had an irq configured.

The patch adds rejection of these invalid devices.

/Brian

serial/8250_pci.c +3 -0
@@ -735,6 +735,9 @@
 	memset(&serial_req, 0, sizeof(serial_req));
 	for (k = 0; k < board->num_ports; k++) {
 		serial_req.irq = get_pci_irq(dev, board, k);
+		if (serial_req.irq == 255)
+			/* not initialised */
+			break;
 		if (get_pci_port(dev, board, &serial_req, k))
 			break;
 #ifdef SERIAL_DEBUG_PCI