Commit f79dc167 authored by Amitoj Kaur Chawla's avatar Amitoj Kaur Chawla Committed by Greg Kroah-Hartman

staging: rtl8188eu: Remove unnecessary variables

Remove unnecessary variable that can be replaced with a single line
of code.

The semantic patch used to find this is:

// <smpl>
@@
expression ret;
@@
- if (ret) return ret;
- return 0;
+ return ret;

@@
local idexpression ret;
expression e;
@@
- ret = e;
- return ret;
+ return e;

@@
type T;
identifier i;
expression E;
@@
- T i = E;
 ... when != i

@@
type T;
identifier i;
@@
- T i;
 ... when != i
// </smpl>
Signed-off-by: default avatarAmitoj Kaur Chawla <amitoj1606@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent d743db9f
...@@ -190,7 +190,6 @@ int rtl88eu_download_fw(struct adapter *adapt) ...@@ -190,7 +190,6 @@ int rtl88eu_download_fw(struct adapter *adapt)
struct rtl92c_firmware_header *pfwheader = NULL; struct rtl92c_firmware_header *pfwheader = NULL;
u8 *pfwdata; u8 *pfwdata;
u32 fwsize; u32 fwsize;
int err;
if (request_firmware(&fw, fw_name, device)) { if (request_firmware(&fw, fw_name, device)) {
dev_err(device, "Firmware %s not available\n", fw_name); dev_err(device, "Firmware %s not available\n", fw_name);
...@@ -229,7 +228,5 @@ int rtl88eu_download_fw(struct adapter *adapt) ...@@ -229,7 +228,5 @@ int rtl88eu_download_fw(struct adapter *adapt)
_rtl88e_write_fw(adapt, pfwdata, fwsize); _rtl88e_write_fw(adapt, pfwdata, fwsize);
_rtl88e_enable_fw_download(adapt, false); _rtl88e_enable_fw_download(adapt, false);
err = _rtl88e_fw_free_to_go(adapt); return _rtl88e_fw_free_to_go(adapt);
return err;
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment