iio: light: opt3001: Convert to i2c's .probe_new()
The probe function doesn't make use of the i2c_device_id * parameter so it can be trivially converted. 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-135-uwe@kleine-koenig.org Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
This commit is contained in:
parent
c49135d99f
commit
06d1007328
|
@ -735,8 +735,7 @@ out:
|
|||
return IRQ_HANDLED;
|
||||
}
|
||||
|
||||
static int opt3001_probe(struct i2c_client *client,
|
||||
const struct i2c_device_id *id)
|
||||
static int opt3001_probe(struct i2c_client *client)
|
||||
{
|
||||
struct device *dev = &client->dev;
|
||||
|
||||
|
@ -835,7 +834,7 @@ static const struct of_device_id opt3001_of_match[] = {
|
|||
MODULE_DEVICE_TABLE(of, opt3001_of_match);
|
||||
|
||||
static struct i2c_driver opt3001_driver = {
|
||||
.probe = opt3001_probe,
|
||||
.probe_new = opt3001_probe,
|
||||
.remove = opt3001_remove,
|
||||
.id_table = opt3001_id,
|
||||
|
||||
|
|
Loading…
Reference in New Issue