mirror of
https://github.com/torvalds/linux.git
synced 2026-05-28 00:53:34 +02:00
serial: max310x: use i2c_get_match_data()
Use preferred i2c_get_match_data() instead of device_get_match_data() to get the driver match data. Suggested-by: Andy Shevchenko <andy.shevchenko@gmail.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Hugo Villeneuve <hvilleneuve@dimonoff.com> Link: https://lore.kernel.org/r/20240118152213.2644269-4-hugo@hugovil.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
60a389a5c8
commit
754500bf73
|
|
@ -1608,7 +1608,7 @@ static int max310x_i2c_probe(struct i2c_client *client)
|
|||
unsigned int i;
|
||||
u8 port_addr;
|
||||
|
||||
devtype = device_get_match_data(&client->dev);
|
||||
devtype = i2c_get_match_data(client);
|
||||
if (!devtype)
|
||||
return dev_err_probe(&client->dev, -ENODEV, "Failed to match device\n");
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user