/etc/fw_env.config not being created

if i have my uboot env defined in the script in ‎package/boot/uboot-tools/uboot-envtools/files/qualcommax_ipq807x`

is it ment to create /etc/fw_env.config?

as I have to manually create the above file to use fw_printenv or fw_setenv

Is this normal?

tplink,deco-x80-5g|)
	ubootenv_add_mtd "0:appsblenv" "0x0" "0x40000" "0x20000"

how come fw_printenv or fw_setenv dont look at the config in/etc/config/ubootenv as the details are populated there?

option dev '/dev/mtd9'
option offset '0x0'
option envsize '0x40000'
option secsize '0x20000'

Im having trouble with the device not switching root partitions during sysupgrade and i did not know if it is an envarg issue.

root@OpenWrt:~# fw_printenv bootargs
Warning: Bad CRC, using default environment
## Error: "bootargs" not defined
root@OpenWrt:~# 
there is a resemblence of correct args in appsblenv
1 Like

Just looking at this for a different device and stumbled on your post.

yes

Shouldn't it be ubootenv_add_uci_config ? As in

ubootenv_add_uci_config "/dev/mtd9" "0x0" "0x40000" "0x20000"

Maybe?

EDIT:

As I keep learning about this...

File you maybe need to update is this: package/boot/uboot-envtools/files/qualcommax_ipq807x
uboot-tools/uboot-envtools doesn't exist in my tree.

It does not create a fw_env.config for me but I fixed my dual boot problem, I just need it to be accepted:
my device has the partitions split on different MTD's and the normal nand do upgrade does not work with that layout.

Qualcommax: IPQ807x: Add dual nand helper script for TPlink Deco X80-5g. by professor-jonny · Pull Request #20961 · openwrt/openwrt

1 Like

Great.
My problem is simpler but your post was very helpful in pointing me where I was messing up.

BTW... your PR is stuck for a fail in formalities. Having done a few PR myself, I suggest you redo the commit with a shorter title and no dot at the end, or probably it won't go any further.

Good luck!