diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2000-07-15 03:32:22 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2000-07-15 03:32:22 +0000 |
commit | f1da2c3860e301527d56a1ef0b56c649ee7c4b1b (patch) | |
tree | 562b5d2e8b9cb62eb983d78ff6bcf9789e08fcf6 /net/irda | |
parent | 00f11569ac8ca73cbcdef8822de1583e79aee571 (diff) |
Merge with Linux 2.4.0-test5-pre1. This works again on Origin UP.
The IP22 cache bugs which are plaguing some machines are still unfixed.
Diffstat (limited to 'net/irda')
-rw-r--r-- | net/irda/irmod.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/net/irda/irmod.c b/net/irda/irmod.c index 5decebd98..fde6788c3 100644 --- a/net/irda/irmod.c +++ b/net/irda/irmod.c @@ -28,6 +28,7 @@ #include <linux/init.h> #include <linux/poll.h> #include <linux/proc_fs.h> +#include <linux/smp_lock.h> #include <asm/segment.h> @@ -389,12 +390,15 @@ static int irda_open( struct inode * inode, struct file *file) { IRDA_DEBUG( 4, __FUNCTION__ "()\n"); + lock_kernel(); if (irda.in_use) { + unlock_kernel(); IRDA_DEBUG(0, __FUNCTION__ "(), irmanager is already running!\n"); return -1; } irda.in_use = TRUE; + unlock_kernel(); return 0; } @@ -446,7 +450,9 @@ static int irda_close(struct inode *inode, struct file *file) { IRDA_DEBUG(4, __FUNCTION__ "()\n"); + lock_kernel(); irda.in_use = FALSE; + unlock_kernel(); return 0; } |