Skip to content

Commit 7963ba0

Browse files
Uwe Kleine-KönigBartosz Golaszewski
authored andcommitted
gpio: pcf857x: 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: Bartosz Golaszewski <[email protected]>
1 parent 1287341 commit 7963ba0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

drivers/gpio/gpio-pcf857x.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -247,9 +247,9 @@ static const struct irq_chip pcf857x_irq_chip = {
247247

248248
/*-------------------------------------------------------------------------*/
249249

250-
static int pcf857x_probe(struct i2c_client *client,
251-
const struct i2c_device_id *id)
250+
static int pcf857x_probe(struct i2c_client *client)
252251
{
252+
const struct i2c_device_id *id = i2c_client_get_device_id(client);
253253
struct pcf857x_platform_data *pdata = dev_get_platdata(&client->dev);
254254
struct device_node *np = client->dev.of_node;
255255
struct pcf857x *gpio;
@@ -422,7 +422,7 @@ static struct i2c_driver pcf857x_driver = {
422422
.name = "pcf857x",
423423
.of_match_table = of_match_ptr(pcf857x_of_table),
424424
},
425-
.probe = pcf857x_probe,
425+
.probe_new = pcf857x_probe,
426426
.remove = pcf857x_remove,
427427
.shutdown = pcf857x_shutdown,
428428
.id_table = pcf857x_id,

0 commit comments

Comments
 (0)