login
Login
/
Register
Search
Search this site:
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2010
»
May
»
26
Re: [PATCH] x86/pat: fix memory leak in free_memtype
view
thread
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From: Suresh Siddha
Subject:
Re: [PATCH] x86/pat: fix memory leak in free_memtype
Date: Tuesday, May 25, 2010 - 5:27 pm
On Tue, 2010-05-25 at 17:12 -0700, Suresh Siddha wrote:
quoted text
> On Tue, 2010-05-25 at 02:52 -0700, Xiaotian Feng wrote: > > reserve_memtype will allocate memory for new memtype, but > > in free_memtype, after the memtype erased from rbtree, the > > memory is not freed. > > > > Signed-off-by: Xiaotian Feng <dfeng@redhat.com> > > Cc: Thomas Gleixner <tglx@linutronix.de> > > Cc: Ingo Molnar <mingo@redhat.com> > > Cc: "H. Peter Anvin" <hpa@zytor.com> > > Cc: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> > > Cc: Jack Steiner <steiner@sgi.com> > > Cc: Suresh Siddha <suresh.b.siddha@intel.com> > > --- > > arch/x86/mm/pat_rbtree.c | 2 ++ > > 1 files changed, 2 insertions(+), 0 deletions(-) > > > > diff --git a/arch/x86/mm/pat_rbtree.c b/arch/x86/mm/pat_rbtree.c > > index 07de4cb..fb8c1e5 100644 > > --- a/arch/x86/mm/pat_rbtree.c > > +++ b/arch/x86/mm/pat_rbtree.c > > @@ -15,6 +15,7 @@ > > #include <linux/rbtree.h> > > #include <linux/sched.h> > > #include <linux/gfp.h> > > +#include <linux/slab.h> > > > > #include <asm/pgtable.h> > > #include <asm/pat.h> > > @@ -240,6 +241,7 @@ int rbt_memtype_erase(u64 start, u64 end) > > return -EINVAL; > > > > rb_erase(&data->rb, &memtype_rbroot); > > + kfree(data); > > return 0; > > } > > Acked-by: Suresh Siddha <suresh.b.siddha@intel.com> > > Peter, Please apply this for x86/urgent, this is introduced in the post > 2.6.34 changes.
Xiaotian, Also I think more cleaner fix is to do this in free_memtype(). Can you please resend the patch with this change? thanks, suresh --
unsubscribe notice
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html
Please read the FAQ at
http://www.tux.org/lkml/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
[PATCH] x86/pat: fix memory leak in free_memtype
, Xiaotian Feng
, (Tue May 25, 2:52 am)
Re: [PATCH] x86/pat: fix memory leak in free_memtype
, Suresh Siddha
, (Tue May 25, 5:12 pm)
Re: [PATCH] x86/pat: fix memory leak in free_memtype
, Suresh Siddha
, (Tue May 25, 5:27 pm)
[PATCH V2] x86/pat: fix memory leak in free_memtype
, Xiaotian Feng
, (Tue May 25, 6:51 pm)
Re: [PATCH V2] x86/pat: fix memory leak in free_memtype
, Suresh Siddha
, (Wed May 26, 9:47 am)
[tip:x86/urgent] x86, pat: Fix memory leak in free_memtype
, tip-bot for Xiaotian ...
, (Wed May 26, 1:22 pm)
Navigation
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Ken Chen
[patch] sched: fix inconsistency when redistribute per-cpu tg->cfs_rq shares.
Hugh Dickins
Re: Linux 2.6.26-rc1 - pgtable_32.c:178 pmd_bad
Bernhard Beck
[PATCH 001/001] usb-serial: Add ThinkOptics WavIT
Oleg Nesterov
Re: [PATCH 4/5] don't panic if /sbin/init exits or killed
Greg KH
[patch 07/21] rtc-pcf8563: detect polarity of century bit automatically
git
:
Jonathan del Strother
Re: [PATCH] Fixing path quoting issues
Gerrit Pape
[PATCH] fix skipping merge-order test with NO_OPENSSL=1.
Linus Torvalds
Re: Implementing branch attributes in git config
Johannes Schindelin
Re: Trying to use git-filter-branch to compress history by removing large, obsolet...
Gerrit Pape
[PATCH] hooks--update: fix test for properly set up project description file
linux-netdev
:
David Miller
Re: [PATCH 04/15] tg3: Preserve LAA when device control is released
Jean-Louis Dupond
Re: tg3 driver not advertising 1000mbit
Sven Wegener
[PATCH] ipvs: Add missing locking during connection table hashing and unhashing
David Miller
Re: [PATCH] qlcnic: dont assume NET_IP_ALIGN is 2
Stephen Hemminger
[PATCH 2/2] sky2: fix transmit state on resume
git-commits-head
:
Linux Kernel Mailing List
[SCSI] scsi ioctl: fix kernel-doc warning
Linux Kernel Mailing List
ALSA: HDA - Correct trivial typos in comments.
Linux Kernel Mailing List
i2c-viapro: Add support for SMBus Process Call transactions
Linux Kernel Mailing List
i2c: Documentation: upgrading clients HOWTO
Linux Kernel Mailing List
[PATCH] fix sysctl_nr_open bugs
openbsd-misc
:
Die Gestalt
Re: How to re-build openssl with SHA1 support?
Edwin Eyan Moragas
Re: managing routes for multiple PPPoE connections
Brian Candler
Re: OBSD's perspective on SELinux
Jonathan Schleifer
Why is getaddrinfo breaking POSIX?
Predrag Punosevac
Re: Kernel developers guide/tutorial
Colocation donated by:
Syndicate