streamline_config.pl: ensure all defaults are tracked

Track default options on the second line. On the second line of some
config entries, default and dependency options sometimes appear. In those
instances, the state will be "NEW" and not "DEP".

Signed-off-by: David Hunter <david.hunter.linux@gmail.com>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
This commit is contained in:
David Hunter 2024-10-14 10:13:32 -04:00 committed by Masahiro Yamada
parent f16c8c0818
commit 90edd30b86

View File

@ -220,7 +220,7 @@ sub read_kconfig {
$depends{$config} = $1;
} elsif ($state eq "DEP" && /^\s*depends\s+on\s+(.*)$/) {
$depends{$config} .= " " . $1;
} elsif ($state eq "DEP" && /^\s*def(_(bool|tristate)|ault)\s+(\S.*)$/) {
} elsif ($state ne "NONE" && /^\s*def(_(bool|tristate)|ault)\s+(\S.*)$/) {
my $dep = $3;
if ($dep !~ /^\s*(y|m|n)\s*$/) {
$dep =~ s/.*\sif\s+//;