mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-11-01 17:08:10 +00:00
regulator: max20411: Convert to i2c's .probe_new()
The probe function doesn't make use of the i2c_device_id * parameter so it can be trivially converted. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/20230127101726.1313927-1-u.kleine-koenig@pengutronix.de Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
668f777d02
commit
fad8ddda1c
1 changed files with 2 additions and 3 deletions
|
@ -96,8 +96,7 @@ static const struct regulator_desc max20411_desc = {
|
||||||
.n_ramp_values = ARRAY_SIZE(max20411_slew_rates),
|
.n_ramp_values = ARRAY_SIZE(max20411_slew_rates),
|
||||||
};
|
};
|
||||||
|
|
||||||
static int max20411_probe(struct i2c_client *client,
|
static int max20411_probe(struct i2c_client *client)
|
||||||
const struct i2c_device_id *id)
|
|
||||||
{
|
{
|
||||||
struct regulator_init_data *init_data;
|
struct regulator_init_data *init_data;
|
||||||
struct device *dev = &client->dev;
|
struct device *dev = &client->dev;
|
||||||
|
@ -156,7 +155,7 @@ static struct i2c_driver max20411_i2c_driver = {
|
||||||
.name = "max20411",
|
.name = "max20411",
|
||||||
.of_match_table = of_max20411_match_tbl,
|
.of_match_table = of_max20411_match_tbl,
|
||||||
},
|
},
|
||||||
.probe = max20411_probe,
|
.probe_new = max20411_probe,
|
||||||
.id_table = max20411_id,
|
.id_table = max20411_id,
|
||||||
};
|
};
|
||||||
module_i2c_driver(max20411_i2c_driver);
|
module_i2c_driver(max20411_i2c_driver);
|
||||||
|
|
Loading…
Reference in a new issue