cancel
Showing results for 
Search instead for 
Did you mean: 

How to add new uboot environment variable in yocto linux

Smedi
Associate II

Hello,

I am using STM32MP157C-DK2 evalution board and I successfully booted the board with STM yocto,now I was trying to add a new environment variable in the Uboot.But I was not able to get how to do that.Can anyone suggest how to do this.

Regards

Srikanth.

2 REPLIES 2
mleo
Senior II

Hello Srikanth,

E.g. you can carefully adapt following patch file - look for CONFIG_EXTRA_ENV_SETTINGS:

/layers/meta-st/meta-st-stm32mp/recipes-bsp/u-boot/u-boot-stm32mp/0005-ARM-v2018.11-stm32mp-r1-MISC.patch

After rebuild you can also verify that your new varible was correctly added in your build directory

/build-openstlinuxweston-stm32mp1/tmp-glibc/work-shared/stm32mp1/uboot-source/include/configs/stm32mp1.h

Best regards,

Milan

Smedi
Associate II

Hai mleo,

Thanks for the reply I found the patch file in the path suggested by I came to know from that patch yocto is getting some of the uboot environment variables like kernel_addr..etc.But I was new to this yocto can you help me how to add my variable and generate the patch file to get the uboot environment variable.

Regards

Srikanth.