From: Jonathan Corbet Date: Sun, 18 May 2008 21:40:00 +0000 (-0600) Subject: Remove the lock_kernel() call from chrdev_open() X-Git-Tag: v2.6.27-rc1~1103^2~85 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9514dff918b947ae43b66517dc90d0e05548bd6a;p=linux-2.6 Remove the lock_kernel() call from chrdev_open() All in-kernel char device open() functions now either have their own lock_kernel() calls or clearly do not need one. Signed-off-by: Jonathan Corbet --- diff --git a/fs/char_dev.c b/fs/char_dev.c index a54d69369b..3cb7cda3d7 100644 --- a/fs/char_dev.c +++ b/fs/char_dev.c @@ -394,11 +394,8 @@ static int chrdev_open(struct inode *inode, struct file *filp) cdev_put(p); return -ENXIO; } - if (filp->f_op->open) { - lock_kernel(); + if (filp->f_op->open) ret = filp->f_op->open(inode,filp); - unlock_kernel(); - } if (ret) cdev_put(p); return ret;