drivers: base: fw: fix ret value when loading fw
authorZahari Doychev <zahari.doychev@linux.com>
Tue, 10 Mar 2015 09:45:40 +0000 (10:45 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 25 Mar 2015 13:49:10 +0000 (14:49 +0100)
commitef518cc8aa4427043efe21cb2f0799be9cb1d74d
tree10aa0001699947341c554464852d1029574f2404
parent46239902ecddd4690b6d800da258d0ab65a5cb78
drivers: base: fw: fix ret value when loading fw

When using the user mode helper to load firmwares the function _request_firmware
gets a positive return value from fw_load_from_user_helper and because of this
the firmware buffer is not assigned. This happens only when the return value
is zero. This patch fixes this problem in _request_firmware_load. When the
completion is ready the return value is set to zero.

Signed-off-by: Zahari Doychev <zahari.doychev@linux.com>
Cc: Ming Lei <ming.lei@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/base/firmware_class.c