Skip to content

Commit 13ab5fd

Browse files
jonhuntergroeck
authored andcommitted
dt-bindings: hwmon: ina3221: Add ti,summation-disable
The INA3221 has a critical alert pin that can be controlled by the summation control function. This function adds the single shunt-voltage conversions for the desired channels in order to compare the combined sum to the programmed limit. The Shunt-Voltage Sum Limit register contains the programmed value that is compared to the value in the Shunt-Voltage Sum register in order to determine if the total summed limit is exceeded. If the shunt-voltage sum limit value is exceeded, the critical alert pin pulls low. For the summation limit to have a meaningful value, it is necessary to use the same shunt-resistor value on all included channels. Add a new vendor specific property, 'ti,summation-disable', to allow specific channels to be excluded from the summation control function if the shunt resistor is different to other channels or the channel should not be considered for triggering the critical alert pin. Note that the ina3221 has always supported summing the various input channels and summation is enabled by default if the shunt-resistor values are the same. This change simply provides a way to exclude inputs from the summation. If this property is not populated, then the functionality of the driver does not change. Signed-off-by: Jon Hunter <[email protected]> Signed-off-by: Ninad Malwade <[email protected]> Reviewed-by: Rob Herring <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
1 parent 81b75e3 commit 13ab5fd

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

Documentation/devicetree/bindings/hwmon/ti,ina3221.yaml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,25 @@ patternProperties:
5858
shunt-resistor-micro-ohms:
5959
description: shunt resistor value in micro-Ohm
6060

61+
ti,summation-disable:
62+
description: |
63+
The INA3221 has a critical alert pin that can be controlled by the
64+
summation control function. This function adds the single
65+
shunt-voltage conversions for the desired channels in order to
66+
compare the combined sum to the programmed limit. The Shunt-Voltage
67+
Sum Limit register contains the programmed value that is compared
68+
to the value in the Shunt-Voltage Sum register in order to
69+
determine if the total summed limit is exceeded. If the
70+
shunt-voltage sum limit value is exceeded, the critical alert pin
71+
is asserted.
72+
73+
For the summation limit to have a meaningful value, it is necessary
74+
to use the same shunt-resistor value on all enabled channels. If
75+
this is not the case or if a channel should not be used for
76+
triggering the critical alert pin, then this property can be used
77+
exclude specific channels from the summation control function.
78+
type: boolean
79+
6180
required:
6281
- reg
6382

0 commit comments

Comments
 (0)