summaryrefslogtreecommitdiff
path: root/drivers/media/test-drivers/vidtv/vidtv_tuner.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>2020-09-13 12:01:23 +0300
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>2020-09-14 17:02:54 +0300
commit3e51a4965b9b9ab4fc6a7ecacc85816c7ebeeccb (patch)
tree8934444cb9d11ffcc7ce734a84167ef5a6d73376 /drivers/media/test-drivers/vidtv/vidtv_tuner.c
parent96230dc134f9c390c86e9df99809e9c88fb44c24 (diff)
downloadlinux-3e51a4965b9b9ab4fc6a7ecacc85816c7ebeeccb.tar.xz
media: vidtv: add basic support for DVBv5 stats
The current stats code is broken on so many ways. It ends reporting 0 for signal strengh, and the work queue doesn't run. If it would run, the code would crash. Fix such issues and add the minimum stuff for DVBv5 stats. Right now, only strength and cnr and UCB are implemented. pre/post BER stats will always return zero. Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers/media/test-drivers/vidtv/vidtv_tuner.c')
-rw-r--r--drivers/media/test-drivers/vidtv/vidtv_tuner.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/test-drivers/vidtv/vidtv_tuner.c b/drivers/media/test-drivers/vidtv/vidtv_tuner.c
index 13ce0a3ef43c..9bc49e099f65 100644
--- a/drivers/media/test-drivers/vidtv/vidtv_tuner.c
+++ b/drivers/media/test-drivers/vidtv/vidtv_tuner.c
@@ -246,7 +246,7 @@ vidtv_tuner_get_signal_strength(struct dvb_frontend *fe, u16 *strength)
* do a linear interpolation between 34dB and 10dB if we can't
* match against the table
*/
- *strength = 34 - 24 * shift / 100;
+ *strength = 34000 - 24000 * shift / 100;
return 0;
}