mbox series

[v3,00/14] si2157: Analog tuning and optimizations

Message ID 20191114200408.28883-1-brad@nextdimension.cc (mailing list archive)
Headers show
Series si2157: Analog tuning and optimizations | expand

Message

Brad Love Nov. 14, 2019, 8:03 p.m. UTC
This series mainly enables analog tuning in the si2157
driver. Some various optimizations are included as well,
along with the dots connected to allow devices with
TUNER_ABSENT to utilize an analog frontend on two different
bridges. Finally two missing statistics are added to get
signal strength and CNR on a tuner and demod respectively.

Summary:
- Enable tuner status flags
- Check tuner status flags
- String cleanup and register labeling
- The analog tuning functions in si2157
- A function to wait for set_*params to complete
- Enable analog fe on TUNER_ABSENT devices in cx231xx and cx23885
- Include some signal strength DVBv5 stats

Now the two patches that 'Add i2c device analog tuner support'
I would like comment on. It looks quite ugly to have big case
statements identifying the TUNER_ABSENT models that have analog.
There is nothing unique done in the blocks, mostly. Right now
there is only a few models, but the addition of more would become
a bit excessive.

Instead of the case statement should a board profile field be
added to the two affected drivers? Something like .has_i2c_analog_fe ?

===

I split up the tune completion and tune lock (5 & 6) patches. Patch 5
should be acceptable, patch 6 has been found to be very insightful in
debugging situations.

Changes since v2:
- Rebase
- Enable HVR5525 analog tuner
- Remove bff option from NTSC analog capable boards
- Split tune completion and tuner lock patches
- Fix si2141 init with error status flags enabled
- Device caps and capabilities fixes

Changes since v1:
- One unnecessary patch removed
- __func__ removed from dev_XXX macros
- normalization logic simplified and explained in rf strength calculation

Brad Love (14):
  si2157: Enable tuner status flags
  si2157: Check error status bit on cmd execute
  si2157: Better check for running tuner in init
  si2157: Add analog tuning related functions
  si2157: Briefly wait for tuning operation to complete
  si2157: module debug option to wait on signal lock
  cx23885: Add analog frontend to Hauppauge QuadHD
  cx23885: Add analog frontend to 1265_K4
  cx23885: Add analog frontend to HVR5525
  cx23885: Add i2c device analog tuner support
  cx231xx: Add i2c device analog tuner support
  si2157: add on-demand rf strength func
  lgdt3306a: Add CNR v5 stat
  cx25840: Register labeling, chip specific correction

 drivers/media/dvb-frontends/lgdt3306a.c    |  14 +
 drivers/media/i2c/cx25840/cx25840-core.c   |  40 +-
 drivers/media/pci/cx23885/cx23885-cards.c  |  51 ++-
 drivers/media/pci/cx23885/cx23885-dvb.c    |  31 ++
 drivers/media/pci/cx23885/cx23885-video.c  |  98 ++++-
 drivers/media/tuners/si2157.c              | 415 ++++++++++++++++++++-
 drivers/media/tuners/si2157_priv.h         |   2 +
 drivers/media/usb/cx231xx/cx231xx-avcore.c |  35 +-
 drivers/media/usb/cx231xx/cx231xx-video.c  |  85 ++++-
 9 files changed, 697 insertions(+), 74 deletions(-)