Skip to contentSkip to conversation

iio: temperature: tmp117: Support the TMP119 sensor

PATCH In review Romain Gantois 4 participants 6 messages Jun 30

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

v3 cover iio: temperature: tmp117: Support the TMP119 sensor

Hello everyone,

This is version three of my series which adds support for the TMP119, which has an identical programming model to the TMP117, but slightly different specs and electrical characteristics.

Best Regards,

Romain

---
Changes in v3:
- Corrected indentation in device tree bindings
- Added an explicit inclusion of array_size.h
- Made sure the correct IIO device name was exposed to userspace
- Link to v2: https://patch.msgid.link/[email protected]

Changes in v2:
- Used ti,tmp117 as a fallback compatible
- Made sure the correct IIO device name was exposed to userspace
- Link to v1: https://patch.msgid.link/[email protected]

To: Puranjay Mohan <[email protected]>
To: Jonathan Cameron <[email protected]>
To: David Lechner <[email protected]>
To: Nuno Sá <[email protected]>
To: Andy Shevchenko <[email protected]>
To: Rob Herring <[email protected]>
To: Krzysztof Kozlowski <[email protected]>
To: Conor Dooley <[email protected]>
Cc: Thomas Petazzoni <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]

---
Romain Gantois (1):
dt-bindings: iio: ti,tmp117: add binding for the TMP119

Wil Stark (1):
iio: temperature: tmp117: add TI TMP119 support

 .../devicetree/bindings/iio/temperature/ti,tmp117.yaml   | 16 +++++++++++-----
 drivers/iio/temperature/tmp117.c                         | 13 +++++++++++++
 2 files changed, 24 insertions(+), 5 deletions(-)

---
base-commit: dc59e4fea9d83f03bad6bddf3fa2e52491777482
change-id: 20260605-tmp119-662d21e4d317

Best regards,

Signature · 1 line
Romain Gantois <[email protected]>
#1 lore raw

PATCH v3 1/2 dt-bindings: iio: ti,tmp117: add binding for the TMP119

The TMP119 has the same register layout as the TMP117, and a better local sensor accuracy. Add a compatible for it.

Use ti,tmp117 as a fallback compatible for ti,tmp119.

---
 .../devicetree/bindings/iio/temperature/ti,tmp117.yaml   | 16 +++++++++++-----
 1 file changed, 11 insertions(+), 5 deletions(-)
Documentation/devicetree/bindings/iio/temperature/ti,tmp117.yaml +11 -5
index fbba5e934861c..7fb3e68207919 100644
@@ -7,19 +7,25 @@ $schema: http://devicetree.org/meta-schemas/core.yaml#
 title: TI TMP117 - Digital temperature sensor with integrated NV memory
 
 description: |
-    TI TMP116/117 - Digital temperature sensor with integrated NV memory that
-    supports I2C interface.
+    TI TMP116/117/119 - Digital temperature sensor with integrated NV memory
+    that supports I2C interface.
       https://www.ti.com/lit/gpn/tmp116
       https://www.ti.com/lit/gpn/tmp117
+      https://www.ti.com/lit/gpn/tmp119
 
 maintainers:
   - Puranjay Mohan <[email protected]>
 
 properties:
   compatible:
-    enum:
-      - ti,tmp116
-      - ti,tmp117
+    oneOf:
+      - enum:
+          - ti,tmp116
+          - ti,tmp117
+      - items:
+          - enum:
+              - ti,tmp119
+          - const: ti,tmp117
 
   reg:
     maxItems: 1
Signature · 1 line
2.54.0
#3 lore raw

PATCH v3 2/2 iio: temperature: tmp117: add TI TMP119 support

In reply to Romain Gantois

From: Wil Stark <[email protected]>

Add support for the TMP119 temperature sensor, which has the same programming model as the TMP117.

[rgantois: Rebased from v6.6.58 to v7.2-rc1]
[rgantois: Commit log]
---
 drivers/iio/temperature/tmp117.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)
drivers/iio/temperature/tmp117.c +13 -0
index 6bc18616ad15e..74cb8d62bef3c 100644
@@ -9,6 +9,7 @@
  * Note: This driver assumes that the sensor has been calibrated beforehand.
  */
 
+#include <linux/array_size.h>
 #include <linux/delay.h>
 #include <linux/err.h>
 #include <linux/i2c.h>
@@ -38,6 +39,7 @@
 
 #define TMP116_DEVICE_ID		0x1116
 #define TMP117_DEVICE_ID		0x0117
