diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2009-10-10 11:35:43 -0400 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2009-10-14 11:33:32 -0400 |
commit | 40b798efe3460797a4ac928ee2e038774e2758eb (patch) | |
tree | 1acade9e91b9bf2c465d293dcfc383a236d616fa /drivers/char | |
parent | 80f506918fdaaca6b574ba931536a58ce015c7be (diff) |
drivers: Remove BKL from misc_open
misc_open() is already serialized with misc_mtx. Remove the BKL
locking which got there via the BKL pushdown.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Greg Kroah-Hartman <gregkh@suse.de>
LKML-Reference: <20091010153349.237173041@linutronix.de>
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/misc.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/char/misc.c b/drivers/char/misc.c index 07fa612a58d5..96f1cd086dd2 100644 --- a/drivers/char/misc.c +++ b/drivers/char/misc.c | |||
@@ -49,7 +49,6 @@ | |||
49 | #include <linux/device.h> | 49 | #include <linux/device.h> |
50 | #include <linux/tty.h> | 50 | #include <linux/tty.h> |
51 | #include <linux/kmod.h> | 51 | #include <linux/kmod.h> |
52 | #include <linux/smp_lock.h> | ||
53 | 52 | ||
54 | /* | 53 | /* |
55 | * Head entry for the doubly linked miscdevice list | 54 | * Head entry for the doubly linked miscdevice list |
@@ -118,8 +117,7 @@ static int misc_open(struct inode * inode, struct file * file) | |||
118 | struct miscdevice *c; | 117 | struct miscdevice *c; |
119 | int err = -ENODEV; | 118 | int err = -ENODEV; |
120 | const struct file_operations *old_fops, *new_fops = NULL; | 119 | const struct file_operations *old_fops, *new_fops = NULL; |
121 | 120 | ||
122 | lock_kernel(); | ||
123 | mutex_lock(&misc_mtx); | 121 | mutex_lock(&misc_mtx); |
124 | 122 | ||
125 | list_for_each_entry(c, &misc_list, list) { | 123 | list_for_each_entry(c, &misc_list, list) { |
@@ -157,7 +155,6 @@ static int misc_open(struct inode * inode, struct file * file) | |||
157 | fops_put(old_fops); | 155 | fops_put(old_fops); |
158 | fail: | 156 | fail: |
159 | mutex_unlock(&misc_mtx); | 157 | mutex_unlock(&misc_mtx); |
160 | unlock_kernel(); | ||
161 | return err; | 158 | return err; |
162 | } | 159 | } |
163 | 160 | ||