Skip to content

Commit

Permalink
staging: comedi: jr3_pci: return 'result' from comedi_pci_enable inst…
Browse files Browse the repository at this point in the history
…ead of -EIO

Fix a smatch warning:
drivers/staging/comedi/drivers/jr3_pci.c:793 jr3_pci_auto_attach() info: why not propagate 'result' from comedi_pci_enable() instead of -5?

CC: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Yuanhan Liu authored and Greg Kroah-Hartman committed Nov 13, 2012
1 parent 9f488ba commit 4ecd622
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/staging/comedi/drivers/jr3_pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -703,7 +703,7 @@ static int __devinit jr3_pci_auto_attach(struct comedi_device *dev,

result = comedi_pci_enable(pcidev, "jr3_pci");
if (result < 0)
return -EIO;
return result;

dev->iobase = 1; /* the "detach" needs this */
devpriv->iobase = ioremap(pci_resource_start(pcidev, 0),
Expand Down

0 comments on commit 4ecd622

Please sign in to comment.