From 30e8ca2cb0ffd270a5c17366254c83cfb533ad14 Mon Sep 17 00:00:00 2001 From: Oliver Endriss Date: Sun, 13 Dec 2009 09:02:39 -0300 Subject: V4L/DVB (13674): stv090x: Add DiSEqC envelope mode Support DiSEqC envelope mode. Feature is enabled by setting config->diseqc_envelope_mode = true (default: disabled). Signed-off-by: Oliver Endriss Acked-by: Manu Abraham Signed-off-by: Mauro Carvalho Chehab --- drivers/media/dvb/frontends/stv090x.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'drivers/media/dvb/frontends/stv090x.c') diff --git a/drivers/media/dvb/frontends/stv090x.c b/drivers/media/dvb/frontends/stv090x.c index 48edd542242e..1573466a5c74 100644 --- a/drivers/media/dvb/frontends/stv090x.c +++ b/drivers/media/dvb/frontends/stv090x.c @@ -3597,7 +3597,8 @@ static int stv090x_send_diseqc_msg(struct dvb_frontend *fe, struct dvb_diseqc_ma reg = STV090x_READ_DEMOD(state, DISTXCTL); - STV090x_SETFIELD_Px(reg, DISTX_MODE_FIELD, 2); + STV090x_SETFIELD_Px(reg, DISTX_MODE_FIELD, + (state->config->diseqc_envelope_mode) ? 4 : 2); STV090x_SETFIELD_Px(reg, DISEQC_RESET_FIELD, 1); if (STV090x_WRITE_DEMOD(state, DISTXCTL, reg) < 0) goto err; @@ -3649,10 +3650,10 @@ static int stv090x_send_diseqc_burst(struct dvb_frontend *fe, fe_sec_mini_cmd_t reg = STV090x_READ_DEMOD(state, DISTXCTL); if (burst == SEC_MINI_A) { - mode = 3; + mode = (state->config->diseqc_envelope_mode) ? 5 : 3; value = 0x00; } else { - mode = 2; + mode = (state->config->diseqc_envelope_mode) ? 4 : 2; value = 0xFF; } -- cgit v1.2.3