Skip to contentSkip to conversation

dt-bindings: mfd: bd71828: Use charger resistor in mOhm instead of MOhm

PATCH Applied Andreas Kemnade 4 participants 4 messages Nov 11, 2024 – Nov 12, 2024

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

PATCH v2 1/1 dt-bindings: mfd: bd71828: Use charger resistor in mOhm instead of MOhm

Apparently there was some confusion regarding milliohm vs. megaohm. (m/M). Use microohms to be able to properly specify the charger resistor like other drivers do. This is not used yet by mainline code yet. Specify a current sense resistor in milliohms range rather then megaohms range in the examples.

---
Changes in V2:
- typo fix

 .../devicetree/bindings/mfd/rohm,bd71828-pmic.yaml  | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
Documentation/devicetree/bindings/mfd/rohm,bd71828-pmic.yaml +7 -6
index fa17686a64f7..09e7d68e92bf 100644
@@ -55,14 +55,15 @@ properties:
     minimum: 0
     maximum: 1
 
-  rohm,charger-sense-resistor-ohms:
-    minimum: 10000000
-    maximum: 50000000
+  rohm,charger-sense-resistor-micro-ohms:
+    minimum: 10000
+    maximum: 50000
+    default: 30000
     description: |
       BD71827 and BD71828 have SAR ADC for measuring charging currents.
       External sense resistor (RSENSE in data sheet) should be used. If some
-      other but 30MOhm resistor is used the resistance value should be given
-      here in Ohms.
+      other but 30mOhm resistor is used the resistance value should be given
+      here in microohms.
 
   regulators:
     $ref: /schemas/regulator/rohm,bd71828-regulator.yaml
@@ -114,7 +115,7 @@ examples:
             #gpio-cells = <2>;
             gpio-reserved-ranges = <0 1>, <2 1>;
 
-            rohm,charger-sense-resistor-ohms = <10000000>;
+            rohm,charger-sense-resistor-micro-ohms = <10000>;
 
             regulators {
                 buck1: BUCK1 {
Signature · 1 line
2.39.5
Acked-by on v2 1/1
#1 lore raw
Quoted 11 lines · Andreas Kemnade

Apparently there was some confusion regarding milliohm vs. megaohm. (m/M). Use microohms to be able to properly specify the charger resistor like other drivers do. This is not used yet by mainline code yet. Specify a current sense resistor in milliohms range rather then megaohms range in the examples.

Reviewed-by on v2 1/1
#2 lore raw
In reply to Andreas Kemnade

Hi,

Quoted 6 lines · Andreas Kemnade

Apparently there was some confusion regarding milliohm vs. megaohm. (m/M). Use microohms to be able to properly specify the charger resistor like other drivers do. This is not used yet by mainline code yet. Specify a current sense resistor in milliohms range rather then megaohms range in the examples.

Quoted 6 lines

---

-- Sebastian

Quoted 43 lines

Changes in V2:
- typo fix

 .../devicetree/bindings/mfd/rohm,bd71828-pmic.yaml  | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
Documentation/devicetree/bindings/mfd/rohm,bd71828-pmic.yaml +7 -6
index fa17686a64f7..09e7d68e92bf 100644
@@ -55,14 +55,15 @@ properties:
     minimum: 0
     maximum: 1
 
-  rohm,charger-sense-resistor-ohms:
-    minimum: 10000000
-    maximum: 50000000
+  rohm,charger-sense-resistor-micro-ohms:
+    minimum: 10000
+    maximum: 50000
+    default: 30000
     description: |
       BD71827 and BD71828 have SAR ADC for measuring charging currents.
       External sense resistor (RSENSE in data sheet) should be used. If some
-      other but 30MOhm resistor is used the resistance value should be given
-      here in Ohms.
+      other but 30mOhm resistor is used the resistance value should be given
+      here in microohms.
 
   regulators:
     $ref: /schemas/regulator/rohm,bd71828-regulator.yaml
@@ -114,7 +115,7 @@ examples:
             #gpio-cells = <2>;
             gpio-reserved-ranges = <0 1>, <2 1>;
 
-            rohm,charger-sense-resistor-ohms = <10000000>;
+            rohm,charger-sense-resistor-micro-ohms = <10000>;
 
             regulators {
                 buck1: BUCK1 {
Signature · 1 line
2.39.5
maintainer Applied
#3 lore raw

Re: (subset) [PATCH v2] dt-bindings: mfd: bd71828: Use charger resistor in mOhm instead of MOhm

In reply to Andreas Kemnade
Quoted 8 lines · Andreas Kemnade

Apparently there was some confusion regarding milliohm vs. megaohm. (m/M). Use microohms to be able to properly specify the charger resistor like other drivers do. This is not used yet by mainline code yet. Specify a current sense resistor in milliohms range rather then megaohms range in the examples.

[...]

Applied, thanks!

[1/1] dt-bindings: mfd: bd71828: Use charger resistor in mOhm instead of MOhm

      commit: 8ece9d248b851b97e1e0779caa2ca98df9bc41f7

--
Lee Jones [李琼斯]