lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 22 Dec 2008 12:04:07 +0000
From:	Catalin Marinas <catalin.marinas@....com>
To:	Pekka Enberg <penberg@...helsinki.fi>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 11/14] kmemleak: Remove some of the kmemleak false
	positives

On Fri, 2008-12-19 at 22:15 +0200, Pekka Enberg wrote:
> On Fri, Dec 19, 2008 at 8:13 PM, Catalin Marinas
> <catalin.marinas@....com> wrote:
> > There are allocations for which the main pointer cannot be found but
> > they are not memory leaks. This patch fixes some of them. For more
> > information on false positives, see Documentation/kmemleak.txt.
> >
> > Signed-off-by: Catalin Marinas <catalin.marinas@....com>
> 
> > @@ -2882,6 +2883,12 @@ static int __init con_init(void)
> >         */
> >        for (currcons = 0; currcons < MIN_NR_CONSOLES; currcons++) {
> >                vc_cons[currcons].d = vc = alloc_bootmem(sizeof(struct vc_data));
> > +               /*
> > +                * Kmemleak does not track the memory allocated via
> > +                * alloc_bootmem() but this block contains pointers to
> > +                * other blocks allocated via kmalloc.
> > +                */
> > +               kmemleak_alloc(vc, sizeof(struct vc_data), 1, GFP_ATOMIC);
> >                INIT_WORK(&vc_cons[currcons].SAK_work, vc_SAK);
> >                visual_init(vc, currcons, 1);
> >                vc->vc_screenbuf = (unsigned short *)alloc_bootmem(vc->vc_screenbuf_size);
> 
> I think there was some discussion about adding hooks to the bootmem
> allocator. Didn't that work out?

I had a look but the combination of alloc_bootmem, reserve_bootmem and
free_bootmem doesn't seem feasible for kmemleak since calling these
functions doesn't always come in alloc/free pairs (unless I
misunderstand it).

-- 
Catalin

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