On 04.06.2025 01:56, Andrew Cooper wrote:
> The early exit from domain_cmdline_size() is buggy. Even if there's no
> bootloader cmdline and no kextra, there still might be Xen parameters to
> forward, and therefore a nonzero cmdline.
>
> Explain what the function is doing, and rewrite it to be both more legible and
> more extendible.
>
> Fixes: 142f0a43a15a ("x86/boot: add cmdline to struct boot_domain")
I don't think this is correct. Iirc I even commented on this apparent anomaly,
being (validly) told that it preserved original behavior, where all the code
was inside "if ( bd->kernel->cmdline_pa || bi->kextra )". Since I had asked to
fix this already back then, ...
> Signed-off-by: Andrew Cooper <[email protected]>
Reviewed-by: Jan Beulich <[email protected]>
with the Fixes: tag corrected (or dropped, for simplicity).
Jan