aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/cx25840/cx25840-core.c
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2009-02-21 16:47:24 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-03-30 11:42:54 -0400
commit10afbef15e7bba5e1008f583852077743d28c395 (patch)
tree73dbfe2a3ccde6ef75c3403fb189274247740003 /drivers/media/video/cx25840/cx25840-core.c
parent1df795370c1392a026c63816368108187aec2ec1 (diff)
V4L/DVB (10698): v4l2-common: remove v4l2_ctrl_query_fill_std
The v4l2_ctrl_query_fill_std() function wasn't one the best idea I ever had. It doesn't add anything valuable that cannot be expressed equally well with v4l2_ctrl_query_fill and only adds overhead. Replace it with v4l2_ctrl_query_fill() everywhere it is used and remove it from v4l2_common.c. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/cx25840/cx25840-core.c')
-rw-r--r--drivers/media/video/cx25840/cx25840-core.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/media/video/cx25840/cx25840-core.c b/drivers/media/video/cx25840/cx25840-core.c
index d4059ecaa58..4a5d5ef9dfc 100644
--- a/drivers/media/video/cx25840/cx25840-core.c
+++ b/drivers/media/video/cx25840/cx25840-core.c
@@ -1205,10 +1205,12 @@ static int cx25840_queryctrl(struct v4l2_subdev *sd, struct v4l2_queryctrl *qc)
1205 1205
1206 switch (qc->id) { 1206 switch (qc->id) {
1207 case V4L2_CID_BRIGHTNESS: 1207 case V4L2_CID_BRIGHTNESS:
1208 return v4l2_ctrl_query_fill(qc, 0, 255, 1, 128);
1208 case V4L2_CID_CONTRAST: 1209 case V4L2_CID_CONTRAST:
1209 case V4L2_CID_SATURATION: 1210 case V4L2_CID_SATURATION:
1211 return v4l2_ctrl_query_fill(qc, 0, 127, 1, 64);
1210 case V4L2_CID_HUE: 1212 case V4L2_CID_HUE:
1211 return v4l2_ctrl_query_fill_std(qc); 1213 return v4l2_ctrl_query_fill(qc, -128, 127, 1, 0);
1212 default: 1214 default:
1213 break; 1215 break;
1214 } 1216 }
@@ -1220,10 +1222,11 @@ static int cx25840_queryctrl(struct v4l2_subdev *sd, struct v4l2_queryctrl *qc)
1220 return v4l2_ctrl_query_fill(qc, 0, 65535, 1222 return v4l2_ctrl_query_fill(qc, 0, 65535,
1221 65535 / 100, state->default_volume); 1223 65535 / 100, state->default_volume);
1222 case V4L2_CID_AUDIO_MUTE: 1224 case V4L2_CID_AUDIO_MUTE:
1225 return v4l2_ctrl_query_fill(qc, 0, 1, 1, 0);
1223 case V4L2_CID_AUDIO_BALANCE: 1226 case V4L2_CID_AUDIO_BALANCE:
1224 case V4L2_CID_AUDIO_BASS: 1227 case V4L2_CID_AUDIO_BASS:
1225 case V4L2_CID_AUDIO_TREBLE: 1228 case V4L2_CID_AUDIO_TREBLE:
1226 return v4l2_ctrl_query_fill_std(qc); 1229 return v4l2_ctrl_query_fill(qc, 0, 65535, 65535 / 100, 32768);
1227 default: 1230 default:
1228 return -EINVAL; 1231 return -EINVAL;
1229 } 1232 }