UPSTREAM: staging/gdm72xx: return PTR_ERR rather -ENOENT
authorDevendra Naga <devendra.aaru@gmail.com>
Thu, 12 Jul 2012 06:11:11 +0000 (11:56 +0545)
committerGerrit <chrome-bot@google.com>
Tue, 7 Aug 2012 19:05:26 +0000 (12:05 -0700)
return the error of filp_open rather returning -ENOENT.

Signed-off-by: Devendra Naga <devendra.aaru@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit d67030d215ac1ec13cab16467904c2a7265e1fbd)

Change-Id: I69f07846a453539bf5505083cc0ae66f801c6db9
Signed-off-by: Ben Chan <benchan@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/28217
Reviewed-by: Olof Johansson <olofj@chromium.org>
drivers/staging/gdm72xx/usb_boot.c

index c163bcc..fef290c 100644 (file)
@@ -174,7 +174,7 @@ int usb_boot(struct usb_device *usbdev, u16 pid)
        if (IS_ERR(filp)) {
                printk(KERN_ERR "Can't find %s.\n", img_name);
                set_fs(fs);
-               ret = -ENOENT;
+               ret = PTR_ERR(filp);
                goto restore_fs;
        }