UEFI booting failed

Hi NV,

I work on JP5.1.1, Orin nano 8G, customer board.

I just executed the command to re-flash bootloader, and did not make any changes to uefi_jetson.bin, but the UEFI boot failure occurred.
100% Reproducibility.

reflash UEFI image:

Linux_for_Tegra$ sudo ./flash.sh -k A_cpu-bootloader -c bootloader/t186ref/cfg/flash_t234_qspi.xml jetson-orin-nano-devkit nvme0n1p1

error log:

��
  Jetson UEFI firmware (version 3.1-32827747 built on 2023-03-19T14:56:32+00:00)

��ERROR:   Exception reason=0 syndrome=0xbe000011
ERROR:   **************************************
ERROR:   RAS Uncorrectable Error in IOB, base=0xe010000:
ERROR:          Status = 0xec000612
ERROR:   SERR = Error response from slave: 0x12
ERROR:          IERR = CBB Interface Error: 0x6
ERROR:          Overflow (there may be more errors) - Uncorrectable
ERROR:          MISC0 = 0xc45a0040
ERROR:          MISC1 = 0x2acc860000000000
ERROR:          MISC2 = 0x0
ERROR:          MISC3 = 0x0
ERROR:          ADDR = 0x8000000003f300c0
ERROR:   **************************************
ERROR:   sdei_dispatch_event returned -1
Unhandled Exception in EL3.
x30            = 0x0000000050011384
x0             = 0x0000000000000000
x1             = 0x0000000000000000
x2             = 0x000000005000cfe4
x3             = 0x0000000000000047
x4             = 0x0000000000000000
x5             = 0x0000000000000043
x6             = 0x0000000000000001
x7             = 0x0000000000000000
x8             = 0x000000005000b610
x9             = 0x0000000000000000
x10            = 0x0000000000010c1c
x11            = 0x0000000000000040
x12            = 0x0000000000000000
x13            = 0x0000000000010c1c
x14            = 0x0000000241c96460
x15            = 0x0000000267f46000
x16            = 0x0000000264341ccc
x17            = 0x0000000001c79b58
x18            = 0x0000000000000000
x19            = 0x0000000003f300c4
x20            = 0x00000002642fde20
x21            = 0x00000002642ff2c0
x22            = 0x0000000000000001
x23            = 0x0000000000000023
x24            = 0x0000000000000056
x25            = 0x00000002421ac4b4
x26            = 0x00000002421ac4c9
x27            = 0x000000004c553250
x28            = 0x0000000241c96000
x29            = 0x00000002685fe770
scr_el3        = 0x000000000003073d
sctlr_el3      = 0x00000000b0cd183f
cptr_el3       = 0x0000000000000000
tcr_el3        = 0x0000000080823518
daif           = 0x00000000000003c0
mair_el3       = 0x00000000004404ff
spsr_el3       = 0x00000000600003cd
elr_el3        = 0x0000000050011384
ttbr0_el3      = 0x0000000050026ac1
esr_el3        = 0x0000000002000000
far_el3        = 0x0000000000000000
spsr_el1       = 0x0000000000000000
elr_el1        = 0x0000000000000000
spsr_abt       = 0x0000000000000000
spsr_und       = 0x0000000000000000
spsr_irq       = 0x0000000000000000
spsr_fiq       = 0x0000000000000000
sctlr_el1      = 0x0000000030d00800
actlr_el1      = 0x0000000000000000
cpacr_el1      = 0x0000000000300000
csselr_el1     = 0x0000000000000000
sp_el1         = 0x0000000000000000
esr_el1        = 0x0000000000000000
ttbr0_el1      = 0x0000000000000000
ttbr1_el1      = 0x0000000000000000
mair_el1       = 0x0000000000000000
amair_el1      = 0x0000000000000000
tcr_el1        = 0x0000000000000000
tpidr_el1      = 0x0000000000000000
tpidr_el0      = 0x0000000080000000
tpidrro_el0    = 0x0000000000000000
par_el1        = 0x0000000000000800
mpidr_el1      = 0x0000000081000000
afsr0_el1      = 0x0000000000000000
afsr1_el1      = 0x0000000000000000
contextidr_el1 = 0x0000000000000000
vbar_el1       = 0x0000000000000000
cntp_ctl_el0   = 0x0000000000000005
cntp_cval_el0  = 0x0000000015263075
cntv_ctl_el0   = 0x0000000000000000
cntv_cval_el0  = 0x0000000000000000
cntkctl_el1    = 0x0000000000000000
sp_el0         = 0x000000026447c2a0
isr_el1        = 0x0000000000000040
cpuectlr_el1   = 0xa000000b40543000
gicd_ispendr regs (Offsets 0x200 - 0x278)
 Offset:                        value
0000000000000200:               0x0000000000000000
0000000000000204:               0x0000000000000000
0000000000000208:               0x0000000000000000
000000000000020c:               0x0000000000000000
0000000000000210:               0x0000000000000000
0000000000000214:               0x0000000000000000
0000000000000218:               0x0000000000010000
000000000000021c:               0x0000000000000000
0000000000000220:               0x0000000000000000
0000000000000224:               0x0000000000000000
0000000000000228:               0x0000000000000000
000000000000022c:               0x0000000000000000
0000000000000230:               0x0000000000000000
0000000000000234:               0x0000000000000000
0000000000000238:               0x0000000000000000
000000000000023c:               0x0000000000000000
0000000000000240:               0x0000000000000000
0000000000000244:               0x0000000000000000
0000000000000248:               0x0000000000000000
000000000000024c:               0x0000000000000000
0000000000000250:               0x0000000000000000
0000000000000254:               0x0000000000000000
0000000000000258:               0x0000000000000000
000000000000025c:               0x0000000000000000
0000000000000260:               0x0000000000000000
0000000000000264:               0x0000000000000000
0000000000000268:               0x0000000000000000
000000000000026c:               0x0000000000000000
0000000000000270:               0x0000000000000000
0000000000000274:               0x0000000000000000
0000000000000278:               0x0000000000000000
000000000000027c:               0x0000000000000000

Is it possible to upgrade the BSP? Rel-35.3.1 seems too old.

Hi Wayne,

This problem does not exist on orin platform + jp5.1.1,
and our products are currently developed based on JP5.1.1.

My purpose is to modify UEFI. I just encountered this problem when I flash UEFI.

Ok. So just to clarify

  1. If you modify UEFI and do full flash, will you hit issue or not?

  2. If you don’t modify UEFI and just do partial flash of bootloader partition, will you hit issue or not?

Hi Wayne,

The cause of the error was found, which was caused by incorrect configuration of environment variables.

I want to disable the function of entering the bootload menu through the F11 or ESC key on the keyboard. Is there a way to do this?

Thanks a lot !

Hi Wayne,

I following the post to modified the code and reflash uefi_jetson.bin.

After UEFI is started, the UEFI firmware compilation time has changed:
Built on 2024-10-12T06:42:02+00:00

But still enter the boot menu by pressing the ESC key on the keyboard.

Hi Wayne,

Add log information in this function:PlatformRegisterOptionsAndKeys,
delete all the code in the function and keep only the log statement,

VOID
PlatformRegisterOptionsAndKeys (
  VOID
  )
{
  EFI_STATUS                    Status;
//  EFI_INPUT_KEY                 Enter;
//#if DISABLE_BOOT_MENU_INTERFACE
//  EFI_INPUT_KEY                 F11;
//  EFI_INPUT_KEY                 Esc;
//  EFI_BOOT_MANAGER_LOAD_OPTION  BootOption;
//#endif

  GetPlatformOptions ();

      DEBUG ((
        DEBUG_ERROR,
        "%a: wxj===== %r.\n",
        __FUNCTION__,
        Status
        ));

  //
  // Register ENTER as CONTINUE key
  //
//  Enter.ScanCode    = SCAN_NULL;
//  Enter.UnicodeChar = CHAR_CARRIAGE_RETURN;
//  Status            = EfiBootManagerRegisterContinueKeyOption (0, &Enter, NULL);
//  ASSERT_EFI_ERROR (Status);
  //
  // Map ESC to Boot Manager Menu
  //
//#if DISABLE_BOOT_MENU_INTERFACE
//  Esc.ScanCode    = SCAN_ESC;
//  Esc.UnicodeChar = CHAR_NULL;
//  Status          = EfiBootManagerGetBootManagerMenu (&BootOption);
//  ASSERT_EFI_ERROR (Status);

//  Status = EfiBootManagerAddKeyOptionVariable (
//             NULL,
//             (UINT16)BootOption.OptionNumber,
//             0,
//             &Esc,
//             NULL
//             );
//  ASSERT (Status == EFI_SUCCESS || Status == EFI_ALREADY_STARTED);

  //
  // Map F11 to Boot Menu App (defined by PcdBootMenuAppFile)
  //
//  F11.ScanCode    = SCAN_F11;
//  F11.UnicodeChar = CHAR_NULL;
//  Status          = EfiBootManagerGetBootMenuApp (&BootOption);
//  ASSERT_EFI_ERROR (Status);

//  Status = EfiBootManagerAddKeyOptionVariable (
//             NULL,
//             (UINT16)BootOption.OptionNumber,
//             0,
//             &F11,
//             NULL
//             );
//  ASSERT (Status == EFI_SUCCESS || Status == EFI_ALREADY_STARTED);
//#endif                                                                                                                                                                                                                                                                          
}

