diff mbox series

[U-Boot,3/6] efi: stub: Move the use_uart assignment immediately after exit_boot_services() call

Message ID 1529656712-3660-4-git-send-email-bmeng.cn@gmail.com
State Accepted
Delegated to: Bin Meng
Headers show
Series x86: efi: payload: Various fixes | expand

Commit Message

Bin Meng June 22, 2018, 8:38 a.m. UTC
The use_uart assignment should follow immediately after the call to
exit_boot_services(), in case we want some debug output after that.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
---

 lib/efi/efi_stub.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Simon Glass June 22, 2018, 7:28 p.m. UTC | #1
On 22 June 2018 at 02:38, Bin Meng <bmeng.cn@gmail.com> wrote:
> The use_uart assignment should follow immediately after the call to
> exit_boot_services(), in case we want some debug output after that.
>
> Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
> ---
>
>  lib/efi/efi_stub.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)

Reviewed-by: Simon Glass <sjg@chromium.org>
Bin Meng June 24, 2018, 12:54 a.m. UTC | #2
On Sat, Jun 23, 2018 at 3:28 AM, Simon Glass <sjg@chromium.org> wrote:
> On 22 June 2018 at 02:38, Bin Meng <bmeng.cn@gmail.com> wrote:
>> The use_uart assignment should follow immediately after the call to
>> exit_boot_services(), in case we want some debug output after that.
>>
>> Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
>> ---
>>
>>  lib/efi/efi_stub.c | 6 +++---
>>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> Reviewed-by: Simon Glass <sjg@chromium.org>

applied to u-boot-x86, thanks!
diff mbox series

Patch

diff --git a/lib/efi/efi_stub.c b/lib/efi/efi_stub.c
index 262fc56..1b495ec 100644
--- a/lib/efi/efi_stub.c
+++ b/lib/efi/efi_stub.c
@@ -361,14 +361,14 @@  efi_status_t EFIAPI efi_main(efi_handle_t image,
 		}
 	}
 
+	/* The EFI UART won't work now, switch to a debug one */
+	use_uart = true;
+
 	map.version = version;
 	map.desc_size = desc_size;
 	add_entry_addr(priv, EFIET_MEMORY_MAP, &map, sizeof(map), desc, size);
 	add_entry_addr(priv, EFIET_END, NULL, 0, 0, 0);
 
-	/* The EFI UART won't work now, switch to a debug one */
-	use_uart = true;
-
 	memcpy((void *)CONFIG_SYS_TEXT_BASE, _binary_u_boot_bin_start,
 	       (ulong)_binary_u_boot_bin_end -
 	       (ulong)_binary_u_boot_bin_start);