[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170726001230.GA32325@hori1.linux.bs1.fc.nec.co.jp>
Date: Wed, 26 Jul 2017 00:12:31 +0000
From: Naoya Horiguchi <n-horiguchi@...jp.nec.com>
To: Matt Fleming <matt@...eblueprint.co.uk>
CC: Baoquan He <bhe@...hat.com>, Kees Cook <keescook@...omium.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"x86@...nel.org" <x86@...nel.org>,
Thomas Gleixner <tglx@...utronix.de>,
"H. Peter Anvin" <hpa@...or.com>, Ingo Molnar <mingo@...nel.org>,
"izumi.taku@...fujitsu.com" <izumi.taku@...fujitsu.com>,
Thomas Garnier <thgarnie@...gle.com>,
"fanc.fnst@...fujitsu.com" <fanc.fnst@...fujitsu.com>,
Junichi Nomura <j-nomura@...jp.nec.com>,
Ard Biesheuvel <ard.biesheuvel@...aro.org>
Subject: Re: [PATCH v3 2/2] x86/efi: clean up dead code around
efi_reserve_boot_services()
On Mon, Jul 24, 2017 at 02:20:44PM +0100, Matt Fleming wrote:
> On Mon, 10 Jul, at 02:51:36PM, Naoya Horiguchi wrote:
> > EFI_BOOT_SERVICES_{CODE|DATA} regions never overlap the kernel now,
> > so we can clean up the check in efi_reserve_boot_services().
> >
> > Signed-off-by: Naoya Horiguchi <n-horiguchi@...jp.nec.com>
> > ---
> > arch/x86/platform/efi/quirks.c | 23 +----------------------
> > 1 file changed, 1 insertion(+), 22 deletions(-)
>
> Is this true for kernels not using KASLR?
Thank you for pointing out this. It's not true depending on memmap layout.
If a firmware does not define the memory around the kernel address
(0x1000000 or CONFIG_PHYSICAL_START) as EFI_BOOT_SERVICES_*, no overlap
happens. That's true in my testing server, but I don't think that we can
expect it generally.
So I think of adding some assertion in the patch 1/2 to detect this overlap
in extract_kernel() even for no KASLR case.
Thanks,
Naoya Horiguchi
Powered by blists - more mailing lists