summaryrefslogtreecommitdiffstats
path: root/drivers/char/hw_random
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2008-05-20 19:16:00 +0200
committerJonathan Corbet <corbet@lwn.net>2008-06-20 22:05:57 +0200
commita9c4e8f74ba26f10cf78fed7c5b863ea50988856 (patch)
tree4d60ce5b86a97ba3d1756723d326feb3e94e482c /drivers/char/hw_random
parenthpet: BKL pushdown (diff)
downloadlinux-a9c4e8f74ba26f10cf78fed7c5b863ea50988856.tar.xz
linux-a9c4e8f74ba26f10cf78fed7c5b863ea50988856.zip
hw-random: BKL pushdown
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'drivers/char/hw_random')
-rw-r--r--drivers/char/hw_random/core.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/char/hw_random/core.c b/drivers/char/hw_random/core.c
index 662d60e44e9a..e5d583c84e4f 100644
--- a/drivers/char/hw_random/core.c
+++ b/drivers/char/hw_random/core.c
@@ -37,6 +37,7 @@
#include <linux/kernel.h>
#include <linux/fs.h>
#include <linux/sched.h>
+#include <linux/smp_lock.h>
#include <linux/init.h>
#include <linux/miscdevice.h>
#include <linux/delay.h>
@@ -86,6 +87,7 @@ static int rng_dev_open(struct inode *inode, struct file *filp)
return -EINVAL;
if (filp->f_mode & FMODE_WRITE)
return -EINVAL;
+ cycle_kernel_lock();
return 0;
}