diff options
| author | Martino Facchin <m.facchin@arduino.cc> | 2026-06-11 16:05:25 +0200 |
|---|---|---|
| committer | Guenter Roeck <linux@roeck-us.net> | 2026-08-10 08:59:40 -0700 |
| commit | d1db9b08fbf399ace18cb99adfd609d7e5582b73 (patch) | |
| tree | 2ece0a24dc1d9bb4d78e66fcefba0161d908b8d8 | |
| parent | 6fe4043c161978e6fbcd8eee4f23b119279bf705 (diff) | |
| download | linux-d1db9b08fbf399ace18cb99adfd609d7e5582b73.tar.gz linux-d1db9b08fbf399ace18cb99adfd609d7e5582b73.zip | |
hwmon: (ina2xx) Add support for INA232
The INA232 is a current/power monitor. It shares the same register
layout as the other chips in the series and uses the INA226 default
configuration, but differs in its electrical characteristics:
Signed-off-by: Martino Facchin <m.facchin@arduino.cc>
Signed-off-by: Loic Poulain <loic.poulain@oss.qualcomm.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20260611-monza-ina232-v2-2-e4375ce652d0@oss.qualcomm.com
[groeck: Rephrased commit message]
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
| -rw-r--r-- | drivers/hwmon/ina2xx.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/drivers/hwmon/ina2xx.c b/drivers/hwmon/ina2xx.c index 449a72c6b40b..5c6dc2c370d8 100644 --- a/drivers/hwmon/ina2xx.c +++ b/drivers/hwmon/ina2xx.c @@ -123,6 +123,7 @@ static const struct regmap_config ina2xx_regmap_config = { enum ina2xx_ids { ina219, ina226, + ina232, ina234, ina260, sy24655 @@ -197,6 +198,20 @@ static const struct ina2xx_config ina2xx_config[] = { .current_shift = 4, .has_update_interval = true, }, + [ina232] = { + .config_default = INA226_CONFIG_DEFAULT, + .calibration_value = 2048, + .shunt_div = 400, + .shunt_voltage_shift = 0, + .bus_voltage_shift = 0, + .bus_voltage_lsb = 1600, + .power_lsb_factor = 32, + .has_alerts = true, + .has_ishunt = false, + .has_power_average = false, + .current_shift = 0, + .has_update_interval = true, + }, [ina260] = { .config_default = INA260_CONFIG_DEFAULT, .shunt_div = 400, @@ -1014,6 +1029,7 @@ static const struct i2c_device_id ina2xx_id[] = { { .name = "ina226", .driver_data = ina226 }, { .name = "ina230", .driver_data = ina226 }, { .name = "ina231", .driver_data = ina226 }, + { .name = "ina232", .driver_data = ina232 }, { .name = "ina234", .driver_data = ina234 }, { .name = "ina260", .driver_data = ina260 }, { .name = "sy24655", .driver_data = sy24655 }, @@ -1047,6 +1063,10 @@ static const struct of_device_id __maybe_unused ina2xx_of_match[] = { .data = (void *)ina226 }, { + .compatible = "ti,ina232", + .data = (void *)ina232 + }, + { .compatible = "ti,ina234", .data = (void *)ina234 }, |
