Commit a9072fe0 authored by Mark Hounschell's avatar Mark Hounschell Committed by Greg Kroah-Hartman

staging: dgap: remove unnecessary dgap_global_lock

dgap_global_lock is no longer required. This patch
removes it.
Signed-off-by: default avatarMark Hounschell <markh@compro.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 54794d19
...@@ -240,7 +240,6 @@ static const struct file_operations DgapBoardFops = { ...@@ -240,7 +240,6 @@ static const struct file_operations DgapBoardFops = {
*/ */
static uint dgap_NumBoards; static uint dgap_NumBoards;
static struct board_t *dgap_Board[MAXBOARDS]; static struct board_t *dgap_Board[MAXBOARDS];
DEFINE_SPINLOCK(dgap_global_lock);
static ulong dgap_poll_counter; static ulong dgap_poll_counter;
static char *dgap_config_buf; static char *dgap_config_buf;
static int dgap_driver_state = DRIVER_INITIALIZED; static int dgap_driver_state = DRIVER_INITIALIZED;
...@@ -1264,10 +1263,6 @@ static int dgap_ms_sleep(ulong ms) ...@@ -1264,10 +1263,6 @@ static int dgap_ms_sleep(ulong ms)
*/ */
static int dgap_tty_preinit(void) static int dgap_tty_preinit(void)
{ {
unsigned long flags;
DGAP_LOCK(dgap_global_lock, flags);
/* /*
* Allocate a buffer for doing the copy from user space to * Allocate a buffer for doing the copy from user space to
* kernel space in dgap_input(). We only use one buffer and * kernel space in dgap_input(). We only use one buffer and
...@@ -1276,12 +1271,9 @@ static int dgap_tty_preinit(void) ...@@ -1276,12 +1271,9 @@ static int dgap_tty_preinit(void)
*/ */
dgap_TmpWriteBuf = kmalloc(WRITEBUFLEN, GFP_ATOMIC); dgap_TmpWriteBuf = kmalloc(WRITEBUFLEN, GFP_ATOMIC);
if (!dgap_TmpWriteBuf) { if (!dgap_TmpWriteBuf)
DGAP_UNLOCK(dgap_global_lock, flags);
return -ENOMEM; return -ENOMEM;
}
DGAP_UNLOCK(dgap_global_lock, flags);
return 0; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment