A minor installation improvement that I've found is to rearrange
the Linux kernel command line to be last segment in the payload.
This allows me to tweak boot time parameters without having to
re-write the entire kernel and initrd in the flash.

Is there a current or historical reason for the ordering?

diff --git a/util/cbfstool/cbfs-payload-linux.c 
b/util/cbfstool/cbfs-payload-linux.c
index 6b4bf27..ccbcb33 100644
--- a/util/cbfstool/cbfs-payload-linux.c
+++ b/util/cbfstool/cbfs-payload-linux.c
@@ -312,14 +312,14 @@ int parse_bzImage_to_payload(const struct buffer *input,
        bzp_output_segment(&bzp, &bzp.trampoline,
                           PAYLOAD_SEGMENT_CODE, TRAMPOLINE_ENTRY_LOC);
 
-       /* cmdline */
-       bzp_output_segment(&bzp, &bzp.cmdline,
-                          PAYLOAD_SEGMENT_DATA, COMMAND_LINE_LOC);
-
        /* initrd */
        bzp_output_segment(&bzp, &bzp.initrd,
                           PAYLOAD_SEGMENT_DATA, initrd_base);
 
+       /* cmdline */
+       bzp_output_segment(&bzp, &bzp.cmdline,
+                          PAYLOAD_SEGMENT_DATA, COMMAND_LINE_LOC);
+
        /* Terminating entry segment. */
        bzp_output_segment(&bzp, NULL, PAYLOAD_SEGMENT_ENTRY, 
TRAMPOLINE_ENTRY_LOC);
 
-- 
Trammell

-- 
coreboot mailing list: coreboot@coreboot.org
https://mail.coreboot.org/mailman/listinfo/coreboot

Reply via email to