summaryrefslogtreecommitdiffstats
path: root/drivers/staging/usbip
diff options
context:
space:
mode:
authorShan Wei <shanwei@cn.fujitsu.com>2009-07-24 16:57:35 +0800
committerGreg Kroah-Hartman <gregkh@suse.de>2009-09-15 12:02:05 -0700
commita7cd5829d8b3837755105d71f76a75cddf49003f (patch)
treeaa818b5123bddf7d49d40e0cd91282a508bce4f5 /drivers/staging/usbip
parent91c0f68ff6723cfa45aade768f89fac7c500cd0b (diff)
downloadlinux-a7cd5829d8b3837755105d71f76a75cddf49003f.tar.gz
linux-a7cd5829d8b3837755105d71f76a75cddf49003f.tar.bz2
linux-a7cd5829d8b3837755105d71f76a75cddf49003f.zip
Staging: usb-ip: vhci_hdc:Fix the returned error value
Compared with other drivers, the "ret" should be nagative and returned. But in vhci_hdc, it always return 0; I dont't use the driver, and I'm not familiar with the code. Hope the patch is helpful. Signed-off-by: Shan Wei <shanwei@cn.fujitsu.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/usbip')
-rw-r--r--drivers/staging/usbip/vhci_hcd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/usbip/vhci_hcd.c b/drivers/staging/usbip/vhci_hcd.c
index 114db8b26028..6e91fc2bd850 100644
--- a/drivers/staging/usbip/vhci_hcd.c
+++ b/drivers/staging/usbip/vhci_hcd.c
@@ -594,7 +594,7 @@ static int vhci_urb_enqueue(struct usb_hcd *hcd, struct urb *urb,
if (type != PIPE_CONTROL || !ctrlreq) {
dev_err(dev, "invalid request to devnum 0\n");
- ret = EINVAL;
+ ret = -EINVAL;
goto no_need_xmit;
}
@@ -653,7 +653,7 @@ no_need_unlink:
usb_hcd_giveback_urb(vhci_to_hcd(the_controller), urb, urb->status);
- return 0;
+ return ret;
}
/*