Skip to content

Commit 69518d2

Browse files
Uwe Kleine-Königbroonie
authored andcommitted
regulator: isl6271a-regulator: 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: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-for-MFD-by: Lee Jones <lee@kernel.org> Acked-for-Backlight-by: Lee Jones <lee@kernel.org> Link: https://lore.kernel.org/r/20221118224540.619276-543-uwe@kleine-koenig.org Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 6554256 commit 69518d2

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

drivers/regulator/isl6271a-regulator.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,9 @@ static const struct regulator_desc isl_rd[] = {
9797
},
9898
};
9999

100-
static int isl6271a_probe(struct i2c_client *i2c,
101-
const struct i2c_device_id *id)
100+
static int isl6271a_probe(struct i2c_client *i2c)
102101
{
102+
const struct i2c_device_id *id = i2c_client_get_device_id(i2c);
103103
struct regulator_dev *rdev;
104104
struct regulator_config config = { };
105105
struct regulator_init_data *init_data = dev_get_platdata(&i2c->dev);
@@ -148,7 +148,7 @@ static struct i2c_driver isl6271a_i2c_driver = {
148148
.driver = {
149149
.name = "isl6271a",
150150
},
151-
.probe = isl6271a_probe,
151+
.probe_new = isl6271a_probe,
152152
.id_table = isl6271a_id,
153153
};
154154

0 commit comments

Comments
 (0)