Skip to content

Commit

Permalink
[media] fimc-lite: Initialize 'step' field in fimc_lite_ctrl structure
Browse files Browse the repository at this point in the history
v4l2_ctrl_new() uses check_range() for control range checking.
This function expects 'step' value for V4L2_CTRL_TYPE_BOOLEAN type control.
If 'step' value doesn't match to '1', it returns -ERANGE error.
This patch adds the default .step value to 1.

Signed-off-by: Shaik Ameer Basha <shaik.ameer@samsung.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Shaik Ameer Basha authored and Mauro Carvalho Chehab committed Mar 21, 2013
1 parent e71918e commit 4cec189
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/media/platform/s5p-fimc/fimc-lite.c
Original file line number Diff line number Diff line change
Expand Up @@ -1408,6 +1408,7 @@ static const struct v4l2_ctrl_config fimc_lite_ctrl = {
.id = V4L2_CTRL_CLASS_USER | 0x1001,
.type = V4L2_CTRL_TYPE_BOOLEAN,
.name = "Test Pattern 640x480",
.step = 1,
};

static int fimc_lite_create_capture_subdev(struct fimc_lite *fimc)
Expand Down

0 comments on commit 4cec189

Please sign in to comment.