Skip to content

Commit 6d43a4b

Browse files
Uwe Kleine-Königsre
authored andcommitted
power: supply: smb347: 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 <[email protected]> Signed-off-by: Sebastian Reichel <[email protected]>
1 parent 02d1a40 commit 6d43a4b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

drivers/power/supply/smb347-charger.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1528,9 +1528,9 @@ static const struct regulator_desc smb347_usb_vbus_regulator_desc = {
15281528
.n_voltages = 1,
15291529
};
15301530

1531-
static int smb347_probe(struct i2c_client *client,
1532-
const struct i2c_device_id *id)
1531+
static int smb347_probe(struct i2c_client *client)
15331532
{
1533+
const struct i2c_device_id *id = i2c_client_get_device_id(client);
15341534
struct power_supply_config mains_usb_cfg = {};
15351535
struct regulator_config usb_rdev_cfg = {};
15361536
struct device *dev = &client->dev;
@@ -1629,7 +1629,7 @@ static struct i2c_driver smb347_driver = {
16291629
.name = "smb347",
16301630
.of_match_table = smb3xx_of_match,
16311631
},
1632-
.probe = smb347_probe,
1632+
.probe_new = smb347_probe,
16331633
.remove = smb347_remove,
16341634
.shutdown = smb347_shutdown,
16351635
.id_table = smb347_id,

0 commit comments

Comments
 (0)