From: Jiri Slaby Date: Thu, 15 Jan 2009 13:30:34 +0000 (+0000) Subject: 8250_pci: add support for netmos 9835 IBM devices X-Git-Tag: v2.6.27.16~35 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=11673fed439117bc3d0f004dcaed8e45e7704ad4;p=thirdparty%2Fkernel%2Fstable.git 8250_pci: add support for netmos 9835 IBM devices commit 25cf9bc1fcb085daaeb82b09bab0fb3c40570887 upstream. Most of netmos 9835 hardware is handled by parport-serial. IBM introduces a device which doesn't have any parallel ports and have screwed subdevice PCI id (not corresponding to port numbers). Handle this device (9710:9835 1014:0299) properly. Signed-off-by: Jiri Slaby Signed-off-by: Andrew Morton Signed-off-by: Alan Cox Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/serial/8250_pci.c b/drivers/serial/8250_pci.c index fd0695b088a0f..1ab32b0c4345a 100644 --- a/drivers/serial/8250_pci.c +++ b/drivers/serial/8250_pci.c @@ -599,6 +599,10 @@ static int pci_netmos_init(struct pci_dev *dev) /* subdevice 0x00PS means

parallel, serial */ unsigned int num_serial = dev->subsystem_device & 0xf; + if (dev->subsystem_vendor == PCI_VENDOR_ID_IBM && + dev->subsystem_device == 0x0299) + return 0; + if (num_serial == 0) return -ENODEV; return num_serial; @@ -2846,6 +2850,10 @@ static struct pci_device_id serial_pci_tbl[] = { 0, pbn_b0_8_115200 }, + { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9835, + PCI_VENDOR_ID_IBM, 0x0299, + 0, 0, pbn_b0_bt_2_115200 }, + /* * These entries match devices with class COMMUNICATION_SERIAL, * COMMUNICATION_MODEM or COMMUNICATION_MULTISERIAL