Skip to contentSkip to conversation

arm: mach-omap2: mux: free allocated memory on error exit

PATCH New Aaro Koskinen 2 participants 2 messages Jan 28, 2011 – Feb 1, 2011

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 arm: mach-omap2: mux: free allocated memory on error exit

Free allocated memory on error exit.

---
 arch/arm/mach-omap2/mux.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
arch/arm/mach-omap2/mux.c +1 -0
index df8d2f2..18aea0c 100644
@@ -1000,6 +1000,7 @@ int __init omap_mux_init(const char *name, u32 flags,
 	if (!partition->base) {
 		pr_err("%s: Could not ioremap mux partition at 0x%08x\n",
 			__func__, partition->phys);
+		kfree(partition);
 		return -ENODEV;
 	}
 
Signature · 1 line
1.5.6.5
maintainer
#1 lore raw

PATCH 1/1 arm: mach-omap2: mux: free allocated memory on error exit

Quoted 12 lines · Aaro Koskinen

Free allocated memory on error exit.

---
 arch/arm/mach-omap2/mux.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
arch/arm/mach-omap2/mux.c +0 -0
index df8d2f2..18aea0c 100644

arch/arm/mach-omap2/mux.c int __init omap_mux_init(const char *name, u32 flags, · line 1005

Quoted 6 lines
arch/arm/mach-omap2/mux.c +1 -0
@@ -1000,6 +1000,7 @@ int __init omap_mux_init(const char *name, u32 flags,
 	if (!partition->base) {
 		pr_err("%s: Could not ioremap mux partition at 0x%08x\n",
 			__func__, partition->phys);
+		kfree(partition);
 		return -ENODEV;
 	}

Thanks, adding into devel-fixes for the -rc cycle.

Tony