Skip to contentSkip to conversation

dt-bindings: hwmon: adm1272: add adm1272-adm1275-temp1-en binding

PATCH In review Chu Lin 3 participants 6 messages Jul 10, 2020 – Jul 20, 2020

Subsystems (2)
lore
Share & tools
lore

Chu Lin

author
#0 lore raw

PATCH 1/1 dt-bindings: hwmon: adm1272: add adm1272-adm1275-temp1-en binding

Problem:
adm1272 and adm1278 supports temperature sampling. The
current way of enabling it requires the user manually unbind the device from the driver, flip the temperature sampling control bit and then bind the device back to the driver. It would be nice if we can control this in a better way by reading the dt.

Solution:
Introducing device tree binding adm1272-adm1278-temp1-en. If the
flag is set, flip the temp1_en control bit on probing.

Testing:
make dt_binding_check

---
 Documentation/devicetree/bindings/hwmon/adm1275.txt | 3 +++
 1 file changed, 3 insertions(+)
Documentation/devicetree/bindings/hwmon/adm1275.txt +3 -0
index 1ecd03f3da4d..4403fe30f005 100644
@@ -15,6 +15,8 @@ Optional properties:
 
 - shunt-resistor-micro-ohms
 	Shunt resistor value in micro-Ohm
+- adm1272-adm1278-temp1-en
+	Enable temperature sampling. This is supported on adm1272 and adm1278
 
 Example:
 
@@ -22,4 +24,5 @@ adm1272@10 {
 	compatible = "adi,adm1272";
 	reg = <0x10>;
 	shunt-resistor-micro-ohms = <500>;
+	adm1272-adm1278-temp1-en;
 };
Signature · 1 line
2.27.0.383.g050319c2ae-goog
author
#1 lore raw

Adding Rob to the review list.

Quoted 42 lines · Chu Lin

Problem:
adm1272 and adm1278 supports temperature sampling. The
current way of enabling it requires the user manually unbind the device from the driver, flip the temperature sampling control bit and then bind the device back to the driver. It would be nice if we can control this in a better way by reading the dt.

Solution:
Introducing device tree binding adm1272-adm1278-temp1-en. If the
flag is set, flip the temp1_en control bit on probing.

Testing:
make dt_binding_check

---
 Documentation/devicetree/bindings/hwmon/adm1275.txt | 3 +++
 1 file changed, 3 insertions(+)
Documentation/devicetree/bindings/hwmon/adm1275.txt +3 -1
index 1ecd03f3da4d..4403fe30f005 100644
@@ -15,6 +15,8 @@ Optional properties:
 
 - shunt-resistor-micro-ohms
        Shunt resistor value in micro-Ohm
+- adm1272-adm1278-temp1-en
+       Enable temperature sampling. This is supported on adm1272 and adm1278
 
 Example:
 
@@ -22,4 +24,5 @@ adm1272@10 {
        compatible = "adi,adm1272";
        reg = <0x10>;
        shunt-resistor-micro-ohms = <500>;
+       adm1272-adm1278-temp1-en;
 };
--

2.27.0.383.g050319c2ae-goog

maintainer
#2 lore raw
Quoted 2 lines · Chu Lin

Adding Rob to the review list.

Rob is running a robot on DT bindings patches. Adding him like this very likely won't trigger the robot.

Guenter

Quoted 43 lines · Chu Lin
Quoted 42 lines

Problem:
adm1272 and adm1278 supports temperature sampling. The
current way of enabling it requires the user manually unbind the device from the driver, flip the temperature sampling control bit and then bind the device back to the driver. It would be nice if we can control this in a better way by reading the dt.

Solution:
Introducing device tree binding adm1272-adm1278-temp1-en. If the
flag is set, flip the temp1_en control bit on probing.

Testing:
make dt_binding_check

---
 Documentation/devicetree/bindings/hwmon/adm1275.txt | 3 +++
 1 file changed, 3 insertions(+)
Documentation/devicetree/bindings/hwmon/adm1275.txt +3 -1
index 1ecd03f3da4d..4403fe30f005 100644
@@ -15,6 +15,8 @@ Optional properties:
 
 - shunt-resistor-micro-ohms
        Shunt resistor value in micro-Ohm
+- adm1272-adm1278-temp1-en
+       Enable temperature sampling. This is supported on adm1272 and adm1278
 
 Example:
 
@@ -22,4 +24,5 @@ adm1272@10 {
        compatible = "adi,adm1272";
        reg = <0x10>;
        shunt-resistor-micro-ohms = <500>;
+       adm1272-adm1278-temp1-en;
 };
--

2.27.0.383.g050319c2ae-goog

maintainer
#3 lore raw
In reply to Chu Lin
Quoted 24 lines · Chu Lin

