linux-next: build failure after merge of the pinctrl tree

From: Stephen Rothwell
Date: Fri Aug 26 2022 - 01:27:00 EST


Hi all,

After merging the pinctrl tree, today's linux-next build (x86_64
allmodconfig) failed like this:

drivers/pinctrl/pinctrl-cy8c95x0.c:1371:27: error: initialization of 'void (*)(struct i2c_client *)' from incompatible pointer type 'int (*)(struct i2c_client *)' [-Werror=incompatible-pointer-types]
1371 | .remove = cy8c95x0_remove,
| ^~~~~~~~~~~~~~~
drivers/pinctrl/pinctrl-cy8c95x0.c:1371:27: note: (near initialization for 'cy8c95x0_driver.remove')

Caused by commit

e6cbbe42944d ("pinctrl: Add Cypress cy8c95x0 support")

interacting with commit

ed5c2f5fd10d ("i2c: Make remove callback return void")

from the i2c tree.

I have applied the following merge fix patch:

From: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
Date: Fri, 26 Aug 2022 15:20:29 +1000
Subject: [PATCH] pinctrl: fixup for "i2c: Make remove callback return void"

Signed-off-by: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
---
drivers/pinctrl/pinctrl-cy8c95x0.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/pinctrl/pinctrl-cy8c95x0.c b/drivers/pinctrl/pinctrl-cy8c95x0.c
index a29df0920f4f..05791212822e 100644
--- a/drivers/pinctrl/pinctrl-cy8c95x0.c
+++ b/drivers/pinctrl/pinctrl-cy8c95x0.c
@@ -1352,14 +1352,12 @@ static int cy8c95x0_probe(struct i2c_client *client)
return ret;
}

-static int cy8c95x0_remove(struct i2c_client *client)
+static void cy8c95x0_remove(struct i2c_client *client)
{
struct cy8c95x0_pinctrl *chip = i2c_get_clientdata(client);

if (!IS_ERR_OR_NULL(chip->regulator))
regulator_disable(chip->regulator);
-
- return 0;
}

static struct i2c_driver cy8c95x0_driver = {
--
2.35.1

--
Cheers,
Stephen Rothwell

Attachment: pgpQ_B8b_5LHG.pgp
Description: OpenPGP digital signature