Warning HAB event in U-Boot 2020.04 for i.MX6Q

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Warning HAB event in U-Boot 2020.04 for i.MX6Q

1,923 Views
shunnianzhai
Contributor III

Hi All,

We have a custom board with i.MX6Q rev 1.6.

Previously we were using the U-Boot 2017.03 which was from NXP BSP version fsl-yocto-L4.9.11_1.0.0.

With U-Boot 2017.03, the following message were shown:

=> hab_status

Secure boot disabled

HAB Configuration: 0xf0, HAB State: 0x66

Noted that

1) no message ""No HAB Events Found!" was displayed for this version.

2) the device can boot properly after closing it.

 

Currently we are porting to the latest NXP BSP version LF5.10.9_1.0.0. Now the U-Boot version is 2020.04.

With U-Boot 2020.04, we noticed the following HAB events:

=> hab_status

Secure boot disabled

HAB Configuration: 0xf0, HAB State: 0x66

--------- HAB Event 1 -----------------
event data:
0xdb 0x00 0x24 0x42 0x69 0x30 0xe1 0x1d
0x00 0x04 0x00 0x02 0x40 0x00 0x36 0x06
0x55 0x55 0x00 0x03 0x00 0x00 0x00 0x00
0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0x00 0x00 0x00 0x01

STS = HAB_WARNING (0x69)
RSN = HAB_ENG_FAIL (0x30)
CTX = HAB_CTX_ENTRY (0xE1)
ENG = HAB_ENG_CAAM (0x1D)

Any idea what could be the problem? How to resolve it? 

Is it safe to close the device with this warning event?

 

Additional information:

We have one unit with the i.MX6Q rev 1.2.

Using the same signed u-boot image for 2020.04, the following message is observed:

=> hab_status

Secure boot disabled

HAB Configuration: 0xf0, HAB State: 0x66
No HAB Events Found!

Q: why is the HAB event different for i.MX6Q rev 1.2 and 1.6?

 

Thanks in advance for your kindly help or advice.

 

Best Regards,

Shunnian

Labels (1)
0 Kudos
Reply
7 Replies

1,915 Views
igorpadykov
NXP Employee
NXP Employee

Hi Shunnian

 

>Q: why is the HAB event different for i.MX6Q rev 1.2 and 1.6?

 

those warnings are caused by RNG self test errors on some i.MX device revisions,

for i.MX6Q only rev.1.6 is affected (additional details were sent via mail).

Recommended to apply patch:

https://portland.source.codeaurora.org/patches/external/imxsupport/uboot-imx/imx_v2016.03_4.1.15_2.0...

 

Best regards
igor

0 Kudos
Reply

1,912 Views
shunnianzhai
Contributor III

Hi Igor,

 

Thanks for your quick response.

I will try to apply the patch and verify the fixing. Once done, I will update you on the result.

 Noted that the patch  is only applicable to imx_v2016.03_4.1.15_2.0.0_ga branch of u-boot.

Is there any plan to apply the patch to the mainstream of the latest u-boot release so the issue can be completed resolved for future version?

 

Thanks and regards,

Shunnian

0 Kudos
Reply

1,909 Views
igorpadykov
NXP Employee
NXP Employee

>Is there any plan to apply the patch to the mainstream of the latest u-boot release so

>the issue can be completed resolved for future version?

 

no such plans, sorry.

 

Best regards
igor

0 Kudos
Reply

1,907 Views
shunnianzhai
Contributor III

Hi Igor,

Today I have tried to apply the patch to the u-boot code.

Also, add the following config into my defconfig file:

CONFIG_CMD_RNG_SELF_TEST=y

However, after I re-build the u-boot, I noted that CONFIG_CMD_RNG_SELF_TEST is not included in the auto-generated file ".config".

So, when I do test, the issue is still existed.

Pls advice on how to add and ensure this config in the file ".config"?

 

thanks for your help,

Shunnian

0 Kudos
Reply

1,904 Views
igorpadykov
NXP Employee
NXP Employee

>Pls advice on how to add and ensure this config in the file ".config"?

 

I sent additional materials via mail, had you checked them ?

In general, nxp has special service for helping with porting and applying patches: 

https://contact.nxp.com/new-prof-svcs-sw-tech

 

Best regards
igor

0 Kudos
Reply

1,896 Views
shunnianzhai
Contributor III

Hi igor,

Yes, I read the additional materials you sent to me and do what need to do per doc carefully.

Since the patch is for u-Boot 2016.03, there are needs to change some files location when porting to U-Boot 2020.04. Also, need to change some header files name to fix the compile errors.

Now I managed to successfully build the following 2 newly-added files:

  cmd_rng_self_test.c

  rng_self_test.c

However, when I test with the new u-boot image, it seems that the command "rng_self_test" is not recognized as the error shown below:

  => rng_self_test
  Unknown command 'rng_self_test' - try 'help'

Please advise what could be wrong?

In addition, please advise if it is safe to close the device even if the following warning event is occurred? What is the best approach to resolve this issue?

=> hab_status

Secure boot disabled

HAB Configuration: 0xf0, HAB State: 0x66

--------- HAB Event 1 -----------------
event data:
0xdb 0x00 0x24 0x42 0x69 0x30 0xe1 0x1d
0x00 0x04 0x00 0x02 0x40 0x00 0x36 0x06
0x55 0x55 0x00 0x03 0x00 0x00 0x00 0x00
0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0x00 0x00 0x00 0x01

STS = HAB_WARNING (0x69)
RSN = HAB_ENG_FAIL (0x30)
CTX = HAB_CTX_ENTRY (0xE1)
ENG = HAB_ENG_CAAM (0x1D)

 

Thanks & regards,

Shunnian

0 Kudos
Reply

1,890 Views
shunnianzhai
Contributor III

Hi igor,

Some good progress today.

I managed to run command "rng_self_test" successfully.

However, it shows some errors as below. Pls advise on what I should do next. What could be the issue?

=> rng_self_test 10000000
RNG SELF TEST DESCRIPTOR:
0xB0800036
0x04800010
0x3C85A15B
0x50A9D0B1
0x71A09FEE
0x2EECF20B
0x02800020
0xB267292E
0x85BF712D
0xE85FF43A
0xA716B7FB
0xC40BB528
0x27B6F564
0x8821CB5D
0x9B5F6C26
0x12A00020
0x0A20DE17
0x6529357E
0x316277AB
0x2846254E
0x34D23BA5
0x6F5E9C32
0x7ABDC1BB
0x0197A385
0x82500405
0xA2000001
0x10880004
0x00000005
0x12820004
0x00000020
0x82500001
0xA2000001
0x10880004
0x40000045
0x02800020
0x8F389CC7
0xE7F7CBB0
0x6BF2073D
0xFC380B6D
0xB22E9D1A
0xEE64FCB7
0xA2B48D49
0xDF9BC3A4
0x82500009
0xA2000001
0x10880004
0x00000005
0x82500001
0x60340020
0x10000000
0xA2000001
0x10880004
0x00000005
0x8250000D

Error while running RNG self-test descriptor: 536877395


=> hab_status

Secure boot disabled

HAB Configuration: 0xf0, HAB State: 0x66

--------- HAB Event 1 -----------------
event data:
0xdb 0x00 0x24 0x42 0x69 0x30 0xe1 0x1d
0x00 0x04 0x00 0x02 0x40 0x00 0x36 0x06
0x55 0x55 0x00 0x03 0x00 0x00 0x00 0x00
0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0x00 0x00 0x00 0x01

STS = HAB_WARNING (0x69)
RSN = HAB_ENG_FAIL (0x30)
CTX = HAB_CTX_ENTRY (0xE1)
ENG = HAB_ENG_CAAM (0x1D)

 

Thanks and regards,

Shunnian

0 Kudos
Reply