and then reflash the UEFI DEBUG bin file: uefi_Jetson_DEBUG.bin, log information is output normally in the console.

BUT,
still enter the boot menu by pressing the ESC key on the keyboard.

You only need to hide these functions.

Hi Wayne,

Modify as follows:

uefi$ git diff 
diff --git a/edk2-nvidia/Silicon/NVIDIA/Library/PlatformBootManagerLib/PlatformBm.c b/edk2-nvidia/Silicon/NVIDIA/Library/PlatformBootManagerLib/PlatformBm.c
index 15879d84..fb6d7fec 100644
--- a/edk2-nvidia/Silicon/NVIDIA/Library/PlatformBootManagerLib/PlatformBm.c
+++ b/edk2-nvidia/Silicon/NVIDIA/Library/PlatformBootManagerLib/PlatformBm.c
@@ -1203,7 +1203,7 @@ PlatformBootManagerBeforeConsole (
     //
     // Register platform-specific boot options and keyboard shortcuts.
     //
-    PlatformRegisterOptionsAndKeys ();
+    //PlatformRegisterOptionsAndKeys ();
 
     //
     // Register EnrollDefaultKeysApp as a SysPrep Option.
@@ -1560,7 +1560,7 @@ PlatformBootManagerAfterConsole (
   //
   // Display system and hotkey information after console is ready.
   //
-  DisplaySystemAndHotkeyInformation ();
+  //DisplaySystemAndHotkeyInformation ();

   //
   // Run Sparse memory test

console log:

��NOTICE:  BL31: v2.6(release):07eea4970
NOTICE:  BL31: Built : 07:55:15, Mar 19 2023
I/TC: 
I/TC: Non-secure external DT found
I/TC: OP-TEE version: 3.19 (gcc version 9.3.0 (Buildroot 2020.08)) #2 Sun Mar 19 15:02:44 UTC 2023 aarch64
I/TC: WARNING: This OP-TEE configuration might be insecure!
I/TC: WARNING: Please check https://optee.readthedocs.io/en/latest/architecture/porting_guidelines.html
I/TC: Primary CPU initializing
I/TC: WARNING: Test OEM keys are being used!
I/TC: This is only for TZ-SE testing and should NOT be used for a shipping product!
I/TC: Primary CPU switching to normal world boot
��
  Jetson UEFI firmware (version r35.3.1-5a48350b-dirty built on 2024-10-14T06:03:12+00:00)

boot logo :

BUT,
console and display still enter the boot menu by pressing the ESC key on the keyboard.

It is not the expected result to me that you would still enter into UEFI menu if you apply the change correctly.

Could you run the following command to flash the QSPI to apply the change?

$ sudo ./flash.sh -c bootloader/t186ref/cfg/flash_t234_qspi.xml jetson-orin-nano-devkit internal

Or do you have the devkit to reproduce the same issue?

Hi Kevin,

I directly replaced the uefi_jetson.bin in the bootlaoder directory with uefi_Jetson_RELEASE.bin,
and then reflash bootloader ,flash cmd:
sudo ./flash.sh -k A_cpu-bootloader -c bootloader/t186ref/cfg/flash_t234_qspi.xml jetson-orin-nano-devkit nvme0n1p1

We are not asking you what did you do.

We are telling you to follow our step to flash whole QSPI first and see the result.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.