[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190418074510.GB27160@zn.tnic>
Date: Thu, 18 Apr 2019 09:45:10 +0200
From: Borislav Petkov <bp@...en8.de>
To: Qian Cai <cai@....pw>
Cc: dave.hansen@...ux.intel.com, luto@...nel.org, peterz@...radead.org,
catalin.marinas@....com, tglx@...utronix.de, mingo@...hat.com,
x86@...nel.org, linux-kernel@...r.kernel.org,
Brijesh Singh <brijesh.singh@....com>
Subject: Re: [PATCH] x86/mm/mem_encrypt: fix a crash with kmemleak_scan
On Tue, Apr 16, 2019 at 08:38:30PM -0400, Qian Cai wrote:
> kmemleak_init() will register the data/bss sections (only register
> .data..ro_after_init if not within .data) and then kmemleak_scan() will scan
> those address and dereference them looking for pointer referencing. If
> free_init_pages() free and unmap pages in those sections, kmemleak_scan() will
> trigger a crash if referencing one of those addresses.
>
> I checked other x86 free_init_pages() call sites and don't see anything obvious
> where another place to free an address in those sections.
And why is .bss/.data special and why does it need that special handling
by kmemleak?
There must be some rule or a heuristic why kmemleak does that. Is that
documented somewhere?
Thx.
--
Regards/Gruss,
Boris.
Good mailing practices for 400: avoid top-posting and trim the reply.
Powered by blists - more mailing lists