From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1425200AbcFHMg1 (ORCPT ); Wed, 8 Jun 2016 08:36:27 -0400 Received: from mail-wm0-f46.google.com ([74.125.82.46]:33350 "EHLO mail-wm0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1425184AbcFHMg0 (ORCPT ); Wed, 8 Jun 2016 08:36:26 -0400 Date: Wed, 8 Jun 2016 13:36:23 +0100 From: Matt Fleming To: Joseph Thelen Cc: linux-kernel@vger.kernel.org, Alex Thorlton , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , x86@kernel.org, linux-efi@vger.kernel.org, Linn Crosetto , Peter Jones , Matthew Garrett Subject: Re: [PATCH] x86/efi: Auto enable EFI memmap on SGI UV systems Message-ID: <20160608123623.GW2658@codeblueprint.co.uk> References: <1464900635-11957-1-git-send-email-jthelen@sgi.com> <1464900635-11957-2-git-send-email-jthelen@sgi.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1464900635-11957-2-git-send-email-jthelen@sgi.com> User-Agent: Mutt/1.5.24+41 (02bc14ed1569) (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org (Cc'ing people familiar with e820 map woes) On Thu, 02 Jun, at 03:50:35PM, Joseph Thelen wrote: > Currently, the EFI memory map entries are disabled by default and must > be enabled by passing the kernel boot option: > > add_efi_memmap > > The EFI memory map entries should be enabled on systems with more > than 128 E820 entries, which includes many UV systems. Check if > we're on a UV system by chekcing the uv system table. > Enable the EFI memory map entries if we're on a UV system. > > This change is backward compatible because the EFI memory map entries are > still disabled by default on non-UV systems, and it maintains the previous > behavior of the kernel boot option. In addition, it allows the EFI memory > map entries to be explicitly disabled (will not be automatically enabled) > by setting the add_efi_memmap boot option to anything that kstringtobool > will determine to be false. > > Signed-off-by: Joseph Thelen > Cc: Alex Thorlton > Cc: Matt Fleming > Cc: Thomas Gleixner > Cc: Ingo Molnar > Cc: "H. Peter Anvin" > Cc: x86@kernel.org > Cc: linux-efi@vger.kernel.org > --- > arch/x86/platform/efi/efi.c | 43 +++++++++++++++++++++++++++++++++++++++---- > 1 file changed, 39 insertions(+), 4 deletions(-) What's the ultimate goal here? To not require that users specify the add_efi_memmap kernel parameter in the future? Presumably they do today? FYI, a lot of non-UV systems have more than 128 entries and the way we handle it is by using the SETUP_E820_EXT setup_data entry in boot_params in the EFI boot stub (I don't think boot loaders use it because they largely go via the stub anyhow). So if you've got control over your boot loader, and assuming SGI UV systems don't boot using the EFI boot stub, you could look at adding boot loader support for SETUP_E820_EXT to force enable > 128 entries automatically without any new kernel code.