Re: [PATCH 2/3] dt-bindings: chrome: add new binding google,cros-ec-chrage-state
From: Krzysztof Kozlowski
Date: Wed Nov 20 2024 - 11:37:49 EST
On 18/11/2024 10:33, Sung-Chi, Li wrote:
> Add new dt bindings for charge chip control. The charge chip control
> dt configuration is used by the driver 'cros-ec-charge-state', which is
> added in the commit "platform/chrome: cros_ec_charge_state: add new
> driver to control charge".
>
> As these charge chip controls are connected under the ChromeOS Embedded
> Controller (EC), also add the patternProperties to the
> mfd/google,cros-ec bindings.
>
> Signed-off-by: Sung-Chi, Li <lschyi@xxxxxxxxxxxx>
> ---
> .../bindings/chrome/google,cros-charge-state.yaml | 62 ++++++++++++++++++++++
> .../devicetree/bindings/mfd/google,cros-ec.yaml | 4 ++
> 2 files changed, 66 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/chrome/google,cros-charge-state.yaml b/Documentation/devicetree/bindings/chrome/google,cros-charge-state.yaml
> new file mode 100644
> index 000000000000..40e8f6988769
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/chrome/google,cros-charge-state.yaml
> @@ -0,0 +1,62 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/chrome/google,cros-charge-state.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Google Chrome OS EC(Embedded Controller) charge state driver.
Capitalize, drop driver, drop full stop.
...
> +examples:
> + - |+
No need for +
> + spi {
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + cros_ec: ec@0 {
> + compatible = "google,cros-ec-spi";
> + reg = <0>;
> + interrupts = <35 0>;
> +
> + charge_chip_battery_current: charge-chip-battery {
1. Drop unused label.
2. So this is a battery? Then just "battery"... or this is a charger?
Please look how power supplies are done. This should not be different.
Best regards,
Krzysztof