]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
V4L/DVB (3291): Fix signed/unsigned bug in hue handling
authorHans Verkuil <hverkuil@xs4all.nl>
Mon, 9 Jan 2006 17:32:43 +0000 (15:32 -0200)
committerMauro Carvalho Chehab <mchehab@brturbo.com.br>
Mon, 9 Jan 2006 17:32:43 +0000 (15:32 -0200)
- Fix signed/unsigned bug in hue handling (set to -127 and 129 was returned).

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
drivers/media/video/cx25840/cx25840-core.c

index d7ece6eecb5c88e7051f04cd0a448d5268409ae0..b93495b2a1fbea4e076be97306661162b99742b3 100644 (file)
@@ -466,7 +466,7 @@ static int get_v4lctrl(struct i2c_client *client, struct v4l2_control *ctrl)
                ctrl->value = cx25840_read(client, 0x420) >> 1;
                break;
        case V4L2_CID_HUE:
-               ctrl->value = cx25840_read(client, 0x422);
+               ctrl->value = (s8)cx25840_read(client, 0x422);
                break;
        case V4L2_CID_AUDIO_VOLUME:
        case V4L2_CID_AUDIO_BASS: