Skip to content

Commit ef784ee

Browse files
committed
ktest.pl minconfig: Unset configs instead of just removing them
After a full run of a make_min_config test, I noticed there were a lot of CONFIGs still enabled that really should not be. Looking at them, I noticed they were all defined as "default y". The issue is that the test simple removes the config and re-runs make oldconfig, which enables it again because it is set to default 'y'. Instead, explicitly disable the config with writing "# CONFIG_FOO is not set" to the file to keep it from being set again. With this change, one of my box's minconfigs went from 768 configs set, down to 521 configs set. Link: https://lkml.kernel.org/r/[email protected] Cc: [email protected] Fixes: 0a05c76 ("ktest: Added config_bisect test type") Reviewed-by: John 'Warthog9' Hawley (VMware) <[email protected]> Signed-off-by: Steven Rostedt (Google) <[email protected]>
1 parent 76dcd73 commit ef784ee

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tools/testing/ktest/ktest.pl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3768,9 +3768,10 @@ sub test_this_config {
37683768
# .config to make sure it is missing the config that
37693769
# we had before
37703770
my %configs = %min_configs;
3771-
delete $configs{$config};
3771+
$configs{$config} = "# $config is not set";
37723772
make_new_config ((values %configs), (values %keep_configs));
37733773
make_oldconfig;
3774+
delete $configs{$config};
37743775
undef %configs;
37753776
assign_configs \%configs, $output_config;
37763777

0 commit comments

Comments
 (0)