aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/briq_panel.c
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2010-06-01 16:53:01 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2010-08-10 16:47:43 -0400
commitec79d6056de58511d8e46d9ae59d3878f958dc3e (patch)
tree8e73cf399c4cb3c31dbf3caced385cfc018a706a /drivers/char/briq_panel.c
parent3f582b8c11014e4ce310d9839fb335164195333f (diff)
tty: replace BKL with a new tty_lock
As a preparation for replacing the big kernel lock in the TTY layer, wrap all the callers in new macros tty_lock, tty_lock_nested and tty_unlock. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/char/briq_panel.c')
-rw-r--r--drivers/char/briq_panel.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/char/briq_panel.c b/drivers/char/briq_panel.c
index 555cd93c2ee..d5fa113afe3 100644
--- a/drivers/char/briq_panel.c
+++ b/drivers/char/briq_panel.c
@@ -67,15 +67,15 @@ static void set_led(char state)
67 67
68static int briq_panel_open(struct inode *ino, struct file *filep) 68static int briq_panel_open(struct inode *ino, struct file *filep)
69{ 69{
70 lock_kernel(); 70 tty_lock();
71 /* enforce single access, vfd_is_open is protected by BKL */ 71 /* enforce single access, vfd_is_open is protected by BKL */
72 if (vfd_is_open) { 72 if (vfd_is_open) {
73 unlock_kernel(); 73 tty_unlock();
74 return -EBUSY; 74 return -EBUSY;
75 } 75 }
76 vfd_is_open = 1; 76 vfd_is_open = 1;
77 77
78 unlock_kernel(); 78 tty_unlock();
79 return 0; 79 return 0;
80} 80}
81 81