Re: [PATCH] mfd: Drop owner assignment from i2c_drivers
On Fri, 10 Jul 2015, Krzysztof Kozlowski wrote: i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski k.kozlow...@samsung.com --- The coccinelle script which generated the patch was sent here: http://www.spinics.net/lists/kernel/msg2029903.html --- drivers/mfd/88pm800.c | 1 - drivers/mfd/88pm805.c | 1 - drivers/mfd/88pm860x-core.c | 1 - drivers/mfd/aat2870-core.c| 1 - drivers/mfd/ab3100-core.c | 1 - drivers/mfd/adp5520.c | 1 - drivers/mfd/arizona-i2c.c | 1 - drivers/mfd/as3711.c | 1 - drivers/mfd/as3722.c | 1 - drivers/mfd/axp20x.c | 1 - drivers/mfd/bcm590xx.c| 1 - drivers/mfd/cros_ec_i2c.c | 1 - drivers/mfd/da903x.c | 1 - drivers/mfd/da9052-i2c.c | 1 - drivers/mfd/da9055-i2c.c | 1 - drivers/mfd/da9063-i2c.c | 1 - drivers/mfd/intel_soc_pmic_core.c | 1 - drivers/mfd/lm3533-core.c | 1 - drivers/mfd/lp3943.c | 1 - drivers/mfd/lp8788.c | 1 - drivers/mfd/max14577.c| 1 - drivers/mfd/max77686.c| 1 - drivers/mfd/max77693.c| 1 - drivers/mfd/max8907.c | 1 - drivers/mfd/max8925-i2c.c | 1 - drivers/mfd/max8997.c | 1 - drivers/mfd/max8998.c | 1 - drivers/mfd/mc13xxx-i2c.c | 1 - drivers/mfd/palmas.c | 1 - drivers/mfd/rc5t583.c | 1 - drivers/mfd/retu-mfd.c| 1 - drivers/mfd/sec-core.c| 1 - drivers/mfd/si476x-i2c.c | 1 - drivers/mfd/smsc-ece1099.c| 1 - drivers/mfd/stmpe-i2c.c | 1 - drivers/mfd/tc3589x.c | 1 - drivers/mfd/tps6507x.c| 1 - drivers/mfd/tps65090.c| 1 - drivers/mfd/tps65217.c| 1 - drivers/mfd/tps65218.c| 1 - drivers/mfd/tps6586x.c| 1 - drivers/mfd/tps65910.c| 1 - drivers/mfd/tps65912-i2c.c| 1 - drivers/mfd/tps80031.c| 1 - drivers/mfd/twl6040.c | 1 - drivers/mfd/wm831x-i2c.c | 1 - drivers/mfd/wm8350-i2c.c | 1 - drivers/mfd/wm8400-core.c | 1 - drivers/mfd/wm8994-core.c | 1 - 49 files changed, 49 deletions(-) Applied, thanks. diff --git a/drivers/mfd/88pm800.c b/drivers/mfd/88pm800.c index 841717a2842c..f2d9fb4c4e8e 100644 --- a/drivers/mfd/88pm800.c +++ b/drivers/mfd/88pm800.c @@ -609,7 +609,6 @@ static int pm800_remove(struct i2c_client *client) static struct i2c_driver pm800_driver = { .driver = { .name = 88PM800, - .owner = THIS_MODULE, .pm = pm80x_pm_ops, }, .probe = pm800_probe, diff --git a/drivers/mfd/88pm805.c b/drivers/mfd/88pm805.c index e9d50644660c..39f2302e137b 100644 --- a/drivers/mfd/88pm805.c +++ b/drivers/mfd/88pm805.c @@ -267,7 +267,6 @@ static int pm805_remove(struct i2c_client *client) static struct i2c_driver pm805_driver = { .driver = { .name = 88PM805, - .owner = THIS_MODULE, .pm = pm80x_pm_ops, }, .probe = pm805_probe, diff --git a/drivers/mfd/88pm860x-core.c b/drivers/mfd/88pm860x-core.c index e03b7f45b8f7..cb47d6e00ebe 100644 --- a/drivers/mfd/88pm860x-core.c +++ b/drivers/mfd/88pm860x-core.c @@ -1258,7 +1258,6 @@ MODULE_DEVICE_TABLE(of, pm860x_dt_ids); static struct i2c_driver pm860x_driver = { .driver = { .name = 88PM860x, - .owner = THIS_MODULE, .pm = pm860x_pm_ops, .of_match_table = pm860x_dt_ids, }, diff --git a/drivers/mfd/aat2870-core.c b/drivers/mfd/aat2870-core.c index 4e6e03d63e12..29b6a2d4ac72 100644 --- a/drivers/mfd/aat2870-core.c +++ b/drivers/mfd/aat2870-core.c @@ -500,7 +500,6 @@ MODULE_DEVICE_TABLE(i2c, aat2870_i2c_id_table); static struct i2c_driver aat2870_i2c_driver = { .driver = { .name = aat2870, - .owner = THIS_MODULE, .pm = aat2870_pm_ops, }, .probe = aat2870_i2c_probe, diff --git a/drivers/mfd/ab3100-core.c b/drivers/mfd/ab3100-core.c index 4659ac1db039..f0afb44271f8 100644 --- a/drivers/mfd/ab3100-core.c +++ b/drivers/mfd/ab3100-core.c @@ -972,7 +972,6 @@ MODULE_DEVICE_TABLE(i2c, ab3100_id); static struct i2c_driver ab3100_driver = { .driver = { .name = ab3100, - .owner = THIS_MODULE, }, .id_table = ab3100_id, .probe = ab3100_probe, diff --git a/drivers/mfd/adp5520.c b/drivers/mfd/adp5520.c index f495b8b57dd7..ae88654595dc 100644 --- a/drivers/mfd/adp5520.c +++ b/drivers/mfd/adp5520.c @@ -351,7 +351,6 @@ MODULE_DEVICE_TABLE(i2c, adp5520_id); static struct i2c_driver
[PATCH] mfd: Drop owner assignment from i2c_drivers
i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski k.kozlow...@samsung.com --- The coccinelle script which generated the patch was sent here: http://www.spinics.net/lists/kernel/msg2029903.html --- drivers/mfd/88pm800.c | 1 - drivers/mfd/88pm805.c | 1 - drivers/mfd/88pm860x-core.c | 1 - drivers/mfd/aat2870-core.c| 1 - drivers/mfd/ab3100-core.c | 1 - drivers/mfd/adp5520.c | 1 - drivers/mfd/arizona-i2c.c | 1 - drivers/mfd/as3711.c | 1 - drivers/mfd/as3722.c | 1 - drivers/mfd/axp20x.c | 1 - drivers/mfd/bcm590xx.c| 1 - drivers/mfd/cros_ec_i2c.c | 1 - drivers/mfd/da903x.c | 1 - drivers/mfd/da9052-i2c.c | 1 - drivers/mfd/da9055-i2c.c | 1 - drivers/mfd/da9063-i2c.c | 1 - drivers/mfd/intel_soc_pmic_core.c | 1 - drivers/mfd/lm3533-core.c | 1 - drivers/mfd/lp3943.c | 1 - drivers/mfd/lp8788.c | 1 - drivers/mfd/max14577.c| 1 - drivers/mfd/max77686.c| 1 - drivers/mfd/max77693.c| 1 - drivers/mfd/max8907.c | 1 - drivers/mfd/max8925-i2c.c | 1 - drivers/mfd/max8997.c | 1 - drivers/mfd/max8998.c | 1 - drivers/mfd/mc13xxx-i2c.c | 1 - drivers/mfd/palmas.c | 1 - drivers/mfd/rc5t583.c | 1 - drivers/mfd/retu-mfd.c| 1 - drivers/mfd/sec-core.c| 1 - drivers/mfd/si476x-i2c.c | 1 - drivers/mfd/smsc-ece1099.c| 1 - drivers/mfd/stmpe-i2c.c | 1 - drivers/mfd/tc3589x.c | 1 - drivers/mfd/tps6507x.c| 1 - drivers/mfd/tps65090.c| 1 - drivers/mfd/tps65217.c| 1 - drivers/mfd/tps65218.c| 1 - drivers/mfd/tps6586x.c| 1 - drivers/mfd/tps65910.c| 1 - drivers/mfd/tps65912-i2c.c| 1 - drivers/mfd/tps80031.c| 1 - drivers/mfd/twl6040.c | 1 - drivers/mfd/wm831x-i2c.c | 1 - drivers/mfd/wm8350-i2c.c | 1 - drivers/mfd/wm8400-core.c | 1 - drivers/mfd/wm8994-core.c | 1 - 49 files changed, 49 deletions(-) diff --git a/drivers/mfd/88pm800.c b/drivers/mfd/88pm800.c index 841717a2842c..f2d9fb4c4e8e 100644 --- a/drivers/mfd/88pm800.c +++ b/drivers/mfd/88pm800.c @@ -609,7 +609,6 @@ static int pm800_remove(struct i2c_client *client) static struct i2c_driver pm800_driver = { .driver = { .name = 88PM800, - .owner = THIS_MODULE, .pm = pm80x_pm_ops, }, .probe = pm800_probe, diff --git a/drivers/mfd/88pm805.c b/drivers/mfd/88pm805.c index e9d50644660c..39f2302e137b 100644 --- a/drivers/mfd/88pm805.c +++ b/drivers/mfd/88pm805.c @@ -267,7 +267,6 @@ static int pm805_remove(struct i2c_client *client) static struct i2c_driver pm805_driver = { .driver = { .name = 88PM805, - .owner = THIS_MODULE, .pm = pm80x_pm_ops, }, .probe = pm805_probe, diff --git a/drivers/mfd/88pm860x-core.c b/drivers/mfd/88pm860x-core.c index e03b7f45b8f7..cb47d6e00ebe 100644 --- a/drivers/mfd/88pm860x-core.c +++ b/drivers/mfd/88pm860x-core.c @@ -1258,7 +1258,6 @@ MODULE_DEVICE_TABLE(of, pm860x_dt_ids); static struct i2c_driver pm860x_driver = { .driver = { .name = 88PM860x, - .owner = THIS_MODULE, .pm = pm860x_pm_ops, .of_match_table = pm860x_dt_ids, }, diff --git a/drivers/mfd/aat2870-core.c b/drivers/mfd/aat2870-core.c index 4e6e03d63e12..29b6a2d4ac72 100644 --- a/drivers/mfd/aat2870-core.c +++ b/drivers/mfd/aat2870-core.c @@ -500,7 +500,6 @@ MODULE_DEVICE_TABLE(i2c, aat2870_i2c_id_table); static struct i2c_driver aat2870_i2c_driver = { .driver = { .name = aat2870, - .owner = THIS_MODULE, .pm = aat2870_pm_ops, }, .probe = aat2870_i2c_probe, diff --git a/drivers/mfd/ab3100-core.c b/drivers/mfd/ab3100-core.c index 4659ac1db039..f0afb44271f8 100644 --- a/drivers/mfd/ab3100-core.c +++ b/drivers/mfd/ab3100-core.c @@ -972,7 +972,6 @@ MODULE_DEVICE_TABLE(i2c, ab3100_id); static struct i2c_driver ab3100_driver = { .driver = { .name = ab3100, - .owner = THIS_MODULE, }, .id_table = ab3100_id, .probe = ab3100_probe, diff --git a/drivers/mfd/adp5520.c b/drivers/mfd/adp5520.c index f495b8b57dd7..ae88654595dc 100644 --- a/drivers/mfd/adp5520.c +++ b/drivers/mfd/adp5520.c @@ -351,7 +351,6 @@ MODULE_DEVICE_TABLE(i2c, adp5520_id); static struct i2c_driver adp5520_driver = { .driver = { .name = adp5520, - .owner = THIS_MODULE, .pm