Hi Ralf,
I found some memory leak in
arch/mips/kernel/module.c file
arch/mips/kernel/module.c file
Please review below patch and share your review comments,
Thanks,
Akhilesh
From 77b8cae374a95000a1fd7e75bcda6694b8180fe9 Mon Sep 17 00:00:00 2001
From: Akhilesh Kumar <akhilesh.lxr@xxxxxxxxx>
Date: Sat, 4 Aug 2012 03:34:06 +0530
Subject: [Memory leak]: memory leak in apply_r_mips_lo16_rel
module.c
if (v != l->value)
goto out_danger ;
out_danger:
pr_err("module %s: dangerous R_MIPS_LO16 REL relocation\n", me->name);
return -ENOEXEC;
in case goto_out_danger kfree(l) is missing
Signed-off-by: Akhilesh Kumar <akhilesh.lxr@xxxxxxxxx>
---
arch/mips/kernel/module.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/mips/kernel/module.c b/arch/mips/kernel/module.c
index a5066b1..b1dce44 100644
--- a/arch/mips/kernel/module.c
+++ b/arch/mips/kernel/module.c
@@ -202,7 +202,7 @@ static int apply_r_mips_lo16_rel(struct module *me, u32 *location, Elf_Addr v)
out_danger:
pr_err("module %s: dangerous R_MIPS_LO16 REL relocation\n", me->name);
-
+ kfree(l);
return -ENOEXEC;
}
--
1.7.8.4