diff options
-rw-r--r-- | drivers/media/video/cx2341x.c | 5 | ||||
-rw-r--r-- | drivers/media/video/v4l2-common.c | 14 | ||||
-rw-r--r-- | include/linux/videodev2.h | 6 |
3 files changed, 16 insertions, 9 deletions
diff --git a/drivers/media/video/cx2341x.c b/drivers/media/video/cx2341x.c index 22847a0444f5..cbbe47fb87b7 100644 --- a/drivers/media/video/cx2341x.c +++ b/drivers/media/video/cx2341x.c | |||
@@ -508,7 +508,10 @@ int cx2341x_ctrl_query(const struct cx2341x_mpeg_params *params, | |||
508 | /* this setting is read-only for the cx2341x since the | 508 | /* this setting is read-only for the cx2341x since the |
509 | V4L2_CID_MPEG_STREAM_TYPE really determines the | 509 | V4L2_CID_MPEG_STREAM_TYPE really determines the |
510 | MPEG-1/2 setting */ | 510 | MPEG-1/2 setting */ |
511 | err = v4l2_ctrl_query_fill_std(qctrl); | 511 | err = v4l2_ctrl_query_fill(qctrl, |
512 | V4L2_MPEG_VIDEO_ENCODING_MPEG_1, | ||
513 | V4L2_MPEG_VIDEO_ENCODING_MPEG_2, 1, | ||
514 | V4L2_MPEG_VIDEO_ENCODING_MPEG_2); | ||
512 | if (err == 0) | 515 | if (err == 0) |
513 | qctrl->flags |= V4L2_CTRL_FLAG_READ_ONLY; | 516 | qctrl->flags |= V4L2_CTRL_FLAG_READ_ONLY; |
514 | return err; | 517 | return err; |
diff --git a/drivers/media/video/v4l2-common.c b/drivers/media/video/v4l2-common.c index 88ca13104417..893ac496c4b4 100644 --- a/drivers/media/video/v4l2-common.c +++ b/drivers/media/video/v4l2-common.c | |||
@@ -187,9 +187,10 @@ const char **v4l2_ctrl_get_menu(u32 id) | |||
187 | NULL | 187 | NULL |
188 | }; | 188 | }; |
189 | static const char *mpeg_audio_encoding[] = { | 189 | static const char *mpeg_audio_encoding[] = { |
190 | "Layer I", | 190 | "MPEG-1 Layer I", |
191 | "Layer II", | 191 | "MPEG-1 Layer II", |
192 | "Layer III", | 192 | "MPEG-1 Layer III", |
193 | "MPEG-4 AAC", | ||
193 | NULL | 194 | NULL |
194 | }; | 195 | }; |
195 | static const char *mpeg_audio_l1_bitrate[] = { | 196 | static const char *mpeg_audio_l1_bitrate[] = { |
@@ -271,6 +272,7 @@ const char **v4l2_ctrl_get_menu(u32 id) | |||
271 | static const char *mpeg_video_encoding[] = { | 272 | static const char *mpeg_video_encoding[] = { |
272 | "MPEG-1", | 273 | "MPEG-1", |
273 | "MPEG-2", | 274 | "MPEG-2", |
275 | "MPEG-4 AVC", | ||
274 | NULL | 276 | NULL |
275 | }; | 277 | }; |
276 | static const char *mpeg_video_aspect[] = { | 278 | static const char *mpeg_video_aspect[] = { |
@@ -358,7 +360,7 @@ int v4l2_ctrl_query_fill(struct v4l2_queryctrl *qctrl, s32 min, s32 max, s32 ste | |||
358 | /* MPEG controls */ | 360 | /* MPEG controls */ |
359 | case V4L2_CID_MPEG_CLASS: name = "MPEG Encoder Controls"; break; | 361 | case V4L2_CID_MPEG_CLASS: name = "MPEG Encoder Controls"; break; |
360 | case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: name = "Audio Sampling Frequency"; break; | 362 | case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: name = "Audio Sampling Frequency"; break; |
361 | case V4L2_CID_MPEG_AUDIO_ENCODING: name = "Audio Encoding Layer"; break; | 363 | case V4L2_CID_MPEG_AUDIO_ENCODING: name = "Audio Encoding"; break; |
362 | case V4L2_CID_MPEG_AUDIO_L1_BITRATE: name = "Audio Layer I Bitrate"; break; | 364 | case V4L2_CID_MPEG_AUDIO_L1_BITRATE: name = "Audio Layer I Bitrate"; break; |
363 | case V4L2_CID_MPEG_AUDIO_L2_BITRATE: name = "Audio Layer II Bitrate"; break; | 365 | case V4L2_CID_MPEG_AUDIO_L2_BITRATE: name = "Audio Layer II Bitrate"; break; |
364 | case V4L2_CID_MPEG_AUDIO_L3_BITRATE: name = "Audio Layer III Bitrate"; break; | 366 | case V4L2_CID_MPEG_AUDIO_L3_BITRATE: name = "Audio Layer III Bitrate"; break; |
@@ -493,7 +495,7 @@ int v4l2_ctrl_query_fill_std(struct v4l2_queryctrl *qctrl) | |||
493 | case V4L2_CID_MPEG_AUDIO_ENCODING: | 495 | case V4L2_CID_MPEG_AUDIO_ENCODING: |
494 | return v4l2_ctrl_query_fill(qctrl, | 496 | return v4l2_ctrl_query_fill(qctrl, |
495 | V4L2_MPEG_AUDIO_ENCODING_LAYER_1, | 497 | V4L2_MPEG_AUDIO_ENCODING_LAYER_1, |
496 | V4L2_MPEG_AUDIO_ENCODING_LAYER_3, 1, | 498 | V4L2_MPEG_AUDIO_ENCODING_AAC, 1, |
497 | V4L2_MPEG_AUDIO_ENCODING_LAYER_2); | 499 | V4L2_MPEG_AUDIO_ENCODING_LAYER_2); |
498 | case V4L2_CID_MPEG_AUDIO_L1_BITRATE: | 500 | case V4L2_CID_MPEG_AUDIO_L1_BITRATE: |
499 | return v4l2_ctrl_query_fill(qctrl, | 501 | return v4l2_ctrl_query_fill(qctrl, |
@@ -535,7 +537,7 @@ int v4l2_ctrl_query_fill_std(struct v4l2_queryctrl *qctrl) | |||
535 | case V4L2_CID_MPEG_VIDEO_ENCODING: | 537 | case V4L2_CID_MPEG_VIDEO_ENCODING: |
536 | return v4l2_ctrl_query_fill(qctrl, | 538 | return v4l2_ctrl_query_fill(qctrl, |
537 | V4L2_MPEG_VIDEO_ENCODING_MPEG_1, | 539 | V4L2_MPEG_VIDEO_ENCODING_MPEG_1, |
538 | V4L2_MPEG_VIDEO_ENCODING_MPEG_2, 1, | 540 | V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC, 1, |
539 | V4L2_MPEG_VIDEO_ENCODING_MPEG_2); | 541 | V4L2_MPEG_VIDEO_ENCODING_MPEG_2); |
540 | case V4L2_CID_MPEG_VIDEO_ASPECT: | 542 | case V4L2_CID_MPEG_VIDEO_ASPECT: |
541 | return v4l2_ctrl_query_fill(qctrl, | 543 | return v4l2_ctrl_query_fill(qctrl, |
diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h index 303d93ffd6b2..350aba2714fc 100644 --- a/include/linux/videodev2.h +++ b/include/linux/videodev2.h | |||
@@ -910,6 +910,7 @@ enum v4l2_mpeg_audio_encoding { | |||
910 | V4L2_MPEG_AUDIO_ENCODING_LAYER_1 = 0, | 910 | V4L2_MPEG_AUDIO_ENCODING_LAYER_1 = 0, |
911 | V4L2_MPEG_AUDIO_ENCODING_LAYER_2 = 1, | 911 | V4L2_MPEG_AUDIO_ENCODING_LAYER_2 = 1, |
912 | V4L2_MPEG_AUDIO_ENCODING_LAYER_3 = 2, | 912 | V4L2_MPEG_AUDIO_ENCODING_LAYER_3 = 2, |
913 | V4L2_MPEG_AUDIO_ENCODING_AAC = 3, | ||
913 | }; | 914 | }; |
914 | #define V4L2_CID_MPEG_AUDIO_L1_BITRATE (V4L2_CID_MPEG_BASE+102) | 915 | #define V4L2_CID_MPEG_AUDIO_L1_BITRATE (V4L2_CID_MPEG_BASE+102) |
915 | enum v4l2_mpeg_audio_l1_bitrate { | 916 | enum v4l2_mpeg_audio_l1_bitrate { |
@@ -992,8 +993,9 @@ enum v4l2_mpeg_audio_crc { | |||
992 | /* MPEG video */ | 993 | /* MPEG video */ |
993 | #define V4L2_CID_MPEG_VIDEO_ENCODING (V4L2_CID_MPEG_BASE+200) | 994 | #define V4L2_CID_MPEG_VIDEO_ENCODING (V4L2_CID_MPEG_BASE+200) |
994 | enum v4l2_mpeg_video_encoding { | 995 | enum v4l2_mpeg_video_encoding { |
995 | V4L2_MPEG_VIDEO_ENCODING_MPEG_1 = 0, | 996 | V4L2_MPEG_VIDEO_ENCODING_MPEG_1 = 0, |
996 | V4L2_MPEG_VIDEO_ENCODING_MPEG_2 = 1, | 997 | V4L2_MPEG_VIDEO_ENCODING_MPEG_2 = 1, |
998 | V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC = 2, | ||
997 | }; | 999 | }; |
998 | #define V4L2_CID_MPEG_VIDEO_ASPECT (V4L2_CID_MPEG_BASE+201) | 1000 | #define V4L2_CID_MPEG_VIDEO_ASPECT (V4L2_CID_MPEG_BASE+201) |
999 | enum v4l2_mpeg_video_aspect { | 1001 | enum v4l2_mpeg_video_aspect { |