projects
/
GitHub
/
LineageOS
/
G12
/
android_kernel_amlogic_linux-4.9.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f9c8154
)
mvme16x-rtc: BKL pushdown
author
Arnd Bergmann
<arnd@arndb.de>
Tue, 20 May 2008 17:16:22 +0000
(19:16 +0200)
committer
Jonathan Corbet
<corbet@lwn.net>
Wed, 2 Jul 2008 21:06:23 +0000
(15:06 -0600)
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
arch/m68k/mvme16x/rtc.c
patch
|
blob
|
blame
|
history
diff --git
a/arch/m68k/mvme16x/rtc.c
b/arch/m68k/mvme16x/rtc.c
index e341387787ab8b048e14ad9575fa96e889acc611..432a9f13b2ed6bc6955908096740c1154e3d4ee5 100644
(file)
--- a/
arch/m68k/mvme16x/rtc.c
+++ b/
arch/m68k/mvme16x/rtc.c
@@
-10,6
+10,7
@@
#include <linux/errno.h>
#include <linux/miscdevice.h>
#include <linux/slab.h>
+#include <linux/smp_lock.h>
#include <linux/ioport.h>
#include <linux/capability.h>
#include <linux/fcntl.h>
@@
-127,11
+128,14
@@
static int rtc_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
static int rtc_open(struct inode *inode, struct file *file)
{
+ lock_kernel();
if( !atomic_dec_and_test(&rtc_ready) )
{
atomic_inc( &rtc_ready );
+ unlock_kernel();
return -EBUSY;
}
+ unlock_kernel();
return 0;
}