struct dvb_frontend_ops contains a function pointer for reading signal strength from the demodulator, however, it would also be useful to be able to read the signal strength from the tuner, itself. As of now, in dvb_tuner_ops, we only have the following function for status: int (*get_status)(struct dvb_frontend *fe, u32 *status); The usability of this function is rather limited, and currently only provides a mechanism for reading a limited amount of bits. The current status bits are as follows: #define TUNER_STATUS_LOCKED 1 #define TUNER_STATUS_STEREO 2 ...this doesn't really lend itself for a useful signal strength reading. I can cite two examples of how this would be useful in the current codebase: 1) Some demodulators do not directly provide signal strength readings. For example, lgdt330x. In order to provide some sort of measurement, other values are used to arrive at an estimated reading. If we had a read_signal_strength function available from the tuner driver, such demodulator drivers that are otherwise unable to provide this functionality directly would be able to read the signal strength from the tuner driver, and either pass on that value, or use it in its calculation of status readings. 2) The analog tuner system accesses the tuner modules directly, and would benefit greatly from having such functionality available to be able to read signal strength from the tuner. I propose the following addition to the internal API. Please respond with an ack, and / or any comments that you may have: [PATCH] add "read_signal_strength" function to dvb_tuner_ops Signed-off-by: Michael Krufky <mkrufky@xxxxxxxxxxx> --- linux/drivers/media/dvb/dvb-core/dvb_frontend.h | 1 + 1 file changed, 1 insertion(+) --- v4l-dvb.orig/linux/drivers/media/dvb/dvb-core/dvb_frontend.h +++ v4l-dvb/linux/drivers/media/dvb/dvb-core/dvb_frontend.h @@ -92,6 +92,7 @@ #define TUNER_STATUS_LOCKED 1 #define TUNER_STATUS_STEREO 2 int (*get_status)(struct dvb_frontend *fe, u32 *status); + int (*read_signal_strength)(struct dvb_frontend* fe, u16* strength); /** These are provided seperately from set_params in order to facilitate silicon * tuners which require sophisticated tuning loops, controlling each parameter seperately. */ _______________________________________________ linux-dvb mailing list linux-dvb@xxxxxxxxxxx http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb