Commit 0712cb93 authored by Uwe Kleine-König's avatar Uwe Kleine-König Committed by Lee Jones

leds: lm355x: Convert to i2c's .probe_new()

.probe_new() doesn't get the i2c_device_id * parameter, so determine
that explicitly in the probe function.
Signed-off-by: default avatarUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: default avatarLee Jones <lee@kernel.org>
Link: https://lore.kernel.org/r/20221118224540.619276-274-uwe@kleine-koenig.org
parent 912bcc8a
...@@ -396,9 +396,9 @@ static const struct regmap_config lm355x_regmap = { ...@@ -396,9 +396,9 @@ static const struct regmap_config lm355x_regmap = {
}; };
/* module initialize */ /* module initialize */
static int lm355x_probe(struct i2c_client *client, static int lm355x_probe(struct i2c_client *client)
const struct i2c_device_id *id)
{ {
const struct i2c_device_id *id = i2c_client_get_device_id(client);
struct lm355x_platform_data *pdata = dev_get_platdata(&client->dev); struct lm355x_platform_data *pdata = dev_get_platdata(&client->dev);
struct lm355x_chip_data *chip; struct lm355x_chip_data *chip;
...@@ -516,7 +516,7 @@ static struct i2c_driver lm355x_i2c_driver = { ...@@ -516,7 +516,7 @@ static struct i2c_driver lm355x_i2c_driver = {
.name = LM355x_NAME, .name = LM355x_NAME,
.pm = NULL, .pm = NULL,
}, },
.probe = lm355x_probe, .probe_new = lm355x_probe,
.remove = lm355x_remove, .remove = lm355x_remove,
.id_table = lm355x_id, .id_table = lm355x_id,
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment