diff options
Diffstat (limited to 'drivers/mfd/da9052-i2c.c')
| -rw-r--r-- | drivers/mfd/da9052-i2c.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/drivers/mfd/da9052-i2c.c b/drivers/mfd/da9052-i2c.c index 8de93db35f3a..fd000a21bcba 100644 --- a/drivers/mfd/da9052-i2c.c +++ b/drivers/mfd/da9052-i2c.c @@ -13,14 +13,11 @@ #include <linux/mfd/core.h> #include <linux/i2c.h> #include <linux/err.h> +#include <linux/of.h> #include <linux/mfd/da9052/da9052.h> #include <linux/mfd/da9052/reg.h> -#ifdef CONFIG_OF -#include <linux/of.h> -#include <linux/of_device.h> -#endif /* I2C safe register check */ static inline bool i2c_safe_reg(unsigned char reg) @@ -126,9 +123,9 @@ static const struct of_device_id dialog_dt_ids[] = { }; #endif -static int da9052_i2c_probe(struct i2c_client *client, - const struct i2c_device_id *id) +static int da9052_i2c_probe(struct i2c_client *client) { + const struct i2c_device_id *id = i2c_client_get_device_id(client); struct da9052 *da9052; int ret; @@ -168,12 +165,11 @@ static int da9052_i2c_probe(struct i2c_client *client, return da9052_device_init(da9052, id->driver_data); } -static int da9052_i2c_remove(struct i2c_client *client) +static void da9052_i2c_remove(struct i2c_client *client) { struct da9052 *da9052 = i2c_get_clientdata(client); da9052_device_exit(da9052); - return 0; } static struct i2c_driver da9052_i2c_driver = { @@ -210,4 +206,3 @@ module_exit(da9052_i2c_exit); MODULE_AUTHOR("David Dajun Chen <dchen@diasemi.com>"); MODULE_DESCRIPTION("I2C driver for Dialog DA9052 PMIC"); -MODULE_LICENSE("GPL"); |
