pub(crate) fn compute_new_kargs(
new_fs: &Dir,
current_root: Option<&Dir>,
new_kargs: &mut Cmdline<'_>,
) -> Result<()>Expand description
Computes new kernel arguments by applying the diff between existing and new kargs.d files.
This function:
- Loads kernel arguments from
usr/lib/bootc/kargs.din the new filesystem - Loads kernel arguments from the current root (if present)
- Computes the difference between them (added/removed arguments)
- Applies that difference to the provided
new_kargscmdline
This allows bootc to maintain user customizations while applying changes from updated container images.
ยงArguments
new_fs- Directory handle to the new filesystem containing kargs.d filescurrent_root- Optional directory handle to current root filesystemnew_kargs- Mutable cmdline that will be modified with the computed diff