Lines Matching refs:adap
20 * @adap: I2C adapter
29 struct i2c_adapter adap;
174 static int ec_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg i2c_msgs[],
177 struct ec_i2c_device *bus = adap->algo_data;
232 static u32 ec_i2c_functionality(struct i2c_adapter *adap)
269 bus->adap.owner = THIS_MODULE;
270 strscpy(bus->adap.name, "cros-ec-i2c-tunnel", sizeof(bus->adap.name));
271 bus->adap.algo = &ec_i2c_algorithm;
272 bus->adap.algo_data = bus;
273 bus->adap.dev.parent = &pdev->dev;
274 bus->adap.dev.of_node = pdev->dev.of_node;
275 bus->adap.retries = I2C_MAX_RETRIES;
276 ACPI_COMPANION_SET(&bus->adap.dev, ACPI_COMPANION(&pdev->dev));
278 err = i2c_add_adapter(&bus->adap);
290 i2c_del_adapter(&bus->adap);