projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1af46fd
)
usbdev: BKL pushdown
author
Jonathan Corbet
<corbet@lwn.net>
Fri, 16 May 2008 20:25:20 +0000
(14:25 -0600)
committer
Jonathan Corbet
<corbet@lwn.net>
Fri, 20 Jun 2008 20:05:53 +0000
(14:05 -0600)
Add explicit lock_kernel() calls to usbdev_open()
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
drivers/usb/core/devio.c
patch
|
blob
|
history
diff --git
a/drivers/usb/core/devio.c
b/drivers/usb/core/devio.c
index de17738f3acbab5c69066a81a31b041d25c5bf38..9218cca210431dea3b840e85b4fa9a0f0653a3fd 100644
(file)
--- a/
drivers/usb/core/devio.c
+++ b/
drivers/usb/core/devio.c
@@
-565,6
+565,7
@@
static int usbdev_open(struct inode *inode, struct file *file)
struct dev_state *ps;
int ret;
+ lock_kernel();
/* Protect against simultaneous removal or release */
mutex_lock(&usbfs_mutex);
@@
-611,6
+612,7
@@
static int usbdev_open(struct inode *inode, struct file *file)
if (ret)
kfree(ps);
mutex_unlock(&usbfs_mutex);
+ unlock_kernel();
return ret;
}