summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Linville <linville@tuxdriver.com>2015-10-19 17:15:00 +0200
committerKalle Valo <kvalo@codeaurora.org>2015-10-28 19:55:47 +0100
commit989b8376f33721f7206dd058330da05972a71384 (patch)
treeb45e7e2848c75cb4978546d82ea0113789065313
parentairo: fix scan after SIOCSIWAP (airo_set_wap) (diff)
downloadlinux-989b8376f33721f7206dd058330da05972a71384.tar.xz
linux-989b8376f33721f7206dd058330da05972a71384.zip
orinoco_usb: return error in ezusb_probe when alloc_orinocodev fails
The current code exits after alloc_orinocodev, but fails to change the return value to something that indicates the failure. This patch changes the return value to -ENOMEM. https://bugzilla.kernel.org/show_bug.cgi?id=106181 Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
-rw-r--r--drivers/net/wireless/orinoco/orinoco_usb.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/wireless/orinoco/orinoco_usb.c b/drivers/net/wireless/orinoco/orinoco_usb.c
index 26a57d773d30..f2cd513d54b2 100644
--- a/drivers/net/wireless/orinoco/orinoco_usb.c
+++ b/drivers/net/wireless/orinoco/orinoco_usb.c
@@ -1576,6 +1576,7 @@ static int ezusb_probe(struct usb_interface *interface,
ezusb_hard_reset, NULL);
if (!priv) {
err("Couldn't allocate orinocodev");
+ retval = -ENOMEM;
goto exit;
}