From f528f664d61cdb87fe12eb24ed9b05548a3e71b3 Mon Sep 17 00:00:00 2001 From: Fabian Frederick Date: Sat, 28 Jun 2014 14:18:52 +0200 Subject: [PATCH] drivers/net/wireless/ipw2x00/libipw_module.c: remove unnecessary null test before kfree Fix checkpatch warning: WARNING: kfree(NULL) is safe this check is probably not required Cc: Stanislav Yakovlev Cc: "John W. Linville" Cc: linux-wireless@vger.kernel.org Signed-off-by: Fabian Frederick Signed-off-by: John W. Linville --- drivers/net/wireless/ipw2x00/libipw_module.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/wireless/ipw2x00/libipw_module.c b/drivers/net/wireless/ipw2x00/libipw_module.c index 3adb24021a28..5f31b72a4921 100644 --- a/drivers/net/wireless/ipw2x00/libipw_module.c +++ b/drivers/net/wireless/ipw2x00/libipw_module.c @@ -100,8 +100,7 @@ static inline void libipw_networks_free(struct libipw_device *ieee) int i; for (i = 0; i < MAX_NETWORK_COUNT; i++) { - if (ieee->networks[i]->ibss_dfs) - kfree(ieee->networks[i]->ibss_dfs); + kfree(ieee->networks[i]->ibss_dfs); kfree(ieee->networks[i]); } } -- 2.39.5