From 1e8f31f31726148c27de1ff4692c76c9bcff9860 Mon Sep 17 00:00:00 2001 From: Antti Palosaari Date: Thu, 19 Jul 2012 21:10:36 -0300 Subject: [media] cxd2820r: use Kernel GPIO for GPIO access Currently there is LNA behind cxd2820r demodulator GPIO. Use Kernel GPIO interface to access those GPIOs. Signed-off-by: Antti Palosaari Signed-off-by: Mauro Carvalho Chehab --- drivers/media/dvb-frontends/cxd2820r_priv.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'drivers/media/dvb-frontends/cxd2820r_priv.h') diff --git a/drivers/media/dvb-frontends/cxd2820r_priv.h b/drivers/media/dvb-frontends/cxd2820r_priv.h index 9396492119ca..7ff5f60c83e1 100644 --- a/drivers/media/dvb-frontends/cxd2820r_priv.h +++ b/drivers/media/dvb-frontends/cxd2820r_priv.h @@ -26,6 +26,7 @@ #include "dvb_frontend.h" #include "dvb_math.h" #include "cxd2820r.h" +#include struct reg_val_mask { u32 reg; @@ -41,7 +42,11 @@ struct cxd2820r_priv { bool ber_running; u8 bank[2]; - u8 gpio[3]; +#define GPIO_COUNT 3 + u8 gpio[GPIO_COUNT]; +#ifdef CONFIG_GPIOLIB + struct gpio_chip gpio_chip; +#endif fe_delivery_system_t delivery_system; bool last_tune_failed; /* for switch between T and T2 tune */ @@ -51,7 +56,7 @@ struct cxd2820r_priv { extern int cxd2820r_debug; -int cxd2820r_gpio(struct dvb_frontend *fe); +int cxd2820r_gpio(struct dvb_frontend *fe, u8 *gpio); int cxd2820r_wr_reg_mask(struct cxd2820r_priv *priv, u32 reg, u8 val, u8 mask); -- cgit v1.2.3-59-g8ed1b