diff mbox series

[2/6] dt-bindings: Add ENS160 as trivial device

Message ID 20240512210444.30824-3-gustavograzs@gmail.com (mailing list archive)
State Changes Requested
Headers show
Series Add driver for ENS160 sensor | expand

Commit Message

Gustavo Silva May 12, 2024, 9:04 p.m. UTC
ScioSense ENS160 is a multi-gas sensor.

Signed-off-by: Gustavo Silva <gustavograzs@gmail.com>
---
 Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++
 1 file changed, 2 insertions(+)

Comments

Conor Dooley May 13, 2024, 4:09 p.m. UTC | #1
On Sun, May 12, 2024 at 06:04:38PM -0300, Gustavo Silva wrote:
> ScioSense ENS160 is a multi-gas sensor.
> 
> Signed-off-by: Gustavo Silva <gustavograzs@gmail.com>

Looks like this device has two supplies, Vdd and Vddio.
Jonathan generally likes supplies to be documented, so that would
disqualify this as a trivial device.

Cheers,
Conor.

> ---
>  Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/trivial-devices.yaml b/Documentation/devicetree/bindings/trivial-devices.yaml
> index e07be7bf8..cdd7f0b46 100644
> --- a/Documentation/devicetree/bindings/trivial-devices.yaml
> +++ b/Documentation/devicetree/bindings/trivial-devices.yaml
> @@ -318,6 +318,8 @@ properties:
>            - samsung,24ad0xd1
>              # Samsung Exynos SoC SATA PHY I2C device
>            - samsung,exynos-sataphy-i2c
> +            # ScioSense ENS160 multi-gas sensor
> +          - sciosense,ens160
>              # Semtech sx1301 baseband processor
>            - semtech,sx1301
>              # Sensirion multi-pixel gas sensor with I2C interface
> -- 
> 2.45.0
>
Jonathan Cameron May 19, 2024, 12:33 p.m. UTC | #2
On Mon, 13 May 2024 17:09:46 +0100
Conor Dooley <conor@kernel.org> wrote:

> On Sun, May 12, 2024 at 06:04:38PM -0300, Gustavo Silva wrote:
> > ScioSense ENS160 is a multi-gas sensor.
> > 
> > Signed-off-by: Gustavo Silva <gustavograzs@gmail.com>  
> 
> Looks like this device has two supplies, Vdd and Vddio.
> Jonathan generally likes supplies to be documented, so that would
> disqualify this as a trivial device.

Agreed. History here is that we have put lots of IIO supported
devices in trivial-devices in the past and then it's turned out
someone has them on a board where they are controllable supplies.
So we end up having introduced insufficient binding docs + need
to move it later.

Much better to just have them documented from the start + just
turn them on at driver probe and off at remove (relying on regulator
subsystem support for fake supplies / fixed regulators where these
operations do nothing).  If someone wants to later do better power
control then that can be added without adding to the binding.

Jonathan

> 
> Cheers,
> Conor.
> 
> > ---
> >  Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++
> >  1 file changed, 2 insertions(+)
> > 
> > diff --git a/Documentation/devicetree/bindings/trivial-devices.yaml b/Documentation/devicetree/bindings/trivial-devices.yaml
> > index e07be7bf8..cdd7f0b46 100644
> > --- a/Documentation/devicetree/bindings/trivial-devices.yaml
> > +++ b/Documentation/devicetree/bindings/trivial-devices.yaml
> > @@ -318,6 +318,8 @@ properties:
> >            - samsung,24ad0xd1
> >              # Samsung Exynos SoC SATA PHY I2C device
> >            - samsung,exynos-sataphy-i2c
> > +            # ScioSense ENS160 multi-gas sensor
> > +          - sciosense,ens160
> >              # Semtech sx1301 baseband processor
> >            - semtech,sx1301
> >              # Sensirion multi-pixel gas sensor with I2C interface
> > -- 
> > 2.45.0
> >
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/trivial-devices.yaml b/Documentation/devicetree/bindings/trivial-devices.yaml
index e07be7bf8..cdd7f0b46 100644
--- a/Documentation/devicetree/bindings/trivial-devices.yaml
+++ b/Documentation/devicetree/bindings/trivial-devices.yaml
@@ -318,6 +318,8 @@  properties:
           - samsung,24ad0xd1
             # Samsung Exynos SoC SATA PHY I2C device
           - samsung,exynos-sataphy-i2c
+            # ScioSense ENS160 multi-gas sensor
+          - sciosense,ens160
             # Semtech sx1301 baseband processor
           - semtech,sx1301
             # Sensirion multi-pixel gas sensor with I2C interface