summaryrefslogtreecommitdiffstats
path: root/drivers/staging/csr
diff options
context:
space:
mode:
authorDevendra Naga <develkernel412222@gmail.com>2012-07-21 13:07:17 +0545
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-08-13 18:56:36 -0700
commit08fb73c1c842d32c15806bd9ae89531d5b0e31ea (patch)
treeed50c3c6820da834f817329db7ef03012646ae53 /drivers/staging/csr
parent2dd58c9d8de3858c51a2f903cc40c0d919a7ce27 (diff)
downloadlinux-08fb73c1c842d32c15806bd9ae89531d5b0e31ea.tar.bz2
staging/csr: remove firmware pointer check before giving to release_firmware
we do a check of firmware pointer against the NULL value before we give it to the release_firmware. as release_firmware is actually having a check against NULL, its not needed here. Signed-off-by: Devendra Naga <develkernel412222@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/csr')
-rw-r--r--drivers/staging/csr/firmware.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/staging/csr/firmware.c b/drivers/staging/csr/firmware.c
index d14e11839618..dc6a04db265a 100644
--- a/drivers/staging/csr/firmware.c
+++ b/drivers/staging/csr/firmware.c
@@ -402,9 +402,7 @@ int uf_release_firmware_files(unifi_priv_t *priv)
int uf_release_firmware(unifi_priv_t *priv, struct dlpriv *to_free)
{
if (to_free != NULL) {
- if (to_free->fw_desc != NULL) {
- release_firmware((const struct firmware *)to_free->fw_desc);
- }
+ release_firmware((const struct firmware *)to_free->fw_desc);
to_free->fw_desc = NULL;
to_free->dl_data = NULL;
to_free->dl_len = 0;