aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/core/devices.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/core/devices.c')
-rw-r--r--drivers/usb/core/devices.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/core/devices.c b/drivers/usb/core/devices.c
index 175529fd02f..c83c975152a 100644
--- a/drivers/usb/core/devices.c
+++ b/drivers/usb/core/devices.c
@@ -675,7 +675,7 @@ static loff_t usb_device_lseek(struct file *file, loff_t offset, int orig)
675{ 675{
676 loff_t ret; 676 loff_t ret;
677 677
678 lock_kernel(); 678 mutex_lock(&file->f_dentry->d_inode->i_mutex);
679 679
680 switch (orig) { 680 switch (orig) {
681 case 0: 681 case 0:
@@ -691,7 +691,7 @@ static loff_t usb_device_lseek(struct file *file, loff_t offset, int orig)
691 ret = -EINVAL; 691 ret = -EINVAL;
692 } 692 }
693 693
694 unlock_kernel(); 694 mutex_unlock(&file->f_dentry->d_inode->i_mutex);
695 return ret; 695 return ret;
696} 696}
697 697