aboutsummaryrefslogtreecommitdiff
path: root/drivers/mtd/maps/tqm8xxl.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mtd/maps/tqm8xxl.c')
-rw-r--r--drivers/mtd/maps/tqm8xxl.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/mtd/maps/tqm8xxl.c b/drivers/mtd/maps/tqm8xxl.c
index 9cb5d679fe6..a43517053e7 100644
--- a/drivers/mtd/maps/tqm8xxl.c
+++ b/drivers/mtd/maps/tqm8xxl.c
@@ -224,10 +224,8 @@ int __init init_tqm_mtd(void)
error_mem:
for(idx = 0 ; idx < FLASH_BANK_MAX ; idx++) {
if(map_banks[idx] != NULL) {
- if(map_banks[idx]->name != NULL) {
- kfree(map_banks[idx]->name);
- map_banks[idx]->name = NULL;
- }
+ kfree(map_banks[idx]->name);
+ map_banks[idx]->name = NULL;
kfree(map_banks[idx]);
map_banks[idx] = NULL;
}