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]
Date:   Sun, 9 Oct 2022 13:27:11 +0100
From:   Jonathan Cameron <jic23@...nel.org>
To:     Matti Vaittinen <mazziesaccount@...il.com>
Cc:     Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>,
        Matti Vaittinen <matti.vaittinen@...rohmeurope.com>,
        Lars-Peter Clausen <lars@...afoo.de>,
        Rob Herring <robh+dt@...nel.org>,
        Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
        Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
        Jagath Jog J <jagathjog1996@...il.com>,
        Nikita Yushchenko <nikita.yoush@...entembedded.com>,
        Cosmin Tanislav <demonsingur@...il.com>,
        linux-iio@...r.kernel.org, devicetree@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH v2 3/5] dt-bindings: iio: Add KX022A accelerometer

On Thu, 6 Oct 2022 18:32:22 +0300
Matti Vaittinen <mazziesaccount@...il.com> wrote:

> Hi dee Ho Krzysztof,
> 
> On 10/6/22 18:23, Krzysztof Kozlowski wrote:
> > On 06/10/2022 16:37, Matti Vaittinen wrote:  
> >> KX022A is a 3-axis Accelerometer from ROHM/Kionix. The sensor features
> >> include variable ODRs, I2C and SPI control, FIFO/LIFO with watermark IRQ,
> >> tap/motion detection, wake-up & back-to-sleep events, four acceleration
> >> ranges (2, 4, 8 and 16g) and probably some other cool features.
> >>  
> > 
> > Thank you for your patch. There is something to discuss/improve.
> >   
> >> +
> >> +properties:
> >> +  compatible:
> >> +    const: kionix,kx022a
> >> +
> >> +  reg:
> >> +    maxItems: 1
> >> +
> >> +  interrupts:
> >> +    minItems: 1
> >> +    maxItems: 2
> >> +
> >> +  interrupt-names:
> >> +    minItems: 1
> >> +    maxItems: 2
> >> +    items:
> >> +      enum:
> >> +        - INT1
> >> +        - INT2  
> > 
> > This allows any order, which I assume was your intention.  
> 
> Yes. I don't see real need to restrict ordering - besides, with my 
> yaml/schema skills it'd took eternity to find corrct example(s) ;)
> 
> My intention is that the user can give either one of these - or both. 
> Order needs naturally to match the order of IRQs - but this we can't know.
> 
> > However maybe
> > at least fix it a bit like:
> > minItems: 1
> > items:
> >    - enum: [ int1, int2]
> >    - const: int2  
> 
> If you say so XD
> I can fix this for v3 :)
If my limited understanding is correct, one advantage of this restriction
is that we can't have

"INT1", "INT1"
though that may be prevented elsewhere...

There is no loss of useful flexibility in how Krzysztof suggested doing it
so looks like a good suggestion to me.

Jonathan

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