From: Jesper Juhl Date: Mon, 9 Apr 2012 20:51:12 +0000 (+0200) Subject: wireless, mwifiex: drop redundant NULL test before call to release_firmware() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=4fb25c5914e0c79e236a327833af7f581225f790;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git wireless, mwifiex: drop redundant NULL test before call to release_firmware() Since release_firmware() does its own test for NULL it is redundant to do so before calling it. Signed-off-by: Jesper Juhl Acked-by: Bing Zhao Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/mwifiex/main.c b/drivers/net/wireless/mwifiex/main.c index 9d1b3ca6334b..2ee61626c54d 100644 --- a/drivers/net/wireless/mwifiex/main.c +++ b/drivers/net/wireless/mwifiex/main.c @@ -342,8 +342,7 @@ static int mwifiex_init_hw_fw(struct mwifiex_adapter *adapter) ret = 0; done: - if (adapter->firmware) - release_firmware(adapter->firmware); + release_firmware(adapter->firmware); if (ret) ret = -1; return ret;