lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7a6290b673d8d9492418365392b2554e310ef557.camel@gmail.com>
Date: Mon, 13 Jan 2025 09:29:44 +0000
From: Nuno Sá <noname.nuno@...il.com>
To: Jonathan Cameron <jic23@...nel.org>, Robert Budai
 <robert.budai@...log.com>
Cc: Nuno Sa <nuno.sa@...log.com>, Ramona Gradinariu	
 <ramona.gradinariu@...log.com>, Antoniu Miclaus
 <antoniu.miclaus@...log.com>,  Lars-Peter Clausen	 <lars@...afoo.de>,
 Michael Hennerich <Michael.Hennerich@...log.com>, Rob Herring
 <robh@...nel.org>, Krzysztof Kozlowski <krzk+dt@...nel.org>, Conor Dooley	
 <conor+dt@...nel.org>, Jonathan Corbet <corbet@....net>, Alex Lanzano	
 <lanzano.alex@...il.com>, linux-iio@...r.kernel.org,
 devicetree@...r.kernel.org, 	linux-kernel@...r.kernel.org,
 linux-doc@...r.kernel.org
Subject: Re: [PATCH v4 4/6] dt-bindings: iio: Add adis16550 bindings

On Sun, 2025-01-12 at 15:48 +0000, Jonathan Cameron wrote:
> On Fri, 10 Jan 2025 09:42:52 +0200
> Robert Budai <robert.budai@...log.com> wrote:
> 
> > Document the ADIS16550 device devicetree bindings.
> > 
> > Co-developed-by: Antoniu Miclaus <antoniu.miclaus@...log.com>
> > Signed-off-by: Antoniu Miclaus <antoniu.miclaus@...log.com>
> > Signed-off-by: Ramona Gradinariu <ramona.gradinariu@...log.com>
> > Signed-off-by: Robert Budai <robert.budai@...log.com>
> > ---
> > 
> > 4:
> > - applied styling changes to the bindings file
> > - restricted sync-mode to intervals 1-2 
> > 
> >  .../bindings/iio/imu/adi,adis16550.yaml       | 96 +++++++++++++++++++
> >  MAINTAINERS                                   |  9 ++
> >  2 files changed, 105 insertions(+)
> >  create mode 100644
> > Documentation/devicetree/bindings/iio/imu/adi,adis16550.yaml
> > 
> > diff --git a/Documentation/devicetree/bindings/iio/imu/adi,adis16550.yaml
> > b/Documentation/devicetree/bindings/iio/imu/adi,adis16550.yaml
> > new file mode 100644
> > index 000000000000..e7ccf3883e55
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/iio/imu/adi,adis16550.yaml
> > @@ -0,0 +1,96 @@
> > +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/iio/imu/adi,adis16550.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: Analog Devices ADIS16550 and similar IMUs
> > +
> > +maintainers:
> > +  - Nuno Sa <nuno.sa@...log.com>
> > +  - Ramona Gradinariu <ramona.gradinariu@...log.com>
> > +  - Antoniu Miclaus <antoniu.miclaus@...log.com>
> > +
> > +properties:
> > +  compatible:
> > +    enum:
> > +      - adi,adis16550
> > +      - adi,adis16550w
> > +
> > +  reg:
> > +    maxItems: 1
> > +
> > +  spi-cpha: true
> > +
> > +  spi-cpol: true
> > +
> > +  spi-max-frequency:
> > +    maximum: 15000000
> > +
> > +  vdd-supply: true
> > +
> > +  interrupts:
> > +    maxItems: 1
> > +
> > +  reset-gpios:
> > +    description:
> > +      RESET active low pin.
> > +    maxItems: 1
> > +
> > +  clocks:
> > +    maxItems: 1
> > +    description: If not provided, then the internal clock is used.
> > +
> > +  adi,sync-mode:
> > +    description:
> > +      Configures the device SYNC pin. The following modes are supported
> > +      0 - output_sync
> > +      1 - direct_sync
> > +      2 - scaled_sync
> 
> A little more on these would be good.  They are 'weird' options
> that are not commonly seen so help the reader out.
> 
> For scaled_sync don't we need information on the scale for it to be useful?
> If we had that then a value of 1 would mean direct sync and wouldn't need
> another control. 
> 
> I'm not fully understanding the usecases for this.
> 
> If we have a say a pulse per second input, the control of the scale should
> be userspace anyway.  So maybe this maps to the input clock that we can elect
> to
> use and control the effective frequency of by using scaled sync?

I guess you likely already saw it in the driver. The scale value is
automatically set by the driver depending on the desired ODR (sampling
frequency).

> 
> I'm not sure what pulse sync is. Grepping the datasheet didn't give me
> anything that seemed related.   The sync pin is input only so I'm also
> not sure on output sync.

I think this is a copy paste from the adis16475 bindings. For this device, it
seems we only have:
 * internal clock;
 * external:
   * direct mode
   * scaled mode

But yeah, as you pointed out I think we do not need the binding. The presence of
an optional input clock plus the frequency should be all we need in order to set
the desired configuration. It should also be possible to add the allowed ranges
to the external input clock in the bindings...


- Nuno Sá



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