* [PATCH 0/2] iio: imu: inv_icm42600: add support for icm42630
@ 2026-07-20 17:34 Jorijn van der Graaf
2026-07-20 17:34 ` [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630 Jorijn van der Graaf
` (2 more replies)
0 siblings, 3 replies; 9+ messages in thread
From: Jorijn van der Graaf @ 2026-07-20 17:34 UTC (permalink / raw)
To: Jonathan Cameron, Jean-Baptiste Maneyrol
Cc: Jorijn van der Graaf, David Lechner, Nuno Sá,
Andy Shevchenko, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Chris Morgan, Luca Weiss, linux-iio, devicetree, linux-kernel
The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family,
used in the Fairphone 6. The existing inv_icm42600 driver drives it
unmodified once its WHOAMI value is known, so this is just the
compatible plus the chip id / WHOAMI table entries.
The part appears to be a mobile SKU and has no public datasheet. The
name comes from the Fairphone 6 schematics and platform documentation;
the WHOAMI value 0x0C was read from the hardware over both SPI and
I2C, and the chip's bank 0 register defaults match the ICM-42600
family layout. Jean-Baptiste, if you are able to confirm the part name
and WHOAMI value from the TDK side, that would be very welcome.
Tested on the Fairphone 6: patch 2 applied to the device's 7.1-based
kernel (with the id-table hunks adjusted to that base's style) drives
the chip over a bit-banged SPI bus with INT1 wired to the SoC - probe,
accelerometer, gyroscope and temperature raw reads, all full-scale
ranges, multiple sampling frequencies, and watermark-paced FIFO reads
through the INT1 interrupt. The accelerometer full scale was cross-checked against
gravity (~2048 LSB/g at the default range, matching +-16g); the
+-2000 dps gyroscope full scale is inferred from family membership,
pending confirmation from TDK.
The series is based on iio/togreg (base-commit below); on that base it
builds (arm64 defconfig with the driver as modules, W=1 clean on the
driver directory) and dt_binding_check passes.
Note: Chris Morgan's in-flight ICM-42607 series [1] adds entries to
the same binding enum; the overlap is context-only (different lines)
and trivial for whichever lands second.
[1] https://lore.kernel.org/all/20260716182637.24310-1-macroalpha82@gmail.com/
The Fairphone 6 board DTS nodes will follow separately via the qcom
tree once this lands.
Jorijn van der Graaf (2):
dt-bindings: iio: imu: icm42600: add icm42630
iio: imu: inv_icm42600: add support for icm42630
.../devicetree/bindings/iio/imu/invensense,icm42600.yaml | 1 +
drivers/iio/imu/inv_icm42600/inv_icm42600.h | 2 ++
drivers/iio/imu/inv_icm42600/inv_icm42600_core.c | 5 +++++
drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c | 4 ++++
drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c | 4 ++++
5 files changed, 16 insertions(+)
base-commit: 036d96ceec6d966339aea34d034420991e24cfac
--
2.55.0
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630
2026-07-20 17:34 [PATCH 0/2] iio: imu: inv_icm42600: add support for icm42630 Jorijn van der Graaf
@ 2026-07-20 17:34 ` Jorijn van der Graaf
2026-07-21 7:14 ` Jean-Baptiste Maneyrol
2026-07-21 16:01 ` Conor Dooley
2026-07-20 17:34 ` [PATCH 2/2] iio: imu: inv_icm42600: add support for icm42630 Jorijn van der Graaf
2026-07-21 7:12 ` [PATCH 0/2] " Jean-Baptiste Maneyrol
2 siblings, 2 replies; 9+ messages in thread
From: Jorijn van der Graaf @ 2026-07-20 17:34 UTC (permalink / raw)
To: Jonathan Cameron, Jean-Baptiste Maneyrol
Cc: Jorijn van der Graaf, David Lechner, Nuno Sá,
Andy Shevchenko, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Chris Morgan, Luca Weiss, linux-iio, devicetree, linux-kernel
The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family,
found e.g. in the Fairphone 6. Document its compatible.
A fallback compatible to a sibling is not usable: the part reports its
own WHOAMI register value, which software validates against the
compatible.
Assisted-by: Claude:claude-fable-5
Signed-off-by: Jorijn van der Graaf <jorijnvdgraaf@catcrafts.net>
---
.../devicetree/bindings/iio/imu/invensense,icm42600.yaml | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml b/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
index 119e28a833fd..add3a7fef09d 100644
--- a/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
+++ b/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
@@ -31,6 +31,7 @@ properties:
- invensense,icm42602
- invensense,icm42605
- invensense,icm42622
+ - invensense,icm42630
- invensense,icm42631
- invensense,icm42686
- invensense,icm42688
--
2.55.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH 2/2] iio: imu: inv_icm42600: add support for icm42630
2026-07-20 17:34 [PATCH 0/2] iio: imu: inv_icm42600: add support for icm42630 Jorijn van der Graaf
2026-07-20 17:34 ` [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630 Jorijn van der Graaf
@ 2026-07-20 17:34 ` Jorijn van der Graaf
2026-07-21 7:18 ` Jean-Baptiste Maneyrol
2026-07-21 7:12 ` [PATCH 0/2] " Jean-Baptiste Maneyrol
2 siblings, 1 reply; 9+ messages in thread
From: Jorijn van der Graaf @ 2026-07-20 17:34 UTC (permalink / raw)
To: Jonathan Cameron, Jean-Baptiste Maneyrol
Cc: Jorijn van der Graaf, David Lechner, Nuno Sá,
Andy Shevchenko, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Chris Morgan, Luca Weiss, linux-iio, devicetree, linux-kernel
The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family,
found e.g. in the Fairphone 6. It is register-compatible with its
siblings (the existing driver works on it unmodified) and reports
WHOAMI value 0x0C.
The part appears to be a mobile SKU and has no public datasheet: the
identity comes from the Fairphone 6 platform documentation and
schematics naming the part, and the WHOAMI value was read from the
hardware, whose bank 0 register defaults match the ICM-42600 family
layout.
Add the chip id, WHOAMI value and I2C/SPI match entries, using the
family default configuration like the ICM-42631.
Tested on the Fairphone 6 via a backport of this change to the
device's 7.1-based kernel (only the id-table style adjusted to that
base), on a bit-banged SPI bus with INT1 wired to the SoC: probe,
accelerometer, gyroscope and temperature raw reads, all full-scale
ranges, multiple sampling frequencies, and watermark-paced FIFO reads
through the INT1 interrupt.
Assisted-by: Claude:claude-fable-5
Signed-off-by: Jorijn van der Graaf <jorijnvdgraaf@catcrafts.net>
---
drivers/iio/imu/inv_icm42600/inv_icm42600.h | 2 ++
drivers/iio/imu/inv_icm42600/inv_icm42600_core.c | 5 +++++
drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c | 4 ++++
drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c | 4 ++++
4 files changed, 15 insertions(+)
diff --git a/drivers/iio/imu/inv_icm42600/inv_icm42600.h b/drivers/iio/imu/inv_icm42600/inv_icm42600.h
index b55d993f0264..349de5458581 100644
--- a/drivers/iio/imu/inv_icm42600/inv_icm42600.h
+++ b/drivers/iio/imu/inv_icm42600/inv_icm42600.h
@@ -28,6 +28,7 @@ enum inv_icm42600_chip {
INV_CHIP_ICM42622,
INV_CHIP_ICM42688,
INV_CHIP_ICM42631,
+ INV_CHIP_ICM42630,
INV_CHIP_NB,
};
@@ -386,6 +387,7 @@ struct inv_icm42600_sensor_state {
#define INV_ICM42600_WHOAMI_ICM42622 0x46
#define INV_ICM42600_WHOAMI_ICM42688 0x47
#define INV_ICM42600_WHOAMI_ICM42631 0x5C
+#define INV_ICM42600_WHOAMI_ICM42630 0x0C
/* User bank 1 (MSB 0x10) */
#define INV_ICM42600_REG_SENSOR_CONFIG0 0x1003
diff --git a/drivers/iio/imu/inv_icm42600/inv_icm42600_core.c b/drivers/iio/imu/inv_icm42600/inv_icm42600_core.c
index dc97d8a274e3..9a31ca3615b3 100644
--- a/drivers/iio/imu/inv_icm42600/inv_icm42600_core.c
+++ b/drivers/iio/imu/inv_icm42600/inv_icm42600_core.c
@@ -177,6 +177,11 @@ static const struct inv_icm42600_hw inv_icm42600_hw[INV_CHIP_NB] = {
.name = "icm42631",
.conf = &inv_icm42600_default_conf,
},
+ [INV_CHIP_ICM42630] = {
+ .whoami = INV_ICM42600_WHOAMI_ICM42630,
+ .name = "icm42630",
+ .conf = &inv_icm42600_default_conf,
+ },
};
const struct iio_mount_matrix *
diff --git a/drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c b/drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c
index 28552d2db91d..c413904c8680 100644
--- a/drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c
+++ b/drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c
@@ -81,6 +81,7 @@ static const struct i2c_device_id inv_icm42600_id[] = {
{ .name = "icm42622", .driver_data = INV_CHIP_ICM42622 },
{ .name = "icm42688", .driver_data = INV_CHIP_ICM42688 },
{ .name = "icm42631", .driver_data = INV_CHIP_ICM42631 },
+ { .name = "icm42630", .driver_data = INV_CHIP_ICM42630 },
{ }
};
MODULE_DEVICE_TABLE(i2c, inv_icm42600_id);
@@ -107,6 +108,9 @@ static const struct of_device_id inv_icm42600_of_matches[] = {
}, {
.compatible = "invensense,icm42631",
.data = (void *)INV_CHIP_ICM42631,
+ }, {
+ .compatible = "invensense,icm42630",
+ .data = (void *)INV_CHIP_ICM42630,
},
{ }
};
diff --git a/drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c b/drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c
index faf743bc6444..a1d12ce3bf87 100644
--- a/drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c
+++ b/drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c
@@ -78,6 +78,7 @@ static const struct spi_device_id inv_icm42600_id[] = {
{ .name = "icm42622", .driver_data = INV_CHIP_ICM42622 },
{ .name = "icm42688", .driver_data = INV_CHIP_ICM42688 },
{ .name = "icm42631", .driver_data = INV_CHIP_ICM42631 },
+ { .name = "icm42630", .driver_data = INV_CHIP_ICM42630 },
{ }
};
MODULE_DEVICE_TABLE(spi, inv_icm42600_id);
@@ -104,6 +105,9 @@ static const struct of_device_id inv_icm42600_of_matches[] = {
}, {
.compatible = "invensense,icm42631",
.data = (void *)INV_CHIP_ICM42631,
+ }, {
+ .compatible = "invensense,icm42630",
+ .data = (void *)INV_CHIP_ICM42630,
},
{ }
};
--
2.55.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH 0/2] iio: imu: inv_icm42600: add support for icm42630
2026-07-20 17:34 [PATCH 0/2] iio: imu: inv_icm42600: add support for icm42630 Jorijn van der Graaf
2026-07-20 17:34 ` [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630 Jorijn van der Graaf
2026-07-20 17:34 ` [PATCH 2/2] iio: imu: inv_icm42600: add support for icm42630 Jorijn van der Graaf
@ 2026-07-21 7:12 ` Jean-Baptiste Maneyrol
2 siblings, 0 replies; 9+ messages in thread
From: Jean-Baptiste Maneyrol @ 2026-07-21 7:12 UTC (permalink / raw)
To: Jorijn van der Graaf, Jonathan Cameron
Cc: David Lechner, Nuno Sá, Andy Shevchenko, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Chris Morgan, Luca Weiss,
linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
>________________________________________
>From: Jorijn van der Graaf <jorijnvdgraaf@catcrafts.net>
>Sent: Monday, July 20, 2026 19:34
>To: Jonathan Cameron; Jean-Baptiste Maneyrol
>Cc: Jorijn van der Graaf; David Lechner; Nuno Sá; Andy Shevchenko; Rob Herring; Krzysztof Kozlowski; Conor Dooley; Chris Morgan; Luca Weiss; linux-iio@vger.kernel.org; devicetree@vger.kernel.org; linux-kernel@vger.kernel.org
>Subject: [PATCH 0/2] iio: imu: inv_icm42600: add support for icm42630
>
>The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family, used in the Fairphone 6. The existing inv_icm42600 driver drives it unmodified once its WHOAMI value is known, so this is just the compatible plus the chip id / WHOAMI table
>ZjQcmQRYFpfptBannerStart
>This Message Is From an External Sender
>This message came from outside your organization.
>
>ZjQcmQRYFpfptBannerEnd
>
>The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family,
>used in the Fairphone 6. The existing inv_icm42600 driver drives it
>unmodified once its WHOAMI value is known, so this is just the
>compatible plus the chip id / WHOAMI table entries.
>
>The part appears to be a mobile SKU and has no public datasheet. The
>name comes from the Fairphone 6 schematics and platform documentation;
>the WHOAMI value 0x0C was read from the hardware over both SPI and
>I2C, and the chip's bank 0 register defaults match the ICM-42600
>family layout. Jean-Baptiste, if you are able to confirm the part name
>and WHOAMI value from the TDK side, that would be very welcome.
>
Hello Jorijn,
I can confirm ICM-42630 is the correct name and is a chip similar to ICM-42631.
It can be supported by inv_icm42600 driver without any modification.
WHOAMI value is 0x0C, that's correct.
Thanks for your series,
JB
>Tested on the Fairphone 6: patch 2 applied to the device's 7.1-based
>kernel (with the id-table hunks adjusted to that base's style) drives
>the chip over a bit-banged SPI bus with INT1 wired to the SoC - probe,
>accelerometer, gyroscope and temperature raw reads, all full-scale
>ranges, multiple sampling frequencies, and watermark-paced FIFO reads
>through the INT1 interrupt. The accelerometer full scale was cross-checked against
>gravity (~2048 LSB/g at the default range, matching +-16g); the
>+-2000 dps gyroscope full scale is inferred from family membership,
>pending confirmation from TDK.
>
>The series is based on iio/togreg (base-commit below); on that base it
>builds (arm64 defconfig with the driver as modules, W=1 clean on the
>driver directory) and dt_binding_check passes.
>
>Note: Chris Morgan's in-flight ICM-42607 series [1] adds entries to
>the same binding enum; the overlap is context-only (different lines)
>and trivial for whichever lands second.
>
>[1] https://urldefense.com/v3/__https://lore.kernel.org/all/20260716182637.24310-1-macroalpha82@gmail.com/__;!!FtrhtPsWDhZ6tw!EMkKQset9Yby2oKxW0kPzUUw-xO1e0Se0_ponfx9sVFHe3ZpNkToWE9hCbKcOrvaXMEPxCQChCML3qSGp08krxDg7tbXgqqw_ZFV$[lore[.]kernel[.]org]
>
>The Fairphone 6 board DTS nodes will follow separately via the qcom
>tree once this lands.
>
>Jorijn van der Graaf (2):
> dt-bindings: iio: imu: icm42600: add icm42630
> iio: imu: inv_icm42600: add support for icm42630
>
> .../devicetree/bindings/iio/imu/invensense,icm42600.yaml | 1 +
> drivers/iio/imu/inv_icm42600/inv_icm42600.h | 2 ++
> drivers/iio/imu/inv_icm42600/inv_icm42600_core.c | 5 +++++
> drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c | 4 ++++
> drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c | 4 ++++
> 5 files changed, 16 insertions(+)
>
>
>base-commit: 036d96ceec6d966339aea34d034420991e24cfac
>--
>2.55.0
>
>
>
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630
2026-07-20 17:34 ` [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630 Jorijn van der Graaf
@ 2026-07-21 7:14 ` Jean-Baptiste Maneyrol
2026-07-21 16:01 ` Conor Dooley
1 sibling, 0 replies; 9+ messages in thread
From: Jean-Baptiste Maneyrol @ 2026-07-21 7:14 UTC (permalink / raw)
To: Jorijn van der Graaf, Jonathan Cameron
Cc: David Lechner, Nuno Sá, Andy Shevchenko, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Chris Morgan, Luca Weiss,
linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
>________________________________________
>From: Jorijn van der Graaf <jorijnvdgraaf@catcrafts.net>
>Sent: Monday, July 20, 2026 19:34
>To: Jonathan Cameron; Jean-Baptiste Maneyrol
>Cc: Jorijn van der Graaf; David Lechner; Nuno Sá; Andy Shevchenko; Rob Herring; Krzysztof Kozlowski; Conor Dooley; Chris Morgan; Luca Weiss; linux-iio@vger.kernel.org; devicetree@vger.kernel.org; linux-kernel@vger.kernel.org
>Subject: [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630
>
>The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family, found e. g. in the Fairphone 6. Document its compatible. A fallback compatible to a sibling is not usable: the part reports its own WHOAMI register value, which software validates
>ZjQcmQRYFpfptBannerStart
>This Message Is From an External Sender
>This message came from outside your organization.
>
>ZjQcmQRYFpfptBannerEnd
>
>The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family,
>found e.g. in the Fairphone 6. Document its compatible.
>
>A fallback compatible to a sibling is not usable: the part reports its
>own WHOAMI register value, which software validates against the
>compatible.
>
>Assisted-by: Claude:claude-fable-5
>Signed-off-by: Jorijn van der Graaf <jorijnvdgraaf@catcrafts.net>
>---
> .../devicetree/bindings/iio/imu/invensense,icm42600.yaml | 1 +
> 1 file changed, 1 insertion(+)
>
>diff --git a/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml b/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
>index 119e28a833fd..add3a7fef09d 100644
>--- a/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
>+++ b/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
>@@ -31,6 +31,7 @@ properties:
> - invensense,icm42602
> - invensense,icm42605
> - invensense,icm42622
>+ - invensense,icm42630
> - invensense,icm42631
> - invensense,icm42686
> - invensense,icm42688
>--
>2.55.0
>
>
Hello Jorijn,
it is OK for me, thanks for the patch.
Acked-by: Jean-Baptiste Maneyrol <jean-baptiste.maneyrol@tdk.com>
Thanks,
JB
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH 2/2] iio: imu: inv_icm42600: add support for icm42630
2026-07-20 17:34 ` [PATCH 2/2] iio: imu: inv_icm42600: add support for icm42630 Jorijn van der Graaf
@ 2026-07-21 7:18 ` Jean-Baptiste Maneyrol
0 siblings, 0 replies; 9+ messages in thread
From: Jean-Baptiste Maneyrol @ 2026-07-21 7:18 UTC (permalink / raw)
To: Jorijn van der Graaf, Jonathan Cameron
Cc: David Lechner, Nuno Sá, Andy Shevchenko, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Chris Morgan, Luca Weiss,
linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
>
>________________________________________
>From: Jorijn van der Graaf <jorijnvdgraaf@catcrafts.net>
>Sent: Monday, July 20, 2026 19:34
>To: Jonathan Cameron; Jean-Baptiste Maneyrol
>Cc: Jorijn van der Graaf; David Lechner; Nuno Sá; Andy Shevchenko; Rob Herring; Krzysztof Kozlowski; Conor Dooley; Chris Morgan; Luca Weiss; linux-iio@vger.kernel.org; devicetree@vger.kernel.org; linux-kernel@vger.kernel.org
>Subject: [PATCH 2/2] iio: imu: inv_icm42600: add support for icm42630
>
>The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family, found e. g. in the Fairphone 6. It is register-compatible with its siblings (the existing driver works on it unmodified) and reports WHOAMI value 0x0C. The part appears to
>ZjQcmQRYFpfptBannerStart
>This Message Is From an External Sender
>This message came from outside your organization.
>
>ZjQcmQRYFpfptBannerEnd
>
>The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family,
>found e.g. in the Fairphone 6. It is register-compatible with its
>siblings (the existing driver works on it unmodified) and reports
>WHOAMI value 0x0C.
>
>The part appears to be a mobile SKU and has no public datasheet: the
>identity comes from the Fairphone 6 platform documentation and
>schematics naming the part, and the WHOAMI value was read from the
>hardware, whose bank 0 register defaults match the ICM-42600 family
>layout.
>
>Add the chip id, WHOAMI value and I2C/SPI match entries, using the
>family default configuration like the ICM-42631.
>
>Tested on the Fairphone 6 via a backport of this change to the
>device's 7.1-based kernel (only the id-table style adjusted to that
>base), on a bit-banged SPI bus with INT1 wired to the SoC: probe,
>accelerometer, gyroscope and temperature raw reads, all full-scale
>ranges, multiple sampling frequencies, and watermark-paced FIFO reads
>through the INT1 interrupt.
>
>Assisted-by: Claude:claude-fable-5
>Signed-off-by: Jorijn van der Graaf <jorijnvdgraaf@catcrafts.net>
>---
> drivers/iio/imu/inv_icm42600/inv_icm42600.h | 2 ++
> drivers/iio/imu/inv_icm42600/inv_icm42600_core.c | 5 +++++
> drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c | 4 ++++
> drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c | 4 ++++
> 4 files changed, 15 insertions(+)
>
>diff --git a/drivers/iio/imu/inv_icm42600/inv_icm42600.h b/drivers/iio/imu/inv_icm42600/inv_icm42600.h
>index b55d993f0264..349de5458581 100644
>--- a/drivers/iio/imu/inv_icm42600/inv_icm42600.h
>+++ b/drivers/iio/imu/inv_icm42600/inv_icm42600.h
>@@ -28,6 +28,7 @@ enum inv_icm42600_chip {
> INV_CHIP_ICM42622,
> INV_CHIP_ICM42688,
> INV_CHIP_ICM42631,
>+ INV_CHIP_ICM42630,
> INV_CHIP_NB,
> };
>
>@@ -386,6 +387,7 @@ struct inv_icm42600_sensor_state {
> #define INV_ICM42600_WHOAMI_ICM42622 0x46
> #define INV_ICM42600_WHOAMI_ICM42688 0x47
> #define INV_ICM42600_WHOAMI_ICM42631 0x5C
>+#define INV_ICM42600_WHOAMI_ICM42630 0x0C
>
> /* User bank 1 (MSB 0x10) */
> #define INV_ICM42600_REG_SENSOR_CONFIG0 0x1003
>diff --git a/drivers/iio/imu/inv_icm42600/inv_icm42600_core.c b/drivers/iio/imu/inv_icm42600/inv_icm42600_core.c
>index dc97d8a274e3..9a31ca3615b3 100644
>--- a/drivers/iio/imu/inv_icm42600/inv_icm42600_core.c
>+++ b/drivers/iio/imu/inv_icm42600/inv_icm42600_core.c
>@@ -177,6 +177,11 @@ static const struct inv_icm42600_hw inv_icm42600_hw[INV_CHIP_NB] = {
> .name = "icm42631",
> .conf = &inv_icm42600_default_conf,
> },
>+ [INV_CHIP_ICM42630] = {
>+ .whoami = INV_ICM42600_WHOAMI_ICM42630,
>+ .name = "icm42630",
>+ .conf = &inv_icm42600_default_conf,
>+ },
> };
>
> const struct iio_mount_matrix *
>diff --git a/drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c b/drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c
>index 28552d2db91d..c413904c8680 100644
>--- a/drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c
>+++ b/drivers/iio/imu/inv_icm42600/inv_icm42600_i2c.c
>@@ -81,6 +81,7 @@ static const struct i2c_device_id inv_icm42600_id[] = {
> { .name = "icm42622", .driver_data = INV_CHIP_ICM42622 },
> { .name = "icm42688", .driver_data = INV_CHIP_ICM42688 },
> { .name = "icm42631", .driver_data = INV_CHIP_ICM42631 },
>+ { .name = "icm42630", .driver_data = INV_CHIP_ICM42630 },
> { }
> };
> MODULE_DEVICE_TABLE(i2c, inv_icm42600_id);
>@@ -107,6 +108,9 @@ static const struct of_device_id inv_icm42600_of_matches[] = {
> }, {
> .compatible = "invensense,icm42631",
> .data = (void *)INV_CHIP_ICM42631,
>+ }, {
>+ .compatible = "invensense,icm42630",
>+ .data = (void *)INV_CHIP_ICM42630,
> },
> { }
> };
>diff --git a/drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c b/drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c
>index faf743bc6444..a1d12ce3bf87 100644
>--- a/drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c
>+++ b/drivers/iio/imu/inv_icm42600/inv_icm42600_spi.c
>@@ -78,6 +78,7 @@ static const struct spi_device_id inv_icm42600_id[] = {
> { .name = "icm42622", .driver_data = INV_CHIP_ICM42622 },
> { .name = "icm42688", .driver_data = INV_CHIP_ICM42688 },
> { .name = "icm42631", .driver_data = INV_CHIP_ICM42631 },
>+ { .name = "icm42630", .driver_data = INV_CHIP_ICM42630 },
> { }
> };
> MODULE_DEVICE_TABLE(spi, inv_icm42600_id);
>@@ -104,6 +105,9 @@ static const struct of_device_id inv_icm42600_of_matches[] = {
> }, {
> .compatible = "invensense,icm42631",
> .data = (void *)INV_CHIP_ICM42631,
>+ }, {
>+ .compatible = "invensense,icm42630",
>+ .data = (void *)INV_CHIP_ICM42630,
> },
> { }
> };
>--
>2.55.0
>
Hello Jorijn,
it is OK for me, thanks for the patch.
Acked-by: Jean-Baptiste Maneyrol <jean-baptiste.maneyrol@tdk.com>
Thanks,
JB
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630
2026-07-20 17:34 ` [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630 Jorijn van der Graaf
2026-07-21 7:14 ` Jean-Baptiste Maneyrol
@ 2026-07-21 16:01 ` Conor Dooley
2026-07-21 17:16 ` Jorijn van der Graaf
1 sibling, 1 reply; 9+ messages in thread
From: Conor Dooley @ 2026-07-21 16:01 UTC (permalink / raw)
To: Jorijn van der Graaf
Cc: Jonathan Cameron, Jean-Baptiste Maneyrol, David Lechner,
Nuno Sá, Andy Shevchenko, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Chris Morgan, Luca Weiss, linux-iio, devicetree,
linux-kernel
[-- Attachment #1: Type: text/plain, Size: 1329 bytes --]
On Mon, Jul 20, 2026 at 07:34:10PM +0200, Jorijn van der Graaf wrote:
> The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family,
> found e.g. in the Fairphone 6. Document its compatible.
>
> A fallback compatible to a sibling is not usable: the part reports its
> own WHOAMI register value, which software validates against the
> compatible.
Why does software do this? If the whoami is the only difference, the
software should stop checking it.
>
> Assisted-by: Claude:claude-fable-5
> Signed-off-by: Jorijn van der Graaf <jorijnvdgraaf@catcrafts.net>
> ---
> .../devicetree/bindings/iio/imu/invensense,icm42600.yaml | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml b/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
> index 119e28a833fd..add3a7fef09d 100644
> --- a/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
> +++ b/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
> @@ -31,6 +31,7 @@ properties:
> - invensense,icm42602
> - invensense,icm42605
> - invensense,icm42622
> + - invensense,icm42630
> - invensense,icm42631
> - invensense,icm42686
> - invensense,icm42688
> --
> 2.55.0
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630
2026-07-21 16:01 ` Conor Dooley
@ 2026-07-21 17:16 ` Jorijn van der Graaf
2026-07-22 16:59 ` Conor Dooley
0 siblings, 1 reply; 9+ messages in thread
From: Jorijn van der Graaf @ 2026-07-21 17:16 UTC (permalink / raw)
To: Conor Dooley, Jean-Baptiste Maneyrol
Cc: Jorijn van der Graaf, Jonathan Cameron, David Lechner,
Nuno Sá, Andy Shevchenko, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Chris Morgan, Luca Weiss, linux-iio, devicetree,
linux-kernel
On Tue, Jul 21, 2026 at 05:01:26PM +0100, Conor Dooley wrote:
> On Mon, Jul 20, 2026 at 07:34:10PM +0200, Jorijn van der Graaf wrote:
> > The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family,
> > found e.g. in the Fairphone 6. Document its compatible.
> >
> > A fallback compatible to a sibling is not usable: the part reports its
> > own WHOAMI register value, which software validates against the
> > compatible.
>
> Why does software do this? If the whoami is the only difference, the
> software should stop checking it.
Whether the whoami is the only difference is exactly what I cannot
establish: the part has no public datasheet. What I can establish is
driver-visible: the unmodified driver has been tested to drive it
correctly, and Jean-Baptiste confirmed the chip is "similar" to the
ICM-42631 and "can be supported by inv_icm42600 driver without any
modification". That is short of knowing the parts are identical (the
family has precedent for real differences behind the same register
layout: ICM-42686, different full-scale ranges), so I did not want
to claim full compatibility with a sibling.
As for the check: it is not mine - inv_icm42600 has returned -ENODEV
on a whoami mismatch since its 2020 introduction (and per-part config
does differ within the family, see above). Since every released
kernel enforces it, a fallback would not probe on any kernel already
out there regardless of what we change now; and even if the check
were relaxed, a fallback-matched part would bind with icm42631 as
its ABI-visible name - so the dedicated compatible is needed either
way. Whether the check should become a warning is
Jean-Baptiste's call, as a behavior change for all parts the driver
supports; I did not want to gate a trivial ID addition on it, but am
happy to send that as a follow-up if wanted.
The commit message led with the driver check where the real reason
is the identity uncertainty above; I will reword that in a v2 if one
is needed.
Thanks,
Jorijn
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630
2026-07-21 17:16 ` Jorijn van der Graaf
@ 2026-07-22 16:59 ` Conor Dooley
0 siblings, 0 replies; 9+ messages in thread
From: Conor Dooley @ 2026-07-22 16:59 UTC (permalink / raw)
To: Jorijn van der Graaf
Cc: Jean-Baptiste Maneyrol, Jonathan Cameron, David Lechner,
Nuno Sá, Andy Shevchenko, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Chris Morgan, Luca Weiss, linux-iio, devicetree,
linux-kernel
[-- Attachment #1: Type: text/plain, Size: 3111 bytes --]
On Tue, Jul 21, 2026 at 07:16:47PM +0200, Jorijn van der Graaf wrote:
> On Tue, Jul 21, 2026 at 05:01:26PM +0100, Conor Dooley wrote:
> > On Mon, Jul 20, 2026 at 07:34:10PM +0200, Jorijn van der Graaf wrote:
> > > The TDK InvenSense ICM-42630 is a 6-axis IMU of the ICM-42600 family,
> > > found e.g. in the Fairphone 6. Document its compatible.
> > >
> > > A fallback compatible to a sibling is not usable: the part reports its
> > > own WHOAMI register value, which software validates against the
> > > compatible.
> >
> > Why does software do this? If the whoami is the only difference, the
> > software should stop checking it.
>
> Whether the whoami is the only difference is exactly what I cannot
> establish: the part has no public datasheet. What I can establish is
> driver-visible: the unmodified driver has been tested to drive it
> correctly, and Jean-Baptiste confirmed the chip is "similar" to the
> ICM-42631 and "can be supported by inv_icm42600 driver without any
> modification". That is short of knowing the parts are identical (the
> family has precedent for real differences behind the same register
> layout: ICM-42686, different full-scale ranges), so I did not want
> to claim full compatibility with a sibling.
>
> As for the check: it is not mine - inv_icm42600 has returned -ENODEV
> on a whoami mismatch since its 2020 introduction (and per-part config
> does differ within the family, see above). Since every released
> kernel enforces it, a fallback would not probe on any kernel already
> out there regardless of what we change now; and even if the check
> were relaxed, a fallback-matched part would bind with icm42631 as
> its ABI-visible name - so the dedicated compatible is needed either
Is that really problematic? It's not problematic for any of the dozens
of other IIO devices that use fallbacks, is there something that would
make this one different?
> way. Whether the check should become a warning is
> Jean-Baptiste's call, as a behavior change for all parts the driver
> supports; I did not want to gate a trivial ID addition on it, but am
> happy to send that as a follow-up if wanted.
The check should be deleted since it prevent using fallbacks.
IMO, delete the check and add the fallback rather than retain it and
propagate the issue. Even if you think having a fallback is a bad idea
because you cannot be 101% sure that there are no programming model
differences, delete the check. Personally I think that given the
testing, patches and quote from JeanBaptiste, a fallback is suitable
here.
I think Jonathan has sorta changed his stance "recently" on the
correctness of checking whoami values versus the compatible, so what was
done in 2020 doesn't represent what's the current guidance and I am
always a proponent of removing these checks whenever I become aware of
one preventing use of fallbacks.
Cheers,
Conor.
> The commit message led with the driver check where the real reason
> is the identity uncertainty above; I will reword that in a v2 if one
> is needed.
>
> Thanks,
> Jorijn
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2026-07-22 16:59 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-20 17:34 [PATCH 0/2] iio: imu: inv_icm42600: add support for icm42630 Jorijn van der Graaf
2026-07-20 17:34 ` [PATCH 1/2] dt-bindings: iio: imu: icm42600: add icm42630 Jorijn van der Graaf
2026-07-21 7:14 ` Jean-Baptiste Maneyrol
2026-07-21 16:01 ` Conor Dooley
2026-07-21 17:16 ` Jorijn van der Graaf
2026-07-22 16:59 ` Conor Dooley
2026-07-20 17:34 ` [PATCH 2/2] iio: imu: inv_icm42600: add support for icm42630 Jorijn van der Graaf
2026-07-21 7:18 ` Jean-Baptiste Maneyrol
2026-07-21 7:12 ` [PATCH 0/2] " Jean-Baptiste Maneyrol
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox