]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
Bluetooth: btmrvl_sdio: remove pointless conditional before release_firmware()
authorJesper Juhl <jj@chaosbits.net>
Mon, 9 Apr 2012 20:49:49 +0000 (22:49 +0200)
committerGustavo Padovan <gustavo@padovan.org>
Fri, 13 Apr 2012 21:26:56 +0000 (18:26 -0300)
release_firmware() deals gracefullt with NULL pointers so there's no
reason to test for one prior to calling the function.

Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Signed-off-by: Gustavo Padovan <gustavo@padovan.org>
drivers/bluetooth/btmrvl_sdio.c

index 27b74b0d547b540043fd318917e2cb5d6ebe0591..ed62c7f6a553a3eac686d66ed24194bf581c6244 100644 (file)
@@ -339,9 +339,7 @@ static int btmrvl_sdio_download_helper(struct btmrvl_sdio_card *card)
 
 done:
        kfree(tmphlprbuf);
-       if (fw_helper)
-               release_firmware(fw_helper);
-
+       release_firmware(fw_helper);
        return ret;
 }
 
@@ -484,10 +482,7 @@ static int btmrvl_sdio_download_fw_w_helper(struct btmrvl_sdio_card *card)
 
 done:
        kfree(tmpfwbuf);
-
-       if (fw_firmware)
-               release_firmware(fw_firmware);
-
+       release_firmware(fw_firmware);
        return ret;
 }