+#define TMP119_DEVICE_ID		0x2117
 
 struct tmp117_data {
 	struct i2c_client *client;
@@ -139,6 +141,12 @@ static const struct tmp11x_info tmp117_channels_info = {
 	.num_channels = ARRAY_SIZE(tmp117_channels)
 };
 
+static const struct tmp11x_info tmp119_channels_info = {
+	.name = "tmp119",
+	.channels = tmp117_channels,
+	.num_channels = ARRAY_SIZE(tmp117_channels)
+};
+
 static const struct iio_info tmp117_info = {
 	.read_raw = tmp117_read_raw,
 	.write_raw = tmp117_write_raw,
@@ -172,6 +180,9 @@ static int tmp117_probe(struct i2c_client *client)
 	case TMP117_DEVICE_ID:
 		match_data = &tmp117_channels_info;
 		break;
+	case TMP119_DEVICE_ID:
+		match_data = &tmp119_channels_info;
+		break;
 	default:
 		dev_info(&client->dev,
 			 "Unknown device id (0x%x), use fallback compatible\n",
@@ -204,6 +215,7 @@ static int tmp117_probe(struct i2c_client *client)
 static const struct of_device_id tmp117_of_match[] = {
 	{ .compatible = "ti,tmp116", .data = &tmp116_channels_info },
 	{ .compatible = "ti,tmp117", .data = &tmp117_channels_info },
+	{ .compatible = "ti,tmp119", .data = &tmp119_channels_info },
 	{ }
 };
 MODULE_DEVICE_TABLE(of, tmp117_of_match);
@@ -211,6 +223,7 @@ MODULE_DEVICE_TABLE(of, tmp117_of_match);
 static const struct i2c_device_id tmp117_id[] = {
 	{ .name = "tmp116", .driver_data = (kernel_ulong_t)&tmp116_channels_info },
 	{ .name = "tmp117", .driver_data = (kernel_ulong_t)&tmp117_channels_info },
+	{ .name = "tmp119", .driver_data = (kernel_ulong_t)&tmp119_channels_info },
 	{ }
 };
 MODULE_DEVICE_TABLE(i2c, tmp117_id);
Signature · 1 line
2.54.0
Reviewed-by on v3 2/2
#4 lore raw

Re: [PATCH v3 2/2] iio: temperature: tmp117: add TI TMP119 support

Quoted 2 lines · Romain Gantois

Add support for the TMP119 temperature sensor, which has the same programming model as the TMP117.

Fine with me,

Signature · 2 lines
With Best Regards,
Andy Shevchenko
maintainer
#5 lore raw
In reply to Romain Gantois
Quoted 11 lines · On Tue, 30 Jun 2026 11:26:33 +0200 Romain Gantois <[email protected]>…

Hello everyone,

This is version three of my series which adds support for the TMP119, which has an identical programming model to the TMP117, but slightly different specs and electrical characteristics.

Best Regards,

Romain

Applied to the testing branch of iio.git. I'll push it out as togreg for linux-next to pick up once I've caught up with my rather large review backlog and anything applied has been through a bit of bot testing!

Thanks,

Jonathan

Quoted 44 lines

---
Changes in v3:
- Corrected indentation in device tree bindings
- Added an explicit inclusion of array_size.h
- Made sure the correct IIO device name was exposed to userspace
- Link to v2: https://patch.msgid.link/[email protected]

Changes in v2:
- Used ti,tmp117 as a fallback compatible
- Made sure the correct IIO device name was exposed to userspace
- Link to v1: https://patch.msgid.link/[email protected]

To: Puranjay Mohan <[email protected]>
To: Jonathan Cameron <[email protected]>
To: David Lechner <[email protected]>
To: Nuno Sá <[email protected]>
To: Andy Shevchenko <[email protected]>
To: Rob Herring <[email protected]>
To: Krzysztof Kozlowski <[email protected]>
To: Conor Dooley <[email protected]>
Cc: Thomas Petazzoni <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]

---
Romain Gantois (1):
dt-bindings: iio: ti,tmp117: add binding for the TMP119

Wil Stark (1):
iio: temperature: tmp117: add TI TMP119 support

 .../devicetree/bindings/iio/temperature/ti,tmp117.yaml   | 16 +++++++++++-----
 drivers/iio/temperature/tmp117.c                         | 13 +++++++++++++
 2 files changed, 24 insertions(+), 5 deletions(-)

---
base-commit: dc59e4fea9d83f03bad6bddf3fa2e52491777482
change-id: 20260605-tmp119-662d21e4d317

Best regards,

Signature · 1 line
Romain Gantois <[email protected]>