[PATCH v3 09/18] iio: accel: bma220: relax constraints during probe()

Petre Rodan posted 18 patches 2 weeks, 5 days ago
[PATCH v3 09/18] iio: accel: bma220: relax constraints during probe()
Posted by Petre Rodan 2 weeks, 5 days ago
Allow compatible chips to work even if their identifier is different.

Signed-off-by: Petre Rodan <petre.rodan@subdimension.ro>
---
v2->v3 replace err with dev_info() (Jonathan)
---
 drivers/iio/accel/bma220_core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/iio/accel/bma220_core.c b/drivers/iio/accel/bma220_core.c
index fad73bf6b8f29c0a33519c64c8888a01008f7579..7fdb83cedfa1809490cfb7f89532182123d580ba 100644
--- a/drivers/iio/accel/bma220_core.c
+++ b/drivers/iio/accel/bma220_core.c
@@ -267,7 +267,7 @@ static int bma220_init(struct spi_device *spi)
 
 	ret = bma220_read_reg(spi, BMA220_REG_ID);
 	if (ret != BMA220_CHIP_ID)
-		return -ENODEV;
+		dev_info(&spi->dev, "Unknown chip found: 0x%02x\n", ret);
 
 	/* Make sure the chip is powered on and config registers are reset */
 	ret = bma220_power(spi, true);

-- 
2.49.1
Re: [PATCH v3 09/18] iio: accel: bma220: relax constraints during probe()
Posted by Andy Shevchenko 2 weeks, 4 days ago
On Sat, Sep 13, 2025 at 6:40 PM Petre Rodan <petre.rodan@subdimension.ro> wrote:
>
> Allow compatible chips to work even if their identifier is different.

This looks to me like a candidate to be moved closer to the beginning
of the series (before even split).

-- 
With Best Regards,
Andy Shevchenko