diff options
Diffstat (limited to 'v4l/scripts')
-rwxr-xr-x | v4l/scripts/gentree.pl | 2 | ||||
-rwxr-xr-x | v4l/scripts/make_config_compat.pl | 40 |
2 files changed, 42 insertions, 0 deletions
diff --git a/v4l/scripts/gentree.pl b/v4l/scripts/gentree.pl index fccaedff4..1968bb334 100755 --- a/v4l/scripts/gentree.pl +++ b/v4l/scripts/gentree.pl @@ -73,6 +73,8 @@ my %defs = ( 'BUZ_USE_HIMEM' => 1, 'NEED_SOUND_DRIVER_H' => 0, 'TTUSB_KERNEL' => 1, + 'NO_PCM_LOCK' => 0, + 'NEED_ALGO_CONTROL' => 0, ); ################################################################# diff --git a/v4l/scripts/make_config_compat.pl b/v4l/scripts/make_config_compat.pl index fdbc5eaba..3a8bdd81e 100755 --- a/v4l/scripts/make_config_compat.pl +++ b/v4l/scripts/make_config_compat.pl @@ -159,6 +159,44 @@ sub check_proc_create() close INNET; } +sub check_pcm_lock() +{ + my $file = "$kdir/include/sound/pcm.h"; + my $need_compat = 1; + + open INNET, "<$file" or die "File not found: $file"; + while (<INNET>) { + if (m/pcm_stream_lock/) { + $need_compat = 0; + last; + } + } + + if ($need_compat) { + $out.= "\n#define NO_PCM_LOCK 1\n"; + } + close INNET; +} + +sub check_algo_control() +{ + my $file = "$kdir/include/linux/i2c.h"; + my $need_compat = 0; + + open INNET, "<$file" or die "File not found: $file"; + while (<INNET>) { + if (m/algo_control/) { + $need_compat = 1; + last; + } + } + + if ($need_compat) { + $out.= "\n#define NEED_ALGO_CONTROL 1\n"; + } + close INNET; +} + sub check_other_dependencies() { check_spin_lock(); @@ -169,6 +207,8 @@ sub check_other_dependencies() check_is_singular(); check_clamp(); check_proc_create(); + check_pcm_lock(); + check_algo_control(); } # Do the basic rules |