aboutsummaryrefslogtreecommitdiff
path: root/drivers/serial/icom.c
diff options
context:
space:
mode:
authorOlaf Hering <olaf@aepfle.de>2007-04-23 14:41:15 -0700
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-04-24 08:23:08 -0700
commit179fb0c726fa34a1ecbb9385a01c704babb9c0ab (patch)
tree164908cddcbb1426f1c0f320649186e334c01289 /drivers/serial/icom.c
parent91fcd412e957f433e9f1abeb0b1926dbeb66ca80 (diff)
do not truncate irq number for icom adapter
irq values are u32, not u8. Large irq numbers will be truncated, free_irq may free a different irq. Remove incorrectly sized struct member and use the one from pci_dev. Signed-off-by: Olaf Hering <olaf@aepfle.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/serial/icom.c')
-rw-r--r--drivers/serial/icom.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/serial/icom.c b/drivers/serial/icom.c
index 41431d0d551..d7aaf764849 100644
--- a/drivers/serial/icom.c
+++ b/drivers/serial/icom.c
@@ -1473,7 +1473,7 @@ static void icom_remove_adapter(struct icom_adapter *icom_adapter)
}
}
- free_irq(icom_adapter->irq_number, (void *) icom_adapter);
+ free_irq(icom_adapter->pci_dev->irq, (void *) icom_adapter);
iounmap(icom_adapter->base_addr);
icom_free_adapter(icom_adapter);
pci_release_regions(icom_adapter->pci_dev);
@@ -1539,7 +1539,6 @@ static int __devinit icom_probe(struct pci_dev *dev,
}
icom_adapter->base_addr_pci = pci_resource_start(dev, 0);
- icom_adapter->irq_number = dev->irq;
icom_adapter->pci_dev = dev;
icom_adapter->version = ent->driver_data;
icom_adapter->subsystem_id = ent->subdevice;
@@ -1570,7 +1569,7 @@ static int __devinit icom_probe(struct pci_dev *dev,
icom_port = &icom_adapter->port_info[index];
if (icom_port->status == ICOM_PORT_ACTIVE) {
- icom_port->uart_port.irq = icom_port->adapter->irq_number;
+ icom_port->uart_port.irq = icom_port->adapter->pci_dev->irq;
icom_port->uart_port.type = PORT_ICOM;
icom_port->uart_port.iotype = UPIO_MEM;
icom_port->uart_port.membase =