Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

iio: adc: max1363: 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>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20221118224540.619276-67-uwe@kleine-koenig.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>

authored by

Uwe Kleine-König and committed by
Jonathan Cameron
a69e45a4 3a798444

+3 -3
+3 -3
drivers/iio/adc/max1363.c
··· 1579 1579 regulator_disable(reg); 1580 1580 } 1581 1581 1582 - static int max1363_probe(struct i2c_client *client, 1583 - const struct i2c_device_id *id) 1582 + static int max1363_probe(struct i2c_client *client) 1584 1583 { 1584 + const struct i2c_device_id *id = i2c_client_get_device_id(client); 1585 1585 int ret; 1586 1586 struct max1363_state *st; 1587 1587 struct iio_dev *indio_dev; ··· 1718 1718 .name = "max1363", 1719 1719 .of_match_table = max1363_of_match, 1720 1720 }, 1721 - .probe = max1363_probe, 1721 + .probe_new = max1363_probe, 1722 1722 .id_table = max1363_id, 1723 1723 }; 1724 1724 module_i2c_driver(max1363_driver);