diff options
author | Nishka Dasgupta <nishkadg.linux@gmail.com> | 2019-08-08 12:10:09 +0530 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-08-08 19:58:15 +0200 |
commit | 690407fdc9dd8103a78c251c59513646f1bed50d (patch) | |
tree | c3d6e22a6d13179ac23da40e3fb728370098c760 /drivers/staging/rtl8712/usb_intf.c | |
parent | 30d83c801d068abbfbb8f6f47e0c1f2a4a36e4b9 (diff) |
staging: rtl8712: init_drv_sw(): Change return values
Change return values of init_drv_sw from _SUCCESS and _FAIL to 0 and
-ENOMEM. Change return type from u8 to int to allow this.
Add a return variable to streamline return of error codes of called
functions.
Modify call site to check for non-zero return value instead of _FAIL.
Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190808064012.12661-7-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/rtl8712/usb_intf.c')
-rw-r--r-- | drivers/staging/rtl8712/usb_intf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/rtl8712/usb_intf.c b/drivers/staging/rtl8712/usb_intf.c index d0daae0b8299..ba1288297ee4 100644 --- a/drivers/staging/rtl8712/usb_intf.c +++ b/drivers/staging/rtl8712/usb_intf.c @@ -389,7 +389,7 @@ static int r871xu_drv_init(struct usb_interface *pusb_intf, } /* step 4. */ status = r8712_init_drv_sw(padapter); - if (status == _FAIL) + if (status) goto error; /* step 5. read efuse/eeprom data and get mac_addr */ { |