Commit fd34cb08 authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab

[media] tuner/xc2028: Fix frequency offset for radio mode

In radio mode, no frequency offset should be used.

Instead of taking Thierry's patch that creates a separate function
to calculate the digital offset, it seemed better to just keep
everything at the same place.
Reported-by: default avatarThierry Reding <thierry.reding@avionic-design.de>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 4d37ece7
......@@ -940,11 +940,16 @@ static int generic_set_freq(struct dvb_frontend *fe, u32 freq /* in HZ */,
* that xc2028 will be in a safe state.
* Maybe this might also be needed for DTV.
*/
if (new_type == V4L2_TUNER_ANALOG_TV) {
switch (new_type) {
case V4L2_TUNER_ANALOG_TV:
rc = send_seq(priv, {0x00, 0x00});
/* Analog modes require offset = 0 */
} else {
/* Analog mode requires offset = 0 */
break;
case V4L2_TUNER_RADIO:
/* Radio mode requires offset = 0 */
break;
case V4L2_TUNER_DIGITAL_TV:
/*
* Digital modes require an offset to adjust to the
* proper frequency. The offset depends on what
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment