Flash_blk.scr new drive environmental variable on 2.8 BSP?


I was doing my migration steps since there is a new BSP announced and I noticed a change I was not expecting…

In the file flash_blk.scr (which I modified to support my internal flash script) appears at the top (what appears now in 2.8b2):

test -n ${drive} || setenv drive 1

Instead of (what I had in 2.8b1)

test -n ${drive} || setenv drive 0

Is there a reason why I should know about it? Did the internal mmc number change from zero to one? Should I keep it as 1 or change to what I had (zero)?

EDIT: I just noticed the same happened for fwd_blk.scr and the question is the same

Best Regards,


Our demo images 2.8b1 and 2.8b2 for Apalis iMX6 both use:

test -n ${drive} || setenv drive 1

The git log also shows that there was only two changes, but both did not touch this variable.

This variable is used as SD drive to load data from. All eMMC based devices (hence also Apalis iMX6) use drive 1 (since drive 0 is always the on module eMMC device). If you would like to use the second SD port one can also use drive 2…

Note that on Apalis modules, the run setupdate command checks for SD card presence and set the drive variable accordingly (the setsdupdate part of it). So the drive variable in the script is usually not set (this is just a fallback e.g. in case one starts the script manually rather than the default run setupdate).

Hi Stefan,

Thanks for the clarification.

On the 2.8b1 I must’ve replaced the file with my customized without noticing it. It makes sense if it’s to use from external SD.

Since my objective is to use internal eMMC to flash the module it’s more useful to me to have drive 0 but now I understand completely what is done.

Thank you