aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/tuners/m88ts2022.c
diff options
context:
space:
mode:
authorAntti Palosaari <crope@iki.fi>2014-08-21 18:32:28 -0300
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-09-08 10:00:55 -0300
commitf461694b965b8cdf67c330d14c802a74acf7bec1 (patch)
tree086e882655feb52ccba35f67aef9d544099a3672 /drivers/media/tuners/m88ts2022.c
parent[media] m88ts2022: convert to RegMap I2C API (diff)
downloadlinux-dev-f461694b965b8cdf67c330d14c802a74acf7bec1.tar.xz
linux-dev-f461694b965b8cdf67c330d14c802a74acf7bec1.zip
[media] m88ts2022: change parameter type of m88ts2022_cmd
It is driver internal function and does not need anything from frontend structure. Due to that change parameter type to driver state which is better for driver internal functions. Also remove one unused variable from state itself. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media/tuners/m88ts2022.c')
-rw-r--r--drivers/media/tuners/m88ts2022.c21
1 files changed, 10 insertions, 11 deletions
diff --git a/drivers/media/tuners/m88ts2022.c b/drivers/media/tuners/m88ts2022.c
index 9f7ebcfc2fa1..caa542346891 100644
--- a/drivers/media/tuners/m88ts2022.c
+++ b/drivers/media/tuners/m88ts2022.c
@@ -18,10 +18,9 @@
#include "m88ts2022_priv.h"
-static int m88ts2022_cmd(struct dvb_frontend *fe,
- int op, int sleep, u8 reg, u8 mask, u8 val, u8 *reg_val)
+static int m88ts2022_cmd(struct m88ts2022_dev *dev, int op, int sleep, u8 reg,
+ u8 mask, u8 val, u8 *reg_val)
{
- struct m88ts2022_dev *dev = fe->tuner_priv;
int ret, i;
unsigned int utmp;
struct m88ts2022_reg_val reg_vals[] = {
@@ -124,7 +123,7 @@ static int m88ts2022_set_params(struct dvb_frontend *fe)
dev->frequency_khz, dev->frequency_khz - c->frequency,
f_vco_khz, pll_n, div_ref, div_out);
- ret = m88ts2022_cmd(fe, 0x10, 5, 0x15, 0x40, 0x00, NULL);
+ ret = m88ts2022_cmd(dev, 0x10, 5, 0x15, 0x40, 0x00, NULL);
if (ret)
goto err;
@@ -142,7 +141,7 @@ static int m88ts2022_set_params(struct dvb_frontend *fe)
if (ret)
goto err;
- ret = m88ts2022_cmd(fe, 0x10, 5, 0x15, 0x40, 0x00, NULL);
+ ret = m88ts2022_cmd(dev, 0x10, 5, 0x15, 0x40, 0x00, NULL);
if (ret)
goto err;
}
@@ -158,7 +157,7 @@ static int m88ts2022_set_params(struct dvb_frontend *fe)
goto err;
}
- ret = m88ts2022_cmd(fe, 0x08, 5, 0x3c, 0xff, 0x00, NULL);
+ ret = m88ts2022_cmd(dev, 0x08, 5, 0x3c, 0xff, 0x00, NULL);
if (ret)
goto err;
@@ -185,7 +184,7 @@ static int m88ts2022_set_params(struct dvb_frontend *fe)
if (ret)
goto err;
- ret = m88ts2022_cmd(fe, 0x04, 2, 0x26, 0xff, 0x00, &u8tmp);
+ ret = m88ts2022_cmd(dev, 0x04, 2, 0x26, 0xff, 0x00, &u8tmp);
if (ret)
goto err;
@@ -195,7 +194,7 @@ static int m88ts2022_set_params(struct dvb_frontend *fe)
if (ret)
goto err;
- ret = m88ts2022_cmd(fe, 0x04, 2, 0x26, 0xff, 0x00, &u8tmp);
+ ret = m88ts2022_cmd(dev, 0x04, 2, 0x26, 0xff, 0x00, &u8tmp);
if (ret)
goto err;
@@ -227,7 +226,7 @@ static int m88ts2022_set_params(struct dvb_frontend *fe)
if (ret)
goto err;
- ret = m88ts2022_cmd(fe, 0x04, 2, 0x26, 0xff, 0x00, &u8tmp);
+ ret = m88ts2022_cmd(dev, 0x04, 2, 0x26, 0xff, 0x00, &u8tmp);
if (ret)
goto err;
@@ -237,7 +236,7 @@ static int m88ts2022_set_params(struct dvb_frontend *fe)
if (ret)
goto err;
- ret = m88ts2022_cmd(fe, 0x04, 2, 0x26, 0xff, 0x00, &u8tmp);
+ ret = m88ts2022_cmd(dev, 0x04, 2, 0x26, 0xff, 0x00, &u8tmp);
if (ret)
goto err;
@@ -257,7 +256,7 @@ static int m88ts2022_set_params(struct dvb_frontend *fe)
if (ret)
goto err;
- ret = m88ts2022_cmd(fe, 0x01, 20, 0x21, 0xff, 0x00, NULL);
+ ret = m88ts2022_cmd(dev, 0x01, 20, 0x21, 0xff, 0x00, NULL);
if (ret)
goto err;
err: