Skip to content

Commit

Permalink
V4L/DVB (3292): Fix signed/unsigned bug in brightness handling of cx2…
Browse files Browse the repository at this point in the history
…5840

- Fix signed/unsigned bug in brightness handling (set to 0 and 128 was returned).

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
  • Loading branch information
Hans Verkuil authored and Mauro Carvalho Chehab committed Jan 9, 2006
1 parent c5099a6 commit 0de7122
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/media/video/cx25840/cx25840-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -457,7 +457,7 @@ static int get_v4lctrl(struct i2c_client *client, struct v4l2_control *ctrl)
ctrl->value = state->pvr150_workaround;
break;
case V4L2_CID_BRIGHTNESS:
ctrl->value = cx25840_read(client, 0x414) + 128;
ctrl->value = (s8)cx25840_read(client, 0x414) + 128;
break;
case V4L2_CID_CONTRAST:
ctrl->value = cx25840_read(client, 0x415) >> 1;
Expand Down

0 comments on commit 0de7122

Please sign in to comment.