* [PATCH 1/3] dt-bindings: power: supply: ab8500: Standard monitored-battery
@ 2021-10-06 22:40 Linus Walleij
2021-10-07 12:05 ` Rob Herring
0 siblings, 1 reply; 3+ messages in thread
From: Linus Walleij @ 2021-10-06 22:40 UTC (permalink / raw)
To: Sebastian Reichel, Marcus Cooper; +Cc: linux-pm, Linus Walleij, devicetree
Make monitored-battery the standard phandle to the battery we monitor
for the AB8500 charger components. We make the old "battery" phandle
deprecated, and the new one required so we detect and fix all users to
use the standard phandle name.
Cc: devicetree@vger.kernel.org
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
.../bindings/power/supply/stericsson,ab8500-btemp.yaml | 10 +++++++---
.../power/supply/stericsson,ab8500-chargalg.yaml | 10 +++++++---
.../power/supply/stericsson,ab8500-charger.yaml | 10 +++++++---
.../bindings/power/supply/stericsson,ab8500-fg.yaml | 10 +++++++---
4 files changed, 28 insertions(+), 12 deletions(-)
diff --git a/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-btemp.yaml b/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-btemp.yaml
index 2f57aa5a5f4e..4b8a00cec39c 100644
--- a/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-btemp.yaml
+++ b/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-btemp.yaml
@@ -17,10 +17,14 @@ properties:
compatible:
const: stericsson,ab8500-btemp
- battery:
+ monitored-battery:
$ref: /schemas/types.yaml#/definitions/phandle
description: phandle to battery node
+ battery:
+ $ref: /schemas/types.yaml#/definitions/phandle
+ deprecated: true
+
interrupts:
maxItems: 5
@@ -42,7 +46,7 @@ properties:
required:
- compatible
- - battery
+ - monitored-battery
- interrupts
- interrupt-names
- io-channels
@@ -56,7 +60,7 @@ examples:
pmic {
battery-temperature {
compatible = "stericsson,ab8500-btemp";
- battery = <&ab8500_battery>;
+ monitored-battery = <&battery>;
interrupts = <20 IRQ_TYPE_LEVEL_HIGH>,
<80 IRQ_TYPE_LEVEL_HIGH>,
<83 IRQ_TYPE_LEVEL_HIGH>,
diff --git a/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-chargalg.yaml b/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-chargalg.yaml
index 0897231c2f6e..6799224f7fb4 100644
--- a/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-chargalg.yaml
+++ b/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-chargalg.yaml
@@ -17,13 +17,17 @@ properties:
compatible:
const: stericsson,ab8500-chargalg
- battery:
+ monitored-battery:
$ref: /schemas/types.yaml#/definitions/phandle
description: phandle to battery node
+ battery:
+ $ref: /schemas/types.yaml#/definitions/phandle
+ deprecated: true
+
required:
- compatible
- - battery
+ - monitored-battery
additionalProperties: false
@@ -32,6 +36,6 @@ examples:
pmic {
charging-algorithm {
compatible = "stericsson,ab8500-chargalg";
- battery = <&ab8500_battery>;
+ monitored-battery = <&ab8500_battery>;
};
};
diff --git a/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-charger.yaml b/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-charger.yaml
index e13305afea69..9518eb7289d0 100644
--- a/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-charger.yaml
+++ b/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-charger.yaml
@@ -17,10 +17,14 @@ properties:
compatible:
const: stericsson,ab8500-charger
- battery:
+ monitored-battery:
$ref: /schemas/types.yaml#/definitions/phandle
description: phandle to battery node
+ battery:
+ $ref: /schemas/types.yaml#/definitions/phandle
+ deprecated: true
+
vddadc-supply:
description: Supply for USB and Main charger
@@ -66,7 +70,7 @@ properties:
required:
- compatible
- - battery
+ - monitored-battery
- vddadc-supply
- interrupts
- interrupt-names
@@ -81,7 +85,7 @@ examples:
pmic {
charger {
compatible = "stericsson,ab8500-charger";
- battery = <&ab8500_battery>;
+ monitored-battery = <&battery>;
vddadc-supply = <&ab8500_ldo_tvout_reg>;
interrupts = <10 IRQ_TYPE_LEVEL_HIGH>,
<11 IRQ_TYPE_LEVEL_HIGH>,
diff --git a/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-fg.yaml b/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-fg.yaml
index db342e5ac0d1..54ac42a9d354 100644
--- a/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-fg.yaml
+++ b/Documentation/devicetree/bindings/power/supply/stericsson,ab8500-fg.yaml
@@ -17,10 +17,14 @@ properties:
compatible:
const: stericsson,ab8500-fg
- battery:
+ monitored-battery:
$ref: /schemas/types.yaml#/definitions/phandle
description: phandle to battery node
+ battery:
+ $ref: /schemas/types.yaml#/definitions/phandle
+ deprecated: true
+
interrupts:
maxItems: 5
@@ -41,7 +45,7 @@ properties:
required:
- compatible
- - battery
+ - monitored-battery
- interrupts
- interrupt-names
- io-channels
@@ -55,7 +59,7 @@ examples:
pmic {
fuel-gauge {
compatible = "stericsson,ab8500-fg";
- battery = <&ab8500_battery>;
+ monitored-battery = <&battery>;
interrupts = <24 IRQ_TYPE_LEVEL_HIGH>,
<8 IRQ_TYPE_LEVEL_HIGH>,
<28 IRQ_TYPE_LEVEL_HIGH>,
--
2.31.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/3] dt-bindings: power: supply: ab8500: Standard monitored-battery
2021-10-06 22:40 [PATCH 1/3] dt-bindings: power: supply: ab8500: Standard monitored-battery Linus Walleij
@ 2021-10-07 12:05 ` Rob Herring
2021-10-07 15:12 ` Linus Walleij
0 siblings, 1 reply; 3+ messages in thread
From: Rob Herring @ 2021-10-07 12:05 UTC (permalink / raw)
To: Linus Walleij; +Cc: Marcus Cooper, devicetree, Sebastian Reichel, linux-pm
On Thu, 07 Oct 2021 00:40:06 +0200, Linus Walleij wrote:
> Make monitored-battery the standard phandle to the battery we monitor
> for the AB8500 charger components. We make the old "battery" phandle
> deprecated, and the new one required so we detect and fix all users to
> use the standard phandle name.
>
> Cc: devicetree@vger.kernel.org
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> ---
> .../bindings/power/supply/stericsson,ab8500-btemp.yaml | 10 +++++++---
> .../power/supply/stericsson,ab8500-chargalg.yaml | 10 +++++++---
> .../power/supply/stericsson,ab8500-charger.yaml | 10 +++++++---
> .../bindings/power/supply/stericsson,ab8500-fg.yaml | 10 +++++++---
> 4 files changed, 28 insertions(+), 12 deletions(-)
>
Running 'make dtbs_check' with the schema in this patch gives the
following warnings. Consider if they are expected or the schema is
incorrect. These may not be new warnings.
Note that it is not yet a requirement to have 0 warnings for dtbs_check.
This will change in the future.
Full log is available here: https://patchwork.ozlabs.org/patch/1537450
ab8500_btemp: 'monitored-battery' is a required property
arch/arm/boot/dts/ste-href520-tvk.dt.yaml
arch/arm/boot/dts/ste-hrefprev60-stuib.dt.yaml
arch/arm/boot/dts/ste-hrefprev60-tvk.dt.yaml
arch/arm/boot/dts/ste-hrefv60plus-stuib.dt.yaml
arch/arm/boot/dts/ste-hrefv60plus-tvk.dt.yaml
arch/arm/boot/dts/ste-snowball.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-codina.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-gavini.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-janice.dt.yaml
ab8500_chargalg: 'monitored-battery' is a required property
arch/arm/boot/dts/ste-href520-tvk.dt.yaml
arch/arm/boot/dts/ste-hrefprev60-stuib.dt.yaml
arch/arm/boot/dts/ste-hrefprev60-tvk.dt.yaml
arch/arm/boot/dts/ste-hrefv60plus-stuib.dt.yaml
arch/arm/boot/dts/ste-hrefv60plus-tvk.dt.yaml
arch/arm/boot/dts/ste-snowball.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-codina.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-gavini.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-janice.dt.yaml
ab8500_charger: 'monitored-battery' is a required property
arch/arm/boot/dts/ste-href520-tvk.dt.yaml
arch/arm/boot/dts/ste-hrefprev60-stuib.dt.yaml
arch/arm/boot/dts/ste-hrefprev60-tvk.dt.yaml
arch/arm/boot/dts/ste-hrefv60plus-stuib.dt.yaml
arch/arm/boot/dts/ste-hrefv60plus-tvk.dt.yaml
arch/arm/boot/dts/ste-snowball.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-codina.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-gavini.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-janice.dt.yaml
ab8500_fg: 'monitored-battery' is a required property
arch/arm/boot/dts/ste-href520-tvk.dt.yaml
arch/arm/boot/dts/ste-hrefprev60-stuib.dt.yaml
arch/arm/boot/dts/ste-hrefprev60-tvk.dt.yaml
arch/arm/boot/dts/ste-hrefv60plus-stuib.dt.yaml
arch/arm/boot/dts/ste-hrefv60plus-tvk.dt.yaml
arch/arm/boot/dts/ste-snowball.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-codina.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-gavini.dt.yaml
arch/arm/boot/dts/ste-ux500-samsung-janice.dt.yaml
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 1/3] dt-bindings: power: supply: ab8500: Standard monitored-battery
2021-10-07 12:05 ` Rob Herring
@ 2021-10-07 15:12 ` Linus Walleij
0 siblings, 0 replies; 3+ messages in thread
From: Linus Walleij @ 2021-10-07 15:12 UTC (permalink / raw)
To: Rob Herring
Cc: Marcus Cooper,
open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
Sebastian Reichel, Linux PM list
On Thu, Oct 7, 2021 at 2:05 PM Rob Herring <robh@kernel.org> wrote:
> On Thu, 07 Oct 2021 00:40:06 +0200, Linus Walleij wrote:
> > Make monitored-battery the standard phandle to the battery we monitor
> > for the AB8500 charger components. We make the old "battery" phandle
> > deprecated, and the new one required so we detect and fix all users to
> > use the standard phandle name.
> >
> > Cc: devicetree@vger.kernel.org
> > Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> > ---
> > .../bindings/power/supply/stericsson,ab8500-btemp.yaml | 10 +++++++---
> > .../power/supply/stericsson,ab8500-chargalg.yaml | 10 +++++++---
> > .../power/supply/stericsson,ab8500-charger.yaml | 10 +++++++---
> > .../bindings/power/supply/stericsson,ab8500-fg.yaml | 10 +++++++---
> > 4 files changed, 28 insertions(+), 12 deletions(-)
> >
>
> Running 'make dtbs_check' with the schema in this patch gives the
> following warnings. Consider if they are expected or the schema is
> incorrect. These may not be new warnings.
All of these are fixed in patch 3/3.
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-10-07 15:12 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-10-06 22:40 [PATCH 1/3] dt-bindings: power: supply: ab8500: Standard monitored-battery Linus Walleij
2021-10-07 12:05 ` Rob Herring
2021-10-07 15:12 ` Linus Walleij
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).