V4L/DVB: pms: remove unnecessary exclusive open/close
authorHans Verkuil <hverkuil@xs4all.nl>
Mon, 22 Mar 2010 08:09:07 +0000 (05:09 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 18 May 2010 03:51:30 +0000 (00:51 -0300)
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/pms.c

index 0598bbd3f368da323398fedbf378ebedcc21ff3d..7129b50757dbd7605fa13449bd7793511019f52f 100644 (file)
@@ -61,7 +61,6 @@ struct pms {
        int depth;
        int input;
        s32 brightness, saturation, hue, contrast;
-       unsigned long in_use;
        struct mutex lock;
        int i2c_count;
        struct i2c_info i2cinfo[64];
@@ -931,25 +930,8 @@ static ssize_t pms_read(struct file *file, char __user *buf,
        return len;
 }
 
-static int pms_exclusive_open(struct file *file)
-{
-       struct pms *dev = video_drvdata(file);
-
-       return test_and_set_bit(0, &dev->in_use) ? -EBUSY : 0;
-}
-
-static int pms_exclusive_release(struct file *file)
-{
-       struct pms *dev = video_drvdata(file);
-
-       clear_bit(0, &dev->in_use);
-       return 0;
-}
-
 static const struct v4l2_file_operations pms_fops = {
        .owner          = THIS_MODULE,
-       .open           = pms_exclusive_open,
-       .release        = pms_exclusive_release,
        .ioctl          = video_ioctl2,
        .read           = pms_read,
 };