Attention is currently required from: Raul Rangel, Matt DeVillier, Karthik Ramasubramanian. Tim Wawrzynczak has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/63211 )
Change subject: drivers/i2c/generic: Add support for i2c device detection ......................................................................
Patch Set 4:
(1 comment)
File src/drivers/i2c/generic/generic.c:
https://review.coreboot.org/c/coreboot/+/63211/comment/668e1d63_39c66fda PS4, Line 70: struct device *const busdev = i2c_busdev(dev); : if (busdev && busdev->ops->ops_i2c_bus->detect) { : if (!busdev->ops->ops_i2c_bus->detect(busdev, : dev->path.i2c.device)) { : printk(BIOS_SPEW, "%s: %s at %s -- NOT FOUND, skipping\n", path, : config->desc ? : dev->chip_ops->name, dev_path(dev)); : return; : } : } Looking at it now, it's not much more code at the client site to use the 0-byte write, e.g.:
``` struct device *const busdev = i2c_busdev(dev); if (busdev) { struct i2c_msg seg = { .slave = dev->path.i2c.device }; if (busdev->ops->ops_i2c_bus->transfer(busdev, &seg, 1)) { printk(BIOS_SPEW, "%s: %s at %s -- NOT FOUND, skipping\n", path, config->desc ? : dev->chip_ops->name, dev_path(dev)); return; } } ```