diff options
-rwxr-xr-x | v4l/scripts/make_kconfig.pl | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/v4l/scripts/make_kconfig.pl b/v4l/scripts/make_kconfig.pl index 0d396c8f4..228e0aa48 100755 --- a/v4l/scripts/make_kconfig.pl +++ b/v4l/scripts/make_kconfig.pl @@ -32,7 +32,7 @@ sub add_int($) { my $arg=shift; - exists $config{$arg} or die "Adding unknown int '$arg'"; + exists $config{$arg} or die "Adding unknown int/hex '$arg'"; $intopt{$arg} = 0; } @@ -41,7 +41,7 @@ sub set_int_value($$) my $key = shift; my $val = shift; - exists $intopt{$key} or die "Default for unknown int option '$key'"; + exists $intopt{$key} or die "Default for unknown int/hex option '$key'"; $intopt{$key} = $val; } @@ -124,7 +124,7 @@ sub open_kconfig($$) { add_int($key); } # Get default for int options - if (m|^\s+default "(\d+)"| && exists $intopt{$key}) { + if (m|^\s+default "([[:xdigit:]]+)"| && exists $intopt{$key}) { set_int_value($key, $1); } # Override default for disabled tri/bool options @@ -138,7 +138,9 @@ sub open_kconfig($$) { # we need to make sure we've disabled it, and add a bit # to the help text if (m|^\s*(---)?help(---)?\s*$| && $disabled) { - print OUT "\tdefault n\n" unless($default_seen); + if(exists $tristate{$key} && !$default_seen) { + print OUT "\tdefault n\n"; + } print OUT <<"EOF"; depends on VIDEO_KERNEL_VERSION help |