summaryrefslogtreecommitdiff
path: root/drivers/media/pci/cx23885/cx23888-ir.c
diff options
context:
space:
mode:
authorLad, Prabhakar <prabhakar.csengg@gmail.com>2013-05-14 01:45:17 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2013-05-27 09:34:56 -0300
commit7eac97d7e714429f7ef1ba5d35f94c07f4c34f8e (patch)
tree58ee47b8b4508f354b47cbd3d2f081c37b2fe7d3 /drivers/media/pci/cx23885/cx23888-ir.c
parent625b35229bc491e837b385b7ce1e2a8eece3db0f (diff)
[media] media: pci: remove duplicate checks for EPERM
This patch removes check for EPERM in dbg_g/s_register and vidioc_g/s_register as this check is already performed by core. Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/pci/cx23885/cx23888-ir.c')
-rw-r--r--drivers/media/pci/cx23885/cx23888-ir.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/media/pci/cx23885/cx23888-ir.c b/drivers/media/pci/cx23885/cx23888-ir.c
index fa672fe41079..cd98651f3ae6 100644
--- a/drivers/media/pci/cx23885/cx23888-ir.c
+++ b/drivers/media/pci/cx23885/cx23888-ir.c
@@ -1116,8 +1116,6 @@ static int cx23888_ir_g_register(struct v4l2_subdev *sd,
return -EINVAL;
if (addr < CX23888_IR_CNTRL_REG || addr > CX23888_IR_LEARN_REG)
return -EINVAL;
- if (!capable(CAP_SYS_ADMIN))
- return -EPERM;
reg->size = 4;
reg->val = cx23888_ir_read4(state->dev, addr);
return 0;
@@ -1135,8 +1133,6 @@ static int cx23888_ir_s_register(struct v4l2_subdev *sd,
return -EINVAL;
if (addr < CX23888_IR_CNTRL_REG || addr > CX23888_IR_LEARN_REG)
return -EINVAL;
- if (!capable(CAP_SYS_ADMIN))
- return -EPERM;
cx23888_ir_write4(state->dev, addr, reg->val);
return 0;
}