From shanwei@cn.fujitsu.com Mon Jul 27 09:38:32 2009 From: Shan Wei Date: Fri, 24 Jul 2009 16:57:35 +0800 Subject: Staging: usb-ip: vhci_hdc:Fix the returned error value To: gregkh@suse.de Cc: devel@driverdev.osuosl.org Message-ID: <4A69777F.3040202@cn.fujitsu.com> 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 Signed-off-by: Greg Kroah-Hartman --- drivers/staging/usbip/vhci_hcd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- 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_h 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; } /*