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

Configure Feed

Select the types of activity you want to include in your feed.

iio: temperature: tmp007: 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-189-uwe@kleine-koenig.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>

authored by

Uwe Kleine-König and committed by
Jonathan Cameron
f1e7d53d 89824f4c

+3 -3
+3 -3
drivers/iio/temperature/tmp007.c
··· 446 446 tmp007_powerdown(data); 447 447 } 448 448 449 - static int tmp007_probe(struct i2c_client *client, 450 - const struct i2c_device_id *tmp007_id) 449 + static int tmp007_probe(struct i2c_client *client) 451 450 { 451 + const struct i2c_device_id *tmp007_id = i2c_client_get_device_id(client); 452 452 struct tmp007_data *data; 453 453 struct iio_dev *indio_dev; 454 454 int ret; ··· 574 574 .of_match_table = tmp007_of_match, 575 575 .pm = pm_sleep_ptr(&tmp007_pm_ops), 576 576 }, 577 - .probe = tmp007_probe, 577 + .probe_new = tmp007_probe, 578 578 .id_table = tmp007_id, 579 579 }; 580 580 module_i2c_driver(tmp007_driver);