Skip to content

Commit 128d396

Browse files
committed
make kernel cmdline option "quiet" a parameter
1 parent 0169148 commit 128d396

File tree

3 files changed

+29
-1
lines changed

3 files changed

+29
-1
lines changed

docs/schema_doc.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -351,6 +351,23 @@ Allows users to customize memory allocation for guest
351351
2G
352352
```
353353

354+
### `core.kernel_quiet` Whether to include quiet flag in kernel command line
355+
356+
|||
357+
|-|-|
358+
|__Type__|boolean|
359+
|__Default__|`true`|
360+
361+
If true, the kernel command line will include the quiet flag, otherwise all kernel boot messages will be printed to the console
362+
363+
```yaml
364+
false
365+
```
366+
367+
```yaml
368+
true
369+
```
370+
354371
## `patches` Patches
355372

356373
|||

src/penguin/penguin_config/structure.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,15 @@ def set_kernel_default(cls, values):
259259
examples=["16K", "512M", "1G", "2G"],
260260
),
261261
]
262+
kernel_quiet: Annotated[
263+
bool,
264+
Field(
265+
True,
266+
title="Whether to include quiet flag in kernel command line",
267+
description="If true, the kernel command line will include the quiet flag, otherwise all kernel boot messages will be printed to the console",
268+
examples=[False, True],
269+
),
270+
]
262271

263272

264273
EnvVal = _newtype(

src/penguin/penguin_run.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,9 @@ def run_config(
273273
"vhost-user-vsock-pci,chardev=char0",
274274
]
275275

276-
append = f"root={ROOTFS} init=/igloo/init console=ttyS0 rw quiet panic=1" # Required
276+
append = f"root={ROOTFS} init=/igloo/init console=ttyS0 rw panic=1" # Required
277+
if "kernel_quiet" in conf["core"] and conf["core"]["kernel_quiet"]:
278+
append += " quiet"
277279
append += " rootfstype=ext2 norandmaps nokaslr" # Nice to have
278280
append += (
279281
" clocksource=jiffies nohz_full nohz=off no_timer_check" # Improve determinism?

0 commit comments

Comments
 (0)