linux_dsm_epyc7002/drivers/media
Mauro Carvalho Chehab 70315b3eaf [media] dib8000: Don't let tuner hang due to a call to get_frontend()
Both dvbv5-scan and dvbv5-zap tools call FE_GET_PROPERTY inside the
loop that checks for stats. If the frontend doesn't support DVBv5, it
falls back to call the DVBv5 stats APIs(FE_READ_BER, FE_READ_SIGNAL,
FE_READ_SNR and FE_READ_UNCORRECTED_BLOCKS).

A call to FE_GET_PROPERTY makes dvb-frontend core to call get_frontend().

However, due to a race condition on dib8000 between dib8000_get_frontend
and dib8000_tune, if get_frontend occurs too early, it causes the
tune state machine to fail and not get any lock.

This patch adds a workaround code that makes get_frontend() to just
return if none of the frontends have a SYNC. This change fixed the issue
with dvbv5-scan/dvbv5-zap, but a fine-tuned logic might be needed in
the future, when we implement DVBv5 stats on this frontend.

The procedure to test the bug and the fix is the one below:

1) tune into a non-existing frequency with:

	$ dvbv5-zap -I dvbv5 -c non_existing_freqs -m 679142857 -t3

2) tune/lock into an existing frequency with:

	$ dvbv5-zap -I dvbv5 -c isdb-test -m 479142857
    or
	$ dvbv5-scan isdb-test

In this case, 679 MHz carrier doesn't exist. Only 479 MHz does.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Acked-by: Patrick Boettcher <pboettcher@kernellabs.com>
2013-12-19 08:17:43 -02:00
..
common [media] media_tree: Fix spelling errors 2013-12-09 14:50:50 -02:00
dvb-core [media] it913x: Add support for Avermedia H335 id 0x0335 2013-12-18 10:27:53 -02:00
dvb-frontends [media] dib8000: Don't let tuner hang due to a call to get_frontend() 2013-12-19 08:17:43 -02:00
firewire
i2c Merge branch 'upstream-fixes' into patchwork 2013-12-13 05:04:00 -02:00
mmc
parport
pci Merge branch 'upstream-fixes' into patchwork 2013-12-13 05:04:00 -02:00
platform [media] s5p-jpeg: Adjust g_volatile_ctrl callback to Exynos4x12 needs 2013-12-18 11:51:47 -02:00
radio [media] radio-raremono: add support for 'Thanko's Raremono' AM/FM/SW USB device 2013-12-18 11:30:32 -02:00
rc [media] mceusb: Add Hauppauge WinTV-HVR-930C HD 2013-12-10 15:33:52 -02:00
tuners [media] media_tree: Fix spelling errors 2013-12-09 14:50:50 -02:00
usb [media] it913x: Add support for Avermedia H335 id 0x0335 2013-12-18 10:27:53 -02:00
v4l2-core [media] v4l: of: Drop endpoint node reference in v4l2_of_get_remote_port() 2013-12-18 06:26:20 -02:00
Kconfig
Makefile
media-device.c
media-devnode.c
media-entity.c [media] media: Check for active links on pads with MEDIA_PAD_FL_MUST_CONNECT flag 2013-12-04 15:03:45 -02:00