[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <b15d7ac4-c751-4db8-a825-1e864570de37@gmail.com>
Date: Mon, 18 Aug 2025 09:57:44 +0300
From: Matti Vaittinen <mazziesaccount@...il.com>
To: Dmitry Torokhov <dmitry.torokhov@...il.com>, Lee Jones <lee@...nel.org>
Cc: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Arnd Bergmann <arnd@...nel.org>, Bartosz Golaszewski <brgl@...ev.pl>,
Linus Walleij <linus.walleij@...aro.org>, linux-input@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 3/3] mfd: rohm-bd718x7: Use software nodes for gpio-keys
On 18/08/2025 01:47, Dmitry Torokhov wrote:
> Refactor the rohm-bd7182x7 MFD driver to use software nodes for
> instantiating the gpio-keys child device, replacing the old
> platform_data mechanism.
>
> The power key's properties are now defined using software nodes and
> property entries. The IRQ is passed as a resource attached to the
> platform device.
>
> This will allow dropping support for using platform data for configuring
> gpio-keys in the future.
> ---
> drivers/mfd/rohm-bd718x7.c | 76 ++++++++++++++++++++++++++++++--------
> 1 file changed, 60 insertions(+), 16 deletions(-)
>
> diff --git a/drivers/mfd/rohm-bd718x7.c b/drivers/mfd/rohm-bd718x7.c
> index 25e494a93d48..20150656ac9c 100644
> --- a/drivers/mfd/rohm-bd718x7.c
> +++ b/drivers/mfd/rohm-bd718x7.c
> @@ -7,7 +7,6 @@
> // Datasheet for BD71837MWV available from
> // https://www.rohm.com/datasheet/BD71837MWV/bd71837mwv-e
...
>
> +static int bd718xx_reg_cnt;
> +
> +static int bd718xx_i2c_register_swnodes(void)
> +{
> + int error;
> +
> + if (bd718xx_reg_cnt == 0) {
> + error = software_node_register_node_group(bd718xx_swnodes);
> + if (error)
> + return error;
> + }
> +
> + bd718xx_reg_cnt++;
> + return 0;
> +}
> +
> +static void bd718xx_i2c_unregister_swnodes(void *dummy)
> +{
> + if (bd718xx_reg_cnt != 0) {
> + software_node_unregister_node_group(bd718xx_swnodes);
> + bd718xx_reg_cnt--;
> + }
> +}
Same questions here as with the patch 2/3.
Yours,
-- Matti
Powered by blists - more mailing lists