Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

media: dvb-frontends/stv0910: implement diseqc_send_burst

This implements the diseqc_send_burst frontend op to support sending
mini-DISEQC bursts. Picked up from dddvb's driver package where this
specific block was disabled via #if 0/#endif, but is still working
according to feedback from upstream, so add it.

Signed-off-by: Daniel Scheller <d.scheller@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>

authored by

Daniel Scheller and committed by
Mauro Carvalho Chehab
448461af 399196ed

+22
+22
drivers/media/dvb-frontends/stv0910.c
··· 1638 1638 return 0; 1639 1639 } 1640 1640 1641 + static int send_burst(struct dvb_frontend *fe, enum fe_sec_mini_cmd burst) 1642 + { 1643 + struct stv *state = fe->demodulator_priv; 1644 + u16 offs = state->nr ? 0x40 : 0; 1645 + u8 value; 1646 + 1647 + if (burst == SEC_MINI_A) { 1648 + write_reg(state, RSTV0910_P1_DISTXCFG + offs, 0x3F); 1649 + value = 0x00; 1650 + } else { 1651 + write_reg(state, RSTV0910_P1_DISTXCFG + offs, 0x3E); 1652 + value = 0xFF; 1653 + } 1654 + wait_dis(state, 0x40, 0x00); 1655 + write_reg(state, RSTV0910_P1_DISTXFIFO + offs, value); 1656 + write_reg(state, RSTV0910_P1_DISTXCFG + offs, 0x3A); 1657 + wait_dis(state, 0x20, 0x20); 1658 + 1659 + return 0; 1660 + } 1661 + 1641 1662 static int sleep(struct dvb_frontend *fe) 1642 1663 { 1643 1664 struct stv *state = fe->demodulator_priv; ··· 1694 1673 .set_tone = set_tone, 1695 1674 1696 1675 .diseqc_send_master_cmd = send_master_cmd, 1676 + .diseqc_send_burst = send_burst, 1697 1677 }; 1698 1678 1699 1679 static struct stv_base *match_base(struct i2c_adapter *i2c, u8 adr)