[U-Boot] [PATCH 0/2] fw_env: fix bugs in fw_setenv when erase-block-size < env-size

Dustin Byford dustin at cumulusnetworks.com
Fri Mar 7 05:48:21 CET 2014


Hi All,

I'm having a problem where fw_setenv fails writing the environment to a SPI NOR
device with a 4K erase block size.  This led me to two discoveries and two
patches:

1) The "default" number of environment sectors is assumed to be one, even if
the environment is larger than a sector.

2) fw_setenv has a bug calculating bytes written for NOR devices.

Patches to follow:

[PATCH 1/2] fw_env: calculate default number of env sectors
[PATCH 2/2] fw_env: correct writes to devices with small erase blocks

Thanks,

		--Dustin


More information about the U-Boot mailing list