diff options
author | Arnd Bergmann <arnd@arndb.de> | 2008-05-20 19:16:29 +0200 |
---|---|---|
committer | Jonathan Corbet <corbet@lwn.net> | 2008-07-02 23:06:24 +0200 |
commit | 7bcc3209be82d69361a944c57caeb548b35c7f04 (patch) | |
tree | 0f902d364c7b16a5d8ca14c6ab59ec14870cee46 | |
parent | ocfs2-stack_user: BKL pushdown (diff) | |
download | linux-7bcc3209be82d69361a944c57caeb548b35c7f04.tar.xz linux-7bcc3209be82d69361a944c57caeb548b35c7f04.zip |
openprom: BKL pushdown
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
-rw-r--r-- | drivers/sbus/char/openprom.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/sbus/char/openprom.c b/drivers/sbus/char/openprom.c index fbfeb89a6f32..29dc735e1a20 100644 --- a/drivers/sbus/char/openprom.c +++ b/drivers/sbus/char/openprom.c @@ -33,6 +33,7 @@ #include <linux/kernel.h> #include <linux/errno.h> #include <linux/slab.h> +#include <linux/smp_lock.h> #include <linux/string.h> #include <linux/miscdevice.h> #include <linux/init.h> @@ -689,9 +690,11 @@ static int openprom_open(struct inode * inode, struct file * file) if (!data) return -ENOMEM; + lock_kernel(); data->current_node = of_find_node_by_path("/"); data->lastnode = data->current_node; file->private_data = (void *) data; + unlock_kernel(); return 0; } |