diff --git a/nixos/modules/system/boot/kernel.nix b/nixos/modules/system/boot/kernel.nix index 46f2e3fec04c..4a9da9394519 100644 --- a/nixos/modules/system/boot/kernel.nix +++ b/nixos/modules/system/boot/kernel.nix @@ -83,7 +83,10 @@ in }; boot.kernelParams = mkOption { - type = types.listOf types.str; + type = types.listOf (types.strMatching ''([^"[:space:]]|"[^"]*")+'' // { + name = "kernelParam"; + description = "string, with spaces inside double quotes"; + }); default = [ ]; description = "Parameters added to the kernel command line."; };