diff --git a/pycheribuild/projects/cross/cheribsd.py b/pycheribuild/projects/cross/cheribsd.py index 2b5e3f787..d86517fd6 100644 --- a/pycheribuild/projects/cross/cheribsd.py +++ b/pycheribuild/projects/cross/cheribsd.py @@ -1830,7 +1830,6 @@ def default_kernel_config(self, platform: "Optional[ConfigPlatform]" = None, **f platform = self.get_default_kernel_platform() kernel_abi = filter_kwargs.pop("kernel_abi", self.get_default_kernel_abi()) filter_kwargs.setdefault("caprevoke", self.caprevoke_kernel) - filter_kwargs.setdefault("benchmark", self.build_bench_kernels) filter_kwargs["mfsroot"] = True config = CheriBSDConfigTable.get_default(self.crosscompile_target, platform, kernel_abi, **filter_kwargs) return config.kernconf diff --git a/tests/test_argument_parsing.py b/tests/test_argument_parsing.py index 9ad90d8c2..2e9b998a5 100644 --- a/tests/test_argument_parsing.py +++ b/tests/test_argument_parsing.py @@ -921,6 +921,14 @@ def test_kernel_configs(target, config_options: "list[str]", expected_kernels: " ], ["CHERI-QEMU-MFS-ROOT"], ), + pytest.param("cheribsd-mfs-root-kernel-aarch64", [], ["GENERIC-MFS-ROOT"]), + # regression test for assert len(configs) != 0, "No matching default kernel configuration", the + # build-bench-kernels flag should not affect the default kernel config selection just the additional ones. + pytest.param( + "cheribsd-mfs-root-kernel-aarch64", + ["--cheribsd/build-bench-kernels", "--cheribsd/default-kernel-abi=hybrid"], + ["GENERIC-MFS-ROOT"], + ), ], ) def test_mfsroot_kernel_configs(target: str, config_options: "list[str]", expected_kernels: "list[str]"):