aboutsummaryrefslogtreecommitdiff
path: root/drivers/media/dvb/frontends/tda18271-fe.c
AgeCommit message (Collapse)Author
2008-04-29V4L/DVB(7767): Move tuners to common/tunersMauro Carvalho Chehab
There were several issues in the past, caused by the hybrid tuner design, since now, the same tuner can be used by drivers/media/dvb and drivers/media/video. Kconfig items were rearranged, to split V4L/DVB core from their drivers. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7481): tda18271: fix standard map debugMichael Krufky
Show IF level and rf agc top settings in standard map dumps. Dump standard map during attach if DBG_MAP or DBG_ADV is set. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7437): tda18271: increment module version minorMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7436): tda18271: add basic support for slave tuner configurationsMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7435): tda18271: add function tda18271_charge_pump_sourceMichael Krufky
Force the main pll charge pump or cal pll charge pump to source current to the main pll loop filter or cal pll loop filter, respectively. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7434): tda18271: set rfagc modes during channel configurationMichael Krufky
Set rfagc to high speed mode before setting the pll. Set rfagc to normal speed mode at the end of the function. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7433): tda18271: fix comparison bug in tda18271_powerscanMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7432): tda18271: allow device-specific configuration of rf agc topMichael Krufky
allow device-specific configuration of rf agc rf top and if top Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7431): tda18271: allow device-specific configuration of IF levelMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7430): tda18271: fix typo in tda18271_calibrate_rfMichael Krufky
The internal calibration signal must be set on the cal pll. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7385): tda18271: store agc_mode configuration independently of std_bitsMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7384): tda18271: store FM_RFn setting in struct tda18271_std_map_itemMichael Krufky
All standard related configuration is stored within struct tda18271_std_map_item. Pass a pointer to this structure rather than its individual members. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7383): tda18271: add attach-time parameter to limit i2c transfer sizeMichael Krufky
Add attach-time parameter, "small_i2c" to limit i2c transfer size to write at most 16 registers at a time during initialization. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7214): tda18271: move init functions to directly above tda18271_tuneMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7213): tda18271: consolidate tune functionsMichael Krufky
combine tda18271c1_tune and tda18271c2_tune into a single function Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7212): tda18271: move rf calibration code from tda18271c1_tune into ↵Michael Krufky
a new function move rf calibration code from tda18271c1_tune into a new function, tda18271c1_rf_tracking_filter_calibration Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7211): tda18271: remove duplicated channel configuration code from ↵Michael Krufky
tda18271c1_tune remove duplicated channel configuration code from tda18271c1_tune, instead call function tda18271_channel_configuration Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-24V4L/DVB (7136): tda18271: use hybrid_tuner_request_state to manage tuner ↵Michael Krufky
instances Convert tda18271 to use the new hybrid_tuner_request_state and hybrid_tuner_release_state macros to manage state sharing between hybrid tuner instances. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (7052): tda18271: when tuning digital, the analog demod must be ↵Michael Krufky
tri-stated Call analog_ops.standby during tda18271_set_params, to put the tda8295 in tri-state when tuning digital channels. Otherwise the tda8295 will interfere with the signal coming from the tda18271 into the digital demodulator. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (7032): tda18271: tda18271_cal_on_startup should be declared staticMichael Krufky
This module option variable is only handled within the file tda18271-fe.c - Declare this variable as static. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (7029): tda18271: provide a choice whether to perform rf cal on init ↵Michael Krufky
or on first tune If module option "cal" is set to 1, the ~22 sec rf tracking filter calibration sequence will be invoked on startup. Otherwise, the calibration will take place during the first tune. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (7028): tda18271: test RF_CAL_OK to see if we need additional RF ↵Michael Krufky
calibration Test RF_CAL_OK to see if we need to perform the RF tracking filter calibration after returning from standby. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (7027): tda18271: put the device in standby mode during sleep()Michael Krufky
Add function, tda18271_set_standby_mode. During sleep, enter standby mode with slave tuner output enabled, loop through on and xtal oscillator on. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (7026): tda18271: report when the RF tracking filter calibration has ↵Michael Krufky
completed Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6988): tda18271: give calibration debug a separate debug maskMichael Krufky
We don't usually want to see the calibration debug messages, but sometimes it is useful. Assign it to a separate debug mask. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6987): tda18271: add support for fm radioMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6986): tda18271: share state between analog and digital tuner instancesMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6979): tda18271: use a mutex to protect state in critical sectionsMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6978): tda18271: store frequency and bandwidth after successful tuneMichael Krufky
Store last tuned frequency & bandwidth after successful tune. Clean up tune functions -- remove pointer to tune function in state structure, instead call tune function based on priv->id. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6977): tda18271: clean up calibration initialization proceduresMichael Krufky
Always initialize registers during attach. Perform IR Calibration during init if needed. Perform RF Calibration during init if needed for C2, only. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6964): tda18271: document debug level and configuration parametersMichael Krufky
Document debug level module options and tda18271_config attach-time parameters. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6963): tda18271: store IF frequency in a u16 instead of u32Michael Krufky
Store IF Frequency in a u16 instead of a u32. Multiply by 1000 before use. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6962): tda18271: allow device-specific configuration of IF ↵Michael Krufky
frequency and std bits Allow drivers to pass device-specific configuration parameters during attach. If these parameters are omitted, default values will be used. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6961): tda18271: move common code to tda18271-common.cMichael Krufky
Move some common code to a new file to make this easier to look at. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6960): tda18271: add support for NXP TDA18271HD/C2Michael Krufky
Tested successfully with QAM256 digital cable. Analog television is limping, needs more work. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6959): tda18271: add MODULE_VERSIONMichael Krufky
version 0.1 Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6958): tda18271: clean up function tda18271_set_analog_paramsMichael Krufky
make set_analog_params function look consistent with set_params function Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6957): tda18271: fail table lookups if frequency is out of rangeMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6928): tda18271: break calculation functions out of tda18271_tuneMichael Krufky
Break out the following new functions from tda18271_tune: tda18271_calc_bp_filter tda18271_calc_km tda18271_calc_rf_band tda18271_calc_gain_taper tda18271_calc_ir_measure tda18271_calc_rf_cal Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6927): tda18271: improve printk macrosMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6926): tda18271: consolidate table lookup functionsMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6925): tda18271: move state structures to tda18271-priv.hMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6923): tda18271: remove extraneous debugMichael Krufky
We don't need to do a dbg_info during tda18271_attach anymore, since the tda18271_get_id function will call dbg_info with the same information and more. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6907): tda18271: create separate calc_pll functionsMichael Krufky
Consolidate duplicated code by creating functions: tda18271_calc_main_pll tda18271_calc_cal_pll Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6906): tda18271: rename tda18271_calc_* functions to tda18271_lookup_*Michael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6905): tda18271: check ID register during attachMichael Krufky
Identify the silicon during attach, return NULL if unsupported device. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6904): tda18271: divider byte 1, bit 7 is always 0Michael Krufky
Bit 7 of both Main Divider byte 1 and Cal Divider byte 1 is always zero. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6890): tda18271: fix typo in RF tracking filter calibrationMichael Krufky
We want to set bits 1 & 2 on easy programming byte 4, not extended byte 4. Thanks to David Wong for pointing this out. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Cc: David Wong <davidtlwong@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6881): include struct analog_demod_ops directly inside struct ↵Michael Krufky
dvb_frontend Rather than using a pointer, include struct analog_demod_ops directly inside struct dvb_frontend. This will allow us to use dvb_attach in the future, along with removing the need to check the ops structure before having to check the pointer to the method being called. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-25V4L/DVB (6880): kill tuner-driver.hMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>