"Replacement old tools" is untrue for `fw_setenv`
Closed this issue · 2 comments
The script format supported by this new implementation of fw_setenv
is not compatible with the one of the original implementation.
From the original fw_setenv
help message (eg. version 2019.01):
Script Syntax:
key [space] value
lines starting with '#' are treated as comment
A variable without value will be deleted. Any number of spaces are
allowed between key and value. Space inside of the value is treated
as part of the value itself.
The new (undocumented) implementation instead requires the following format:
name=value
Blindly switching to the new fw_setenv
tool in an otherwise working setup leads to unpleasant surprises. Been there, found this.
Please use the ML as indicated in the README, github issues are not generally ignored.
This was debated on the U-Boot ML times ago, and led to the commit (in U-Boot):
commit cd655514aa044c77fe3b895a51677ba47b26ba89
tools/env: allow equal sign as key value separation
Treat the first equal sign as a key/value separation too. This makes
the script files compatible with mkenvimage input file format. It
won't support variables with equal signs anymore, but this seems not
really like a loss.
Check the commit, old (but after 2018) tools in U-Boot support "=" as separator, even if the help was not updated (please send a patch to U-Boot ML). Because
name=value
is supported by both tools, the same script can be used independently which tool is (from U-Boot or libubootenv) is used.
Please use the ML as indicated in the README, github issues are not generally ignored. This was debated on the U-Boot ML times ago, and led to the commit (in U-Boot):
commit cd655514aa044c77fe3b895a51677ba47b26ba89 tools/env: allow equal sign as key value separation
Treat the first equal sign as a key/value separation too. This makes the script files compatible with mkenvimage input file format. It won't support variables with equal signs anymore, but this seems not really like a loss.
Check the commit, old (but after 2018) tools in U-Boot support "=" as separator, even if the help was not updated (please send a patch to U-Boot ML). Because
name=value
is supported by both tools, the same script can be used independently which tool is (from U-Boot or libubootenv) is used.
Thanks, I've such help improvement and I'll send a patch.