U-Boot bootcmd not executing

Hi,

OK, this is likely me, but just not figuring it out :frowning_face:. I have set up a U-Boot bootcmd (run nfsboot). If I go to the serial console, reboot ... and "stop" U-Boot, so I can enter a command - I can run bootcmd, or bootd (boot default). It works great, no issue at all!

But, if I just reboot / power up - it seems to not run the bootcmd. I do have bootdelay set, which is necessary, but still then - it just boots from NAND. Is this expected, and/or am I doing something dumb? Everything I can find (including U-Boot documentation) says this command should be run.

Thanks!

device / model? (uboot banner?)

LOL - sorry! Was thinking this was a somewhat generic U-Boot item / issue, but you have a good point :grinning_face_with_smiling_eyes:.

Linksys EA3500, and if it helps,

        |  \/  | __ _ _ ____   _____| | |
        | |\/| |/ _` | '__\ \ / / _ \ | |
        | |  | | (_| | |   \ V /  __/ | |
        |_|  |_|\__,_|_|    \_/ \___|_|_|
 _   _     ____              _
| | | |   | __ )  ___   ___ | |_
| | | |___|  _ \ / _ \ / _ \| __|
| |_| |___| |_) | (_) | (_) | |_
 \___/    |____/ \___/ \___/ \__|
 ** WNC BOARD: audi R2.2 LE **

U-Boot 1.1.4 (Jan  2 2012 - 19:59:08) Marvell version: 3.5.9

Thanks!

1 Like

Did you saveenv after making changes to bootcmd?

Yep! And checked from serial (U-Boot), as well as OpenWrt (fw_printenv). What's odd ... if I break (into) U-Boot, just enter bootd (boot default) ... in runs my bootcmd. But, on reboot, untouched - it goes straight to NAND (flash). Huh?!?! :laughing:

Thanks!

So is bootcmd yours after a reboot, or is it reset to default?

Some uboots will ignore the params, and use a hard-coded string.

Nope, still mine - it's just not running it. Not sure why.

Sorry, to understand - are you saying it's supposed to ignore bootcmd, or asking if it is? If asking - yes, it's ignoring bootcmd for some reason.

Thanks!

There was a typo in my last post, fixed.

For the fun of it, dump the uboot partition (the bin partition, not data) , and use strings or a hex editor, to see if you can find the default bootcmd string within the dump file.

It could indicate the bootcmd is always defaulted, no matter what you actually set it to.

Feel free to post the printenv output as well.

2 Likes

Isn't that EA3500 "audi" a Linksys dualboot device?
The bootcmd to be run is modified at every sysupgrade when the dual-partition change is triggered.

https://github.com/openwrt/openwrt/blob/master/target/linux/kirkwood/base-files/lib/upgrade/linksys.sh#L5

(This thread is likely related to Mtd resize (to get back to Stock) [Solved] )

I thought that too, but it seems like the command line is not being used, rather the boot partition selection is based on the value of boot_part, no? I had some struggles with this in the past, and found some patches that take that into use. Let me go back, find those.

And I did confirm, after reboot ... bootcmd is untouched. Still perplexed why U-Boot doesn't use it. Hmmm.

Sort of :laughing:. I actually have a (final) solution for that one - just need to post it (tied up today, but by tomorrow I hope to capture it). I was able to crawl my way back there ... LOL! I figured I shouldn't "spider" that one into this U-Boot issue, so created this item - but do yell if that's wrong.

Thanks!