From: Vasily Gorbik Date: Fri, 17 Feb 2023 13:00:54 +0000 (+0100) Subject: s390/setup: do not complain about parameters handled in decompressor X-Git-Tag: v6.3-rc1~25^2~11 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=8ee0d2fb4dfa3465ea2030dec59a6f6fe3005804;p=thirdparty%2Fkernel%2Flinux.git s390/setup: do not complain about parameters handled in decompressor Currently there are several kernel command line parameters which are only parsed and handled in decompressor and not known to the kernel. This leads to the following error message during kernel boot: Unknown kernel command line parameters "mem=3G nokaslr", will be passed to user space. To avoid confusion, register those parameters with an empty stub so that kernel does not complain about them. Reported-by: Gerald Schaefer Reviewed-by: Heiko Carstens Signed-off-by: Vasily Gorbik Signed-off-by: Heiko Carstens --- diff --git a/arch/s390/kernel/early.c b/arch/s390/kernel/early.c index 59eba19ae0f2a..d26f02495636e 100644 --- a/arch/s390/kernel/early.c +++ b/arch/s390/kernel/early.c @@ -36,6 +36,23 @@ int __bootdata(is_full_image); +#define decompressor_handled_param(param) \ +static int __init ignore_decompressor_param_##param(char *s) \ +{ \ + return 0; \ +} \ +early_param(#param, ignore_decompressor_param_##param) + +decompressor_handled_param(mem); +decompressor_handled_param(vmalloc); +decompressor_handled_param(dfltcc); +decompressor_handled_param(noexec); +decompressor_handled_param(facilities); +decompressor_handled_param(nokaslr); +#if IS_ENABLED(CONFIG_KVM) +decompressor_handled_param(prot_virt); +#endif + static void __init reset_tod_clock(void) { union tod_clock clk;