Skip to contentSkip to conversation

how to customize kernel command line in a kas-docker project?

DISCUSSION Meng, Fino 2 participants 2 messages May 5, 2020

lore
Share & tools
lore

Meng, Fino

author
#0 lore raw

hi team,

These days I am working on https://gitlab.denx.de/Xenomai/xenomai-images which use kas-docker, I need to customize kernel command line for my build. The 2 ways I found now:

1) directly modify wic/x86-64-efi.wks, update following line:
bootloader --ptable gpt --timeout=5 --append "rw rootwait console=ttyS0,115200"

2) add config files for a new board: board-xxx.yml, conf/machine/xxx.conf, wic/xxx.wks; then add my own kernel cmdline in xxx.wks;

is it possible to achieve this task in a non-intrusive way, without adding new board? add new cmdline in a new file and override the original,
same working mechanism as "PREFERRED_VERSION_linux-xenomai" ?

BR / Fino (孟祥夫)
Intel – IOTG Developer Enabling

#1 lore raw
Quoted 8 lines · Fino via Xenomai

hi team,

These days I am working on https://gitlab.denx.de/Xenomai/xenomai-images which use kas-docker, I need to customize kernel command line for my build. The 2 ways I found now:

1) directly modify wic/x86-64-efi.wks, update following line:
bootloader --ptable gpt --timeout=5 --append "rw rootwait console=ttyS0,115200"

Quoted 7 lines

2) add config files for a new board: board-xxx.yml, conf/machine/xxx.conf, wic/xxx.wks; then add my own kernel cmdline in xxx.wks;

is it possible to achieve this task in a non-intrusive way, without adding new board? add new cmdline in a new file and override the original,
same working mechanism as "PREFERRED_VERSION_linux-xenomai" ?

Many options are available, e.g.

- overwrite WKS_FILE to point to your own version, even only for the target in question (WKS_FILE_x86-64-efi = "...")

- give your own layer a higher prio and provide an own version of the wks file under the same name

- introduce a template for the wks file (x86-64-efi.wks.in), add a variable for the command line param and maintain that var also in your layer

- ...

It's basically what bitbake allows you to do, plus in this case some specifics of the wic integration into Isar (templating - though I think that OE provides the same).

Jan

Signature · 2 lines
Siemens AG, Corporate Technology, CT RDA IOT SES-DE
Corporate Competence Center Embedded Linux