Problem:
adm1272 and adm1278 supports temperature sampling. The
current way of enabling it requires the user manually unbind the device from the driver, flip the temperature sampling control bit and then bind the device back to the driver. It would be nice if we can control this in a better way by reading the dt.

Solution:
Introducing device tree binding adm1272-adm1278-temp1-en. If the
flag is set, flip the temp1_en control bit on probing.

Testing:
make dt_binding_check

---
 Documentation/devicetree/bindings/hwmon/adm1275.txt | 3 +++
 1 file changed, 3 insertions(+)
Documentation/devicetree/bindings/hwmon/adm1275.txt +0 -0
index 1ecd03f3da4d..4403fe30f005 100644

Documentation/devicetree/bindings/hwmon/adm1275.txt Optional properties: · line 19

Quoted 5 lines
Documentation/devicetree/bindings/hwmon/adm1275.txt +2 -0
@@ -15,6 +15,8 @@ Optional properties:
 
 - shunt-resistor-micro-ohms
 	Shunt resistor value in micro-Ohm
+- adm1272-adm1278-temp1-en
+	Enable temperature sampling. This is supported on adm1272 and adm1278

I suspect this should be something like "analog,temp1-enable". Either case, I would suggest to resend the series and copy DT maintainers at least on this patch.

Thanks,
Guenter

Quoted 9 lines
Documentation/devicetree/bindings/hwmon/adm1275.txt +1 -0
 Example:
 
@@ -22,4 +24,5 @@ adm1272@10 {
 	compatible = "adi,adm1272";
 	reg = <0x10>;
 	shunt-resistor-micro-ohms = <500>;
+	adm1272-adm1278-temp1-en;
 };
author
#4 lore raw
Quoted 27 lines · Guenter Roeck
Quoted 25 lines · Chu Lin

Problem:
adm1272 and adm1278 supports temperature sampling. The
current way of enabling it requires the user manually unbind the device from the driver, flip the temperature sampling control bit and then bind the device back to the driver. It would be nice if we can control this in a better way by reading the dt.

Solution:
Introducing device tree binding adm1272-adm1278-temp1-en. If the
flag is set, flip the temp1_en control bit on probing.

Testing:
make dt_binding_check

---
 Documentation/devicetree/bindings/hwmon/adm1275.txt | 3 +++
 1 file changed, 3 insertions(+)
Documentation/devicetree/bindings/hwmon/adm1275.txt +0 -0
index 1ecd03f3da4d..4403fe30f005 100644
@@ -15,6 +15,8 @@ Optional properties:
 
Quoted 8 lines

Documentation/devicetree/bindings/hwmon/adm1275.txt Optional properties: · line 19

Quoted 4 lines
Documentation/devicetree/bindings/hwmon/adm1275.txt +2 -0
 - shunt-resistor-micro-ohms
      Shunt resistor value in micro-Ohm
+- adm1272-adm1278-temp1-en
+     Enable temperature sampling. This is supported on adm1272 and adm1278

I suspect this should be something like "analog,temp1-enable". Either case, I would suggest to resend the series and copy DT maintainers at least on this patch.

Thanks for the heads up. I will send another review with a fix.

Thanks,
Chu

maintainer
#5 lore raw
In reply to Guenter Roeck
Quoted 26 lines · Guenter Roeck
Quoted 25 lines · Chu Lin

Problem:
adm1272 and adm1278 supports temperature sampling. The
current way of enabling it requires the user manually unbind the device from the driver, flip the temperature sampling control bit and then bind the device back to the driver. It would be nice if we can control this in a better way by reading the dt.

Solution:
Introducing device tree binding adm1272-adm1278-temp1-en. If the
flag is set, flip the temp1_en control bit on probing.

Testing:
make dt_binding_check

---
 Documentation/devicetree/bindings/hwmon/adm1275.txt | 3 +++
 1 file changed, 3 insertions(+)
Documentation/devicetree/bindings/hwmon/adm1275.txt +0 -0
index 1ecd03f3da4d..4403fe30f005 100644
@@ -15,6 +15,8 @@ Optional properties:
 
Quoted 6 lines

Documentation/devicetree/bindings/hwmon/adm1275.txt Optional properties: · line 19

Quoted 4 lines
Documentation/devicetree/bindings/hwmon/adm1275.txt +2 -0
 - shunt-resistor-micro-ohms
 	Shunt resistor value in micro-Ohm
+- adm1272-adm1278-temp1-en
+	Enable temperature sampling. This is supported on adm1272 and adm1278

I suspect this should be something like "analog,temp1-enable".

Yes.

Quoted 3 lines

Either case,
I would suggest to resend the series and copy DT maintainers at least on this patch.

Only the DT list matters.

Rob