[PATCH] mfd: rohm-bdXXX - switch to use i2c probe_new

From: Matti Vaittinen
Date: Thu Mar 26 2020 - 02:49:04 EST


ROHM BD70528 and BD718x7 drivers do not utilize the I2C id.
Do the trivial conversion and make them to use probe_new
instead of probe.

Signed-off-by: Matti Vaittinen <matti.vaittinen@xxxxxxxxxxxxxxxxx>
---
drivers/mfd/rohm-bd70528.c | 5 ++---
drivers/mfd/rohm-bd718x7.c | 5 ++---
2 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/drivers/mfd/rohm-bd70528.c b/drivers/mfd/rohm-bd70528.c
index 5c44d3b77b3e..179584d10109 100644
--- a/drivers/mfd/rohm-bd70528.c
+++ b/drivers/mfd/rohm-bd70528.c
@@ -216,8 +216,7 @@ static struct regmap_irq_chip bd70528_irq_chip = {
.irq_reg_stride = 1,
};

-static int bd70528_i2c_probe(struct i2c_client *i2c,
- const struct i2c_device_id *id)
+static int bd70528_i2c_probe(struct i2c_client *i2c)
{
struct bd70528_data *bd70528;
struct regmap_irq_chip_data *irq_data;
@@ -304,7 +303,7 @@ static struct i2c_driver bd70528_drv = {
.name = "rohm-bd70528",
.of_match_table = bd70528_of_match,
},
- .probe = &bd70528_i2c_probe,
+ .probe_new = &bd70528_i2c_probe,
};

module_i2c_driver(bd70528_drv);
diff --git a/drivers/mfd/rohm-bd718x7.c b/drivers/mfd/rohm-bd718x7.c
index c32c1b6c98fa..e621e1a82222 100644
--- a/drivers/mfd/rohm-bd718x7.c
+++ b/drivers/mfd/rohm-bd718x7.c
@@ -129,8 +129,7 @@ static int bd718xx_init_press_duration(struct bd718xx *bd718xx)
return 0;
}

-static int bd718xx_i2c_probe(struct i2c_client *i2c,
- const struct i2c_device_id *id)
+static int bd718xx_i2c_probe(struct i2c_client *i2c)
{
struct bd718xx *bd718xx;
int ret;
@@ -226,7 +225,7 @@ static struct i2c_driver bd718xx_i2c_driver = {
.name = "rohm-bd718x7",
.of_match_table = bd718xx_of_match,
},
- .probe = bd718xx_i2c_probe,
+ .probe_new = bd718xx_i2c_probe,
};

static int __init bd718xx_i2c_init(void)

base-commit: 16fbf79b0f83bc752cee8589279f1ebfe57b3b6e
--
2.21.0


--
Matti Vaittinen, Linux device drivers
ROHM Semiconductors, Finland SWDC
Kiviharjunlenkki 1E
90220 OULU
FINLAND

~~~ "I don't think so," said Rene Descartes. Just then he vanished ~~~
Simon says - in Latin please.
~~~ "non cogito me" dixit Rene Descarte, deinde evanescavit ~~~
Thanks to Simon Glass for the translation =]