Where is the u-boot.lds in android_M6.0.1_2.0.0_source.tar.gz for HAB enabling

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

Where is the u-boot.lds in android_M6.0.1_2.0.0_source.tar.gz for HAB enabling

782 Views
ruei_chang
Contributor III

Dear NXP,

      I managed to enable HAB. And I found there is a post which has a document to guide people enabling the HAB on imx6. Here is the link How-to-enable-HAB-in-i-MX6x 

 

    And I followed all the instructions of the document. Everything is fine until the modification of u-boot.lds.

    

     There is no u-boot.lds in my u-boot folder. I've checked the folder(bootable/bootloader/uboot-imx/board/freescale/mx6sabresd)  and it only has these files below.

-rw-rw-r-- 1 softpc softpc 154 二 19 10:34 Kconfig
-rw-rw-r-- 1 softpc softpc 238 二 19 10:34 MAINTAINERS
-rw-rw-r-- 1 softpc softpc 303 二 19 10:34 Makefile
-rw-rw-r-- 1 softpc softpc 3773 二 19 10:34 mx6dlsabresd.cfg
-rw-rw-r-- 1 softpc softpc 4205 二 19 10:34 mx6q_4x_mt41j128.cfg
-rw-rw-r-- 1 softpc softpc 4666 二 19 10:34 mx6qp.cfg
-rwxrwxr-x 1 softpc softpc 50580 二 19 10:34 mx6sabresd.c
-rw-rw-r-- 1 softpc softpc 3403 二 19 10:34 mx6solo_4x_mt41j128.cfg
-rw-rw-r-- 1 softpc softpc 12673 二 19 10:34 plugin.S

 

  Did anyone have the same problem like me?  How can I fix it?

 

 

 

Labels (1)
Tags (1)
0 Kudos
3 Replies

777 Views
igorpadykov
NXP Employee
NXP Employee

Hi ruei_chang

 

unfortunately android_M6.0.1_2.0.0 is not more officially supported as outdated release.

Recommended to migrate to latest android releases

https://www.nxp.com/design/software/embedded-software/i-mx-software/android-os-for-i-mx-applications...

For hab for this release (based on L4.1.15 kernel) one can look at unit test examples

..test/mxc_secureboot

www.nxp.com/lgfiles/NMG/MAD/YOCTO/imx-test-5.7.tar.gz

 

Best regards
igor

0 Kudos

753 Views
ruei_chang
Contributor III

Hello @igorpadykov ,

   Thank you for your reply last time. The tool, mxc_secureboot, you gave is awesome. I can generate singed u-boot.imx smoothly.

    Then I used the MFG tool to download this signed u-boot.imx.

    I got some confuses here.  I followed the i.MX_6_Linux_High_Assurance_Boot_(HAB)_User's_Guide.pdf.  And it says I have to write down the data of SRK_1_2_3_4_fuse.bin in /sys/fsl_opt/HW_OCOTP_SRK[0-7] if I want to enable the HAB.

 

     I actually write the data into HW_OCOTP_SRK. But I'm not able to read the data from HW_OCOTP_SRK. It always return 0x0 so that I always get the data improperly.

      Then I checked the kernel_imx/drivers/char/fsl_otp.c.   There is a function which was called fsl_otp_show.  I noticed that otp_wait_busy in the fsl_otp_show function is only working fine in the first execution.  After that It will be 0x0 because otp_wait_busy always give me the value less than 0.  This is weird.

 

    So I tried to find another way to write down the fuse data. There is a method I can use in u-boot command prompt which is call fuse.

     Here is my example of fuse command in u-boot.  

fuse prog -y 3 0 0xFBC3C52B
fuse prog -y 3 1 0xA5A76254
fuse prog -y 3 2 0x2339D2A3
fuse prog -y 3 3 0xFB867DC3
fuse prog -y 3 4 0x875E8370
fuse prog -y 3 5 0xE5F3D5DB
fuse prog -y 3 6 0xF8A9B441
fuse prog -y 3 7 0xB211C8C1

   

    I assume all of data have been written properly.  And I blowed the fuse from eMMC.

fuse prog -y 0 5 0x1060
fuse prog -y 0 6 0x10

   

    Then I turned off the and turned on the power again. The board becomes a brick...I can't recover it by MFG tool anymore.  

 

    I don't understand if I do any improper instructions.  What if I'd like to enable the HAB in u-boot with eMMC?    Is there any latest version of HAB enabling for reference?

 

0 Kudos

774 Views
ruei_chang
Contributor III

Thank you so much, @igorpadykov    I will give it a try. 

0 Kudos