summaryrefslogtreecommitdiff
path: root/v4l
diff options
context:
space:
mode:
Diffstat (limited to 'v4l')
-rwxr-xr-xv4l/scripts/gentree.pl1
-rwxr-xr-xv4l/scripts/make_config_compat.pl20
2 files changed, 21 insertions, 0 deletions
diff --git a/v4l/scripts/gentree.pl b/v4l/scripts/gentree.pl
index fccaedff4..d84608aa1 100755
--- a/v4l/scripts/gentree.pl
+++ b/v4l/scripts/gentree.pl
@@ -73,6 +73,7 @@ my %defs = (
'BUZ_USE_HIMEM' => 1,
'NEED_SOUND_DRIVER_H' => 0,
'TTUSB_KERNEL' => 1,
+ 'NO_PCM_LOCK' => 0,
);
#################################################################
diff --git a/v4l/scripts/make_config_compat.pl b/v4l/scripts/make_config_compat.pl
index fdbc5eaba..3aac7e3b3 100755
--- a/v4l/scripts/make_config_compat.pl
+++ b/v4l/scripts/make_config_compat.pl
@@ -159,6 +159,25 @@ 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_other_dependencies()
{
check_spin_lock();
@@ -169,6 +188,7 @@ sub check_other_dependencies()
check_is_singular();
check_clamp();
check_proc_create();
+ check_pcm_lock();
}
# Do the basic rules