On Sat, Sep 02, 2023 at 10:09:36AM +0100, Biju Das wrote: > The driver has OF match table, still it uses ID lookup table for > retrieving match data. Currently the driver is working on the > assumption that a I2C device registered via OF will always match a > legacy I2C device ID. The correct approach is to have an OF device ID > table using of_device_match_data() if the devices are registered via OF. ... > - const struct i2c_device_id *id = i2c_client_get_device_id(client); > struct device *dev = &client->dev; > - unsigned int type = id->driver_data; > + unsigned int type; Now it's shorter than below line, so move it further. > struct mcp23s08 *mcp; > int ret; -- With Best Regards, Andy Shevchenko