From: Jonathan Corbet Date: Fri, 16 May 2008 20:25:20 +0000 (-0600) Subject: usbdev: BKL pushdown X-Git-Tag: v2.6.27-rc1~1103^2~90 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=b5b4aa67da65aeb58718e0a39158b293873ac572;p=linux-2.6-omap-h63xx.git usbdev: BKL pushdown Add explicit lock_kernel() calls to usbdev_open() Signed-off-by: Jonathan Corbet --- diff --git a/drivers/usb/core/devio.c b/drivers/usb/core/devio.c index de17738f3ac..9218cca2104 100644 --- 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; }