[PATCH v2] mfd: da9063: occupy second I2C address, too

Wolfram Sang posted 1 patch 4 months ago
There is a newer version of this series
drivers/mfd/da9063-i2c.c | 2 ++
1 file changed, 2 insertions(+)
[PATCH v2] mfd: da9063: occupy second I2C address, too
Posted by Wolfram Sang 4 months ago
The second address can be used as a shortcut to access register pages
2+3. The driver does not use this feature yet. The second address should
still be marked as used, otherwise userspace could interfere with the
driver.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Peter Rosin <peda@axentia.se>
Reviewed-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
---

Change since v1: reworded commit message

 drivers/mfd/da9063-i2c.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/mfd/da9063-i2c.c b/drivers/mfd/da9063-i2c.c
index 1ec9ab56442d..12f3dd927aba 100644
--- a/drivers/mfd/da9063-i2c.c
+++ b/drivers/mfd/da9063-i2c.c
@@ -469,6 +469,8 @@ static int da9063_i2c_probe(struct i2c_client *i2c)
 		}
 	}
 
+	devm_i2c_new_dummy_device(&i2c->dev, i2c->adapter, i2c->addr + 1);
+
 	return da9063_device_init(da9063, i2c->irq);
 }
 
-- 
2.47.2
Re: [PATCH v2] mfd: da9063: occupy second I2C address, too
Posted by Lee Jones 3 months, 2 weeks ago
On Tue, 07 Oct 2025, Wolfram Sang wrote:

> The second address can be used as a shortcut to access register pages
> 2+3. The driver does not use this feature yet. The second address should
> still be marked as used, otherwise userspace could interfere with the
> driver.

Perfect.  Thanks for updating.

> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
> Reviewed-by: Peter Rosin <peda@axentia.se>
> Reviewed-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
> Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
> ---
> 
> Change since v1: reworded commit message
> 
>  drivers/mfd/da9063-i2c.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/mfd/da9063-i2c.c b/drivers/mfd/da9063-i2c.c
> index 1ec9ab56442d..12f3dd927aba 100644
> --- a/drivers/mfd/da9063-i2c.c
> +++ b/drivers/mfd/da9063-i2c.c
> @@ -469,6 +469,8 @@ static int da9063_i2c_probe(struct i2c_client *i2c)
>  		}
>  	}
>  
> +	devm_i2c_new_dummy_device(&i2c->dev, i2c->adapter, i2c->addr + 1);

I still think we need a simple comment to explain why we're obtaining
and seemingly not using the address.


-- 
Lee Jones [李琼斯]