diff options
author | Maciej S. Szmigiero <mail@maciej.szmigiero.name> | 2018-07-02 17:23:24 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2018-07-04 09:49:27 -0400 |
commit | 010b876ae9a05307c138cd591555fcd8a0a0bf14 (patch) | |
tree | 2e84f47598ce070989dbba0a854f8c093a078e27 /drivers/media/tuners | |
parent | af16d0a132af47c60494c373100ff8952d557b01 (diff) | |
download | linux-010b876ae9a05307c138cd591555fcd8a0a0bf14.tar.bz2 |
media: tuner-simple: allow setting mono radio mode
For some types of tuners (Philips FMD1216ME(X) MK3 currently) we know that
letting TDA9887 output port 1 remain high (inactive) will switch FM radio
to mono mode.
Let's make use of this functionality - nothing changes for the default
stereo radio mode.
Tested on a Medion 95700 board which has a FMD1216ME tuner.
Signed-off-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers/media/tuners')
-rw-r--r-- | drivers/media/tuners/tuner-simple.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/media/tuners/tuner-simple.c b/drivers/media/tuners/tuner-simple.c index 36b88f820239..29c1473f2e9f 100644 --- a/drivers/media/tuners/tuner-simple.c +++ b/drivers/media/tuners/tuner-simple.c @@ -670,6 +670,7 @@ static int simple_set_radio_freq(struct dvb_frontend *fe, int rc, j; struct tuner_params *t_params; unsigned int freq = params->frequency; + bool mono = params->audmode == V4L2_TUNER_MODE_MONO; tun = priv->tun; @@ -736,8 +737,8 @@ static int simple_set_radio_freq(struct dvb_frontend *fe, config |= TDA9887_PORT2_ACTIVE; if (t_params->intercarrier_mode) config |= TDA9887_INTERCARRIER; -/* if (t_params->port1_set_for_fm_mono) - config &= ~TDA9887_PORT1_ACTIVE;*/ + if (t_params->port1_set_for_fm_mono && mono) + config &= ~TDA9887_PORT1_ACTIVE; if (t_params->fm_gain_normal) config |= TDA9887_GAIN_NORMAL; if (t_params->radio_if == 2) |