Lines Matching refs:input
70 struct ddb_input *input = fe->sec_priv; in max_send_master_cmd() local
71 struct ddb_port *port = input->port; in max_send_master_cmd()
73 struct ddb_dvb *dvb = &port->dvb[input->nr & 1]; in max_send_master_cmd()
84 ddbwritel(dev, 0, tag | LNB_BUF_LEVEL(dvb->input)); in max_send_master_cmd()
86 ddbwritel(dev, cmd->msg[i], tag | LNB_BUF_WRITE(dvb->input)); in max_send_master_cmd()
87 lnb_command(dev, port->lnr, dvb->input, LNB_CMD_DISEQC); in max_send_master_cmd()
92 static int lnb_send_diseqc(struct ddb *dev, u32 link, u32 input, in lnb_send_diseqc() argument
98 ddbwritel(dev, 0, tag | LNB_BUF_LEVEL(input)); in lnb_send_diseqc()
100 ddbwritel(dev, cmd->msg[i], tag | LNB_BUF_WRITE(input)); in lnb_send_diseqc()
101 lnb_command(dev, link, input, LNB_CMD_DISEQC); in lnb_send_diseqc()
105 static int lnb_set_sat(struct ddb *dev, u32 link, u32 input, u32 sat, u32 band, in lnb_set_sat() argument
114 return lnb_send_diseqc(dev, link, input, &cmd); in lnb_set_sat()
117 static int lnb_set_tone(struct ddb *dev, u32 link, u32 input, in lnb_set_tone() argument
121 u32 mask = (1ULL << input); in lnb_set_tone()
127 dev->link[link].lnb.tone &= ~(1ULL << input); in lnb_set_tone()
132 dev->link[link].lnb.tone |= (1ULL << input); in lnb_set_tone()
139 s = lnb_command(dev, link, input, LNB_CMD_NOP); in lnb_set_tone()
143 static int lnb_set_voltage(struct ddb *dev, u32 link, u32 input, in lnb_set_voltage() argument
148 if (dev->link[link].lnb.oldvoltage[input] == voltage) in lnb_set_voltage()
152 if (dev->link[link].lnb.voltage[input]) in lnb_set_voltage()
154 lnb_command(dev, link, input, LNB_CMD_OFF); in lnb_set_voltage()
157 lnb_command(dev, link, input, LNB_CMD_LOW); in lnb_set_voltage()
160 lnb_command(dev, link, input, LNB_CMD_HIGH); in lnb_set_voltage()
166 dev->link[link].lnb.oldvoltage[input] = voltage; in lnb_set_voltage()
172 struct ddb_input *input = fe->sec_priv; in max_set_input_unlocked() local
173 struct ddb_port *port = input->port; in max_set_input_unlocked()
175 struct ddb_dvb *dvb = &port->dvb[input->nr & 1]; in max_set_input_unlocked()
180 if (dvb->input != in) { in max_set_input_unlocked()
181 u32 bit = (1ULL << input->nr); in max_set_input_unlocked()
183 dev->link[port->lnr].lnb.voltage[dvb->input & 3] & bit; in max_set_input_unlocked()
185 dev->link[port->lnr].lnb.voltage[dvb->input & 3] &= ~bit; in max_set_input_unlocked()
186 dvb->input = in; in max_set_input_unlocked()
187 dev->link[port->lnr].lnb.voltage[dvb->input & 3] |= obit; in max_set_input_unlocked()
195 struct ddb_input *input = fe->sec_priv; in max_set_tone() local
196 struct ddb_port *port = input->port; in max_set_tone()
198 struct ddb_dvb *dvb = &port->dvb[input->nr & 1]; in max_set_tone()
209 res = lnb_set_tone(dev, port->lnr, dvb->input, tone); in max_set_tone()
233 struct ddb_input *input = fe->sec_priv; in max_set_voltage() local
234 struct ddb_port *port = input->port; in max_set_voltage()
236 struct ddb_dvb *dvb = &port->dvb[input->nr & 1]; in max_set_voltage()
252 dev->link[port->lnr].lnb.voltage[dvb->input] &= in max_set_voltage()
253 ~(1ULL << input->nr); in max_set_voltage()
255 dev->link[port->lnr].lnb.voltage[dvb->input] |= in max_set_voltage()
256 (1ULL << input->nr); in max_set_voltage()
258 res = lnb_set_voltage(dev, port->lnr, dvb->input, voltage); in max_set_voltage()
264 ~(1ULL << input->nr); in max_set_voltage()
267 (1ULL << input->nr); in max_set_voltage()
399 int ddb_fe_attach_mxl5xx(struct ddb_input *input) in ddb_fe_attach_mxl5xx() argument
401 struct ddb *dev = input->port->dev; in ddb_fe_attach_mxl5xx()
402 struct i2c_adapter *i2c = &input->port->i2c->adap; in ddb_fe_attach_mxl5xx()
403 struct ddb_dvb *dvb = &input->port->dvb[input->nr & 1]; in ddb_fe_attach_mxl5xx()
404 struct ddb_port *port = input->port; in ddb_fe_attach_mxl5xx()
413 demod = input->nr; in ddb_fe_attach_mxl5xx()
431 if (input->nr < 4) { in ddb_fe_attach_mxl5xx()
432 lnb_command(dev, port->lnr, input->nr, LNB_CMD_INIT); in ddb_fe_attach_mxl5xx()
433 lnb_set_voltage(dev, port->lnr, input->nr, SEC_VOLTAGE_OFF); in ddb_fe_attach_mxl5xx()
443 dvb->fe->sec_priv = input; in ddb_fe_attach_mxl5xx()
444 dvb->input = tuner; in ddb_fe_attach_mxl5xx()
451 int ddb_fe_attach_mci(struct ddb_input *input, u32 type) in ddb_fe_attach_mci() argument
453 struct ddb *dev = input->port->dev; in ddb_fe_attach_mci()
454 struct ddb_dvb *dvb = &input->port->dvb[input->nr & 1]; in ddb_fe_attach_mci()
455 struct ddb_port *port = input->port; in ddb_fe_attach_mci()
460 demod = input->nr; in ddb_fe_attach_mci()
471 dvb->fe = ddb_mci_attach(input, &cfg, demod, &dvb->set_input); in ddb_fe_attach_mci()
480 if (input->nr < 4) { in ddb_fe_attach_mci()
481 lnb_command(dev, port->lnr, input->nr, LNB_CMD_INIT); in ddb_fe_attach_mci()
482 lnb_set_voltage(dev, port->lnr, input->nr, SEC_VOLTAGE_OFF); in ddb_fe_attach_mci()
492 dvb->fe->sec_priv = input; in ddb_fe_attach_mci()
493 dvb->input = tuner; in ddb_fe_attach_mci()