aboutsummaryrefslogtreecommitdiff
path: root/drivers/parport/parport_serial.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2008-12-23 16:23:23 +0100
committerIngo Molnar <mingo@elte.hu>2008-12-23 16:23:23 +0100
commit1ccedb7cdba6886939dd8b4c8f965a826f696e56 (patch)
tree0f5fc519a68faca5318c296315c9b6c502907056 /drivers/parport/parport_serial.c
parenta98f8fd24fb24fcb9a359553e64dd6aac5cf4279 (diff)
parent929096fe9ff1f4b3645cf3919527ab47e8d5e17c (diff)
Merge commit 'v2.6.28-rc9' into x86/apic
Diffstat (limited to 'drivers/parport/parport_serial.c')
-rw-r--r--drivers/parport/parport_serial.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/parport/parport_serial.c b/drivers/parport/parport_serial.c
index e2e95b36a60..101ed49a2d1 100644
--- a/drivers/parport/parport_serial.c
+++ b/drivers/parport/parport_serial.c
@@ -70,6 +70,8 @@ static int __devinit netmos_parallel_init(struct pci_dev *dev, struct parport_pc
* parallel ports and <S> is the number of serial ports.
*/
card->numports = (dev->subsystem_device & 0xf0) >> 4;
+ if (card->numports > ARRAY_SIZE(card->addr))
+ card->numports = ARRAY_SIZE(card->addr);
return 0;
}