From: Mauro Carvalho Chehab <mchehab@redhat.com>
To: "Miroslav Slugeň" <thunder.mmm@gmail.com>
Cc: linux-media@vger.kernel.org, Hans Verkuil <hverkuil@xs4all.nl>
Subject: Re: cx25840: allow setting radio audio mode stereo/mono
Date: Tue, 28 Feb 2012 14:29:06 -0300 [thread overview]
Message-ID: <4F4D0EE2.4030908@redhat.com> (raw)
In-Reply-To: <CAEN_-SB9X_3OrLAG7D6kotprtu6Xza3=XSeVZFsV937tWJK3yQ@mail.gmail.com>
Em 16-01-2012 13:32, Miroslav Slugeň escreveu:
>
> cx25840_s_tuner_radio_support.patch
Signed-off-by: is missing.
>
>
> Signed-off-by: Miroslav Slugen <thunder.mmm@gmail.com>
> From: Miroslav Slugen <thunder.mmm@gmail.com>
> Date: Mon, 12 Dec 2011 00:19:34 +0100
> Subject: [PATCH] cx25840_s_tuner should support also radio mode for setting
> stereo and mono.
>
> ---
> diff -Naurp a/drivers/media/video/cx25840/cx25840-core.c b/drivers/media/video/cx25840/cx25840-core.c
> --- a/drivers/media/video/cx25840/cx25840-core.c 2012-01-12 20:42:45.000000000 +0100
> +++ b/drivers/media/video/cx25840/cx25840-core.c 2012-01-16 16:18:06.181583026 +0100
> @@ -1628,9 +1628,14 @@ static int cx25840_s_tuner(struct v4l2_s
> struct cx25840_state *state = to_state(sd);
> struct i2c_client *client = v4l2_get_subdevdata(sd);
>
> - if (state->radio || is_cx2583x(state))
> + if (is_cx2583x(state))
> return 0;
>
> + /* FM radio supports only mono and stereo modes */
> + if ((state->radio) &&
> + (vt->audmode != V4L2_TUNER_MODE_MONO) &&
> + (vt->audmode != V4L2_TUNER_MODE_STEREO)) return -EINVAL;
> +
Well, this is true for all radio devices: only mono/stereo modes are supported.
A check like that probably makes sense at the V4L2 core [1], as otherwise, the
same test would be needed on all radio drivers.
[1] drivers/media/video/v4l2-ioctl.c
Regards,
Mauro
> switch (vt->audmode) {
> case V4L2_TUNER_MODE_MONO:
> /* mono -> mono
> -- 1.7.2.3
>
prev parent reply other threads:[~2012-02-28 17:29 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-16 15:32 cx25840: allow setting radio audio mode stereo/mono Miroslav Slugeň
2012-02-28 17:29 ` Mauro Carvalho Chehab [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4F4D0EE2.4030908@redhat.com \
--to=mchehab@redhat.com \
--cc=hverkuil@xs4all.nl \
--cc=linux-media@vger.kernel.org \
--cc=thunder.mmm@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.