lkml.org 
[lkml]   [2009]   [Jul]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Possible memory leak via alloc_pid()
From
Date
On Wed, 2009-07-29 at 19:36 -0500, Serge E. Hallyn wrote:
> Quoting Andrew Morton (akpm@linux-foundation.org):
> > On Wed, 8 Jul 2009 22:33:31 +0100
> > Catalin Marinas <catalin.marinas@arm.com> wrote:
> > > There's a kmemleak report of a struct pid allocation in alloc_pid()
> > > which somehow gets lost:
[...]
> > > This is the gdm fork for starting Xorg (with pid 2739). It first
> > > logged me in automatically, after which I logged out and gdm started
> > > another Xorg. The pid structure for the first Xorg is reported as a
> > > leak. The Xorg with pid 2739 is no longer present on my system.
> > >
> > > Using gdb vmlinux /proc/kcore shows that the pid->count is 2, so
> > > that's why it probably wasn't freed by put_pid():
[...]
> thanks for the report. Note that kernel modules can increment those
> counds through find_get_pid().

It is possible that there are more *get_pid() calls than put_pid() but I
couldn't track them.

> Can you send your kernel .config and
> the output of lsmod?

I logged this as http://bugzilla.kernel.org/show_bug.cgi?id=13868. I
uploaded the ARM .config file (no modules loaded). I'll upload the x86
config as well later today (it's on my home machine but it's pretty much
the default Ubuntu 9.04 .config with CONFIG_KMEMLEAK enabled).

Thanks.

--
Catalin



\
 
 \ /
  Last update: 2009-07-30 11:19    [W:0.132 / U:5.848 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site