Re: [PATCH v3 1/2] dt-bindings: at24: add new optional power-supply property

From: Rob Herring
Date: Mon Aug 29 2022 - 14:56:13 EST


On Sun, Aug 28, 2022 at 10:49 AM Eliav Farber <farbere@xxxxxxxxxx> wrote:
>
> Boards using the AT24 EEPROMs might have a GPIO that controls the power
> supply of the chip, and it must be set to enable the usage of it.
>
> Add a new optional property to the device tree binding document, which
> allows to specify a GPIO regulator for the pin that controls the power.
>
> On Linux this means that we need to enable the GPIO at the beginning of
> probe function, before trying to access the chip.
>
> Signed-off-by: Eliav Farber <farbere@xxxxxxxxxx>
> ---
> V2 -> V3:
> Apply on top of v6.0-rc1
>
> Documentation/devicetree/bindings/eeprom/at24.yaml | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/eeprom/at24.yaml b/Documentation/devicetree/bindings/eeprom/at24.yaml
> index d14e0accbda8..82f0046f67a9 100644
> --- a/Documentation/devicetree/bindings/eeprom/at24.yaml
> +++ b/Documentation/devicetree/bindings/eeprom/at24.yaml
> @@ -179,6 +179,10 @@ properties:
> description:
> phandle of the regulator that provides the supply voltage.
>
> + power-supply:

The datasheets I looked at say the supply name is 'VCC', so vcc-supply.

> + description:
> + phandle of the gpio regulator that provides the supply voltage.

What the connection is is outside the scope of the binding. IOW, it
might not be a GPIO controlled regulator. So drop the description.

> +
> required:
> - compatible
> - reg
> --
> 2.37.1
>