diff options
Diffstat (limited to 'drivers/hwmon/ad7418.c')
-rw-r--r-- | drivers/hwmon/ad7418.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/drivers/hwmon/ad7418.c b/drivers/hwmon/ad7418.c index 4829f83ff52e..7a132accdf8a 100644 --- a/drivers/hwmon/ad7418.c +++ b/drivers/hwmon/ad7418.c @@ -230,8 +230,6 @@ static void ad7418_init_client(struct i2c_client *client) } } -static const struct i2c_device_id ad7418_id[]; - static int ad7418_probe(struct i2c_client *client) { struct device *dev = &client->dev; @@ -252,10 +250,7 @@ static int ad7418_probe(struct i2c_client *client) mutex_init(&data->lock); data->client = client; - if (dev->of_node) - data->type = (uintptr_t)of_device_get_match_data(dev); - else - data->type = i2c_match_id(ad7418_id, client)->driver_data; + data->type = (uintptr_t)i2c_get_match_data(client); switch (data->type) { case ad7416: |