From: Roy Franz Subject: [PATCH for-4.5] EFI: Always use EFI command line Date: Thu, 23 Oct 2014 17:16:22 -0700 Message-ID: <1414109782-22961-1-git-send-email-roy.franz@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel@lists.xen.org, ian.campbell@citrix.com, stefano.stabellini@citrix.com, tim@xen.org, jbeulich@suse.com Cc: Roy Franz , fu.wei@linaro.org List-Id: xen-devel@lists.xenproject.org This patch changes the ARM EFI boot code to always use the EFI commandline, even when loaded by GRUB, which makes it consistent with Linux EFI booting. The code previously incorrectly skipped processing of the EFI command line when modules are present in the loader supplied FDT and the config file is not used. There is no change in behavior for x86 since it unconditionally uses the config file. Signed-off-by: Roy Franz --- xen/common/efi/boot.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/xen/common/efi/boot.c b/xen/common/efi/boot.c index 4257341..c0d6768 100644 --- a/xen/common/efi/boot.c +++ b/xen/common/efi/boot.c @@ -702,7 +702,7 @@ efi_start(EFI_HANDLE ImageHandle, EFI_SYSTEM_TABLE *SystemTable) EFI_SHIM_LOCK_PROTOCOL *shim_lock; EFI_GRAPHICS_OUTPUT_PROTOCOL *gop = NULL; EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *mode_info; - union string section = { NULL }, name; + union string section = { NULL }, name, cfg_options = { NULL }; bool_t base_video = 0; char *option_str; @@ -904,8 +904,7 @@ efi_start(EFI_HANDLE ImageHandle, EFI_SYSTEM_TABLE *SystemTable) efi_bs->FreePool(name.w); } - name.s = get_value(&cfg, section.s, "options"); - efi_arch_handle_cmdline(argc ? *argv : NULL, options, name.s); + cfg_options.s = get_value(&cfg, section.s, "options"); if ( !base_video ) { @@ -930,8 +929,8 @@ efi_start(EFI_HANDLE ImageHandle, EFI_SYSTEM_TABLE *SystemTable) cfg.addr = 0; dir_handle->Close(dir_handle); - } + efi_arch_handle_cmdline(argc ? *argv : NULL, options, cfg_options.s); if ( gop && !base_video ) { -- 2.1.0