| #
770aaedb |
| 14-Feb-2026 |
Linus Torvalds <torvalds@linux-foundation.org> |
Merge tag 'bootconfig-v7.0' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace
Pull bootconfig updates from Masami Hiramatsu:
- Update the bootconfig parser to stop searching for a
Merge tag 'bootconfig-v7.0' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace
Pull bootconfig updates from Masami Hiramatsu:
- Update the bootconfig parser to stop searching for a value when it encounters a newline character
- Update the tests for bootconfig parser to ensure the good examples to be parsed correctly by comparing the expected results
* tag 'bootconfig-v7.0' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace: bootconfig: Check the parsed output of the good examples bootconfig: Terminate value search if it hits a newline
show more ...
|
| #
1cadf281 |
| 05-Feb-2026 |
Masami Hiramatsu (Google) <mhiramat@kernel.org> |
bootconfig: Terminate value search if it hits a newline
Terminate the value search for a key if it hits a newline and make the value empty.
When we pass a bootconfig with an empty value terminated
bootconfig: Terminate value search if it hits a newline
Terminate the value search for a key if it hits a newline and make the value empty.
When we pass a bootconfig with an empty value terminated by the newline, like below::
foo = bar = value
Current bootconfig interprets it as a single entry::
foo = "bar = value";
The Documentation/admin-guide/bootconfig.rst defines the value itself is terminated by newline:
The value has to be terminated by semi-colon (``;``) or newline (``\n``).
but it does not define when the value search is terminated. This changes the behavior to be more line-oriented, so that it is clearer in how it works.
- The value search of key-value pair will be terminated by a comment or newline. - The value search of an array will continue beyond comments and newlines.
Thus, with this update, the above example is interpreted as::
foo = ""; bar = "value";
And the below example will cause a syntax error because "bar" is expected as a key but it has ','.
foo = bar, buz
According to this change, one wrong example config is updated.
Link: https://lore.kernel.org/all/177025238503.14982.17059549076175612447.stgit@devnote2/
Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org> Reviewed-by: Julius Werner <jwerner@chromium.org>
show more ...
|