summaryrefslogtreecommitdiffstats
path: root/drivers/usb/scanner.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/scanner.h')
-rw-r--r--drivers/usb/scanner.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/usb/scanner.h b/drivers/usb/scanner.h
index bf01c8082..c1ec964dc 100644
--- a/drivers/usb/scanner.h
+++ b/drivers/usb/scanner.h
@@ -30,6 +30,7 @@
#include <linux/delay.h>
#include <linux/ioctl.h>
#include <linux/sched.h>
+#include <linux/smp_lock.h>
// #define DEBUG
@@ -94,6 +95,7 @@ struct scn_usb_data {
char *obuf, *ibuf; /* transfer buffers */
char bulk_in_ep, bulk_out_ep, intr_ep; /* Endpoint assignments */
wait_queue_head_t rd_wait_q; /* read timeouts */
+ struct semaphore gen_lock; /* lock to prevent concurrent reads or writes */
};
static struct scn_usb_data *p_scn_table[SCN_MAX_MNR] = { NULL, /* ... */};