summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIan Abbott <abbotti@mev.co.uk>2016-06-29 20:27:44 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-09-07 08:34:55 +0200
commitf231fe0fea6e7df74bb06ab1d84baf24c5998410 (patch)
tree0acfe27051777e62d3c0af50d5250370be09979c
parent9d04f44366ee632169750fec623eef1b50ff8503 (diff)
downloadlinux-stable-f231fe0fea6e7df74bb06ab1d84baf24c5998410.tar.gz
linux-stable-f231fe0fea6e7df74bb06ab1d84baf24c5998410.tar.bz2
linux-stable-f231fe0fea6e7df74bb06ab1d84baf24c5998410.zip
staging: comedi: daqboard2000: bug fix board type matching code
commit 80e162ee9b31d77d851b10f8c5299132be1e120f upstream. `daqboard2000_find_boardinfo()` is supposed to check if the DaqBoard/2000 series model is supported, based on the PCI subvendor and subdevice ID. The current code is wrong as it is comparing the PCI device's subdevice ID to an expected, fixed value for the subvendor ID. It should be comparing the PCI device's subvendor ID to this fixed value. Correct it. Fixes: 7e8401b23e7f ("staging: comedi: daqboard2000: add back subsystem_device check") Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/staging/comedi/drivers/daqboard2000.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/comedi/drivers/daqboard2000.c b/drivers/staging/comedi/drivers/daqboard2000.c
index a536a15c1d30..a91ea0235191 100644
--- a/drivers/staging/comedi/drivers/daqboard2000.c
+++ b/drivers/staging/comedi/drivers/daqboard2000.c
@@ -636,7 +636,7 @@ static const void *daqboard2000_find_boardinfo(struct comedi_device *dev,
const struct daq200_boardtype *board;
int i;
- if (pcidev->subsystem_device != PCI_VENDOR_ID_IOTECH)
+ if (pcidev->subsystem_vendor != PCI_VENDOR_ID_IOTECH)
return NULL;
for (i = 0; i < ARRAY_SIZE(boardtypes); i++) {