Lines Matching defs:slave
164 * running for less time, max slave read per tasklet is set to 10 bytes.
206 struct i2c_client *slave;
222 /* tasklet to process slave rx data */
236 static int bcm_iproc_i2c_reg_slave(struct i2c_client *slave);
237 static int bcm_iproc_i2c_unreg_slave(struct i2c_client *slave);
300 /* Maximum slave stretch time */
306 /* Configure the slave address */
310 val |= (iproc_i2c->slave->addr << S_CFG_NIC_SMB_ADDR3_SHIFT);
313 /* clear all pending slave interrupts */
338 dev_err(iproc_i2c->device, "slave random stretch time timeout\n");
360 i2c_slave_event(iproc_i2c->slave,
367 i2c_slave_event(iproc_i2c->slave,
373 i2c_slave_event(iproc_i2c->slave,
377 i2c_slave_event(iproc_i2c->slave, I2C_SLAVE_STOP,
403 * IS_S_START_BUSY_SHIFT event. Hence start slave data send
406 * This means don't send any data from slave when
408 * eeprom or other backend slave driver read pointer twice.
417 /* clear slave interrupt */
419 /* enable slave interrupts */
441 /* disable slave interrupts */
465 i2c_slave_event(iproc_i2c->slave,
470 i2c_slave_event(iproc_i2c->slave,
506 i2c_slave_event(iproc_i2c->slave, I2C_SLAVE_STOP, &value);
513 /* check slave transmit status only if slave is transmitting */
636 /* process only slave interrupt which are enabled */
835 /* format and load slave address into the TX FIFO */
842 * has been used up by the slave address
864 * The last byte to be sent out should be a slave
1063 /* no slave support */
1186 static int bcm_iproc_i2c_reg_slave(struct i2c_client *slave)
1188 struct bcm_iproc_i2c_dev *iproc_i2c = i2c_get_adapdata(slave->adapter);
1190 if (iproc_i2c->slave)
1193 if (slave->flags & I2C_CLIENT_TEN)
1196 iproc_i2c->slave = slave;
1205 static int bcm_iproc_i2c_unreg_slave(struct i2c_client *slave)
1208 struct bcm_iproc_i2c_dev *iproc_i2c = i2c_get_adapdata(slave->adapter);
1210 if (!iproc_i2c->slave)
1215 /* disable all slave interrupts */
1223 /* Erase the slave address programmed */
1232 /* clear all pending slave interrupts */
1235 iproc_i2c->slave = NULL;