[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20221118224540.619276-292-uwe@kleine-koenig.org>
Date: Fri, 18 Nov 2022 23:40:25 +0100
From: Uwe Kleine-König <uwe@...ine-koenig.org>
To: Angel Iglesias <ang.iglesiasg@...il.com>,
Lee Jones <lee.jones@...aro.org>,
Grant Likely <grant.likely@...aro.org>,
Wolfram Sang <wsa@...nel.org>,
Benjamin Herrenschmidt <benh@...nel.crashing.org>,
Michael Ellerman <mpe@...erman.id.au>,
Wolfram Sang <wsa+renesas@...g-engineering.com>,
Ajay Gupta <ajayg@...dia.com>,
Srinivas Pandruvada <srinivas.pandruvada@...ux.intel.com>,
Liang He <windhl@....com>,
Christophe Leroy <christophe.leroy@...roup.eu>
Cc: linux-i2c@...r.kernel.org, kernel@...gutronix.de,
Uwe Kleine-König
<u.kleine-koenig@...gutronix.de>, linuxppc-dev@...ts.ozlabs.org,
linux-kernel@...r.kernel.org
Subject: [PATCH 291/606] macintosh: therm_windtunnel: Convert to i2c's .probe_new()
From: Uwe Kleine-König <u.kleine-koenig@...gutronix.de>
.probe_new() doesn't get the i2c_device_id * parameter, so determine
that explicitly in the probe function.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@...gutronix.de>
---
drivers/macintosh/therm_windtunnel.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/macintosh/therm_windtunnel.c b/drivers/macintosh/therm_windtunnel.c
index b8228ca40454..22b15efcc025 100644
--- a/drivers/macintosh/therm_windtunnel.c
+++ b/drivers/macintosh/therm_windtunnel.c
@@ -411,8 +411,9 @@ static const struct i2c_device_id therm_windtunnel_id[] = {
MODULE_DEVICE_TABLE(i2c, therm_windtunnel_id);
static int
-do_probe(struct i2c_client *cl, const struct i2c_device_id *id)
+do_probe(struct i2c_client *cl)
{
+ const struct i2c_device_id *id = i2c_client_get_device_id(cl);
struct i2c_adapter *adapter = cl->adapter;
int ret = 0;
@@ -441,7 +442,7 @@ static struct i2c_driver g4fan_driver = {
.driver = {
.name = "therm_windtunnel",
},
- .probe = do_probe,
+ .probe_new = do_probe,
.remove = do_remove,
.id_table = therm_windtunnel_id,
};
--
2.38.1
Powered by blists - more mailing lists