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:   Tue, 2 Apr 2019 20:50:09 -0500
From:   Rob Herring <robh+dt@...nel.org>
To:     Brian Masney <masneyb@...tation.org>
Cc:     Dan Murphy <dmurphy@...com>, Lee Jones <lee.jones@...aro.org>,
        Daniel Thompson <daniel.thompson@...aro.org>,
        Jingoo Han <jingoohan1@...il.com>,
        Jacek Anaszewski <jacek.anaszewski@...il.com>,
        Pavel Machek <pavel@....cz>,
        Mark Rutland <mark.rutland@....com>,
        Bartlomiej Zolnierkiewicz <b.zolnierkie@...sung.com>,
        dri-devel <dri-devel@...ts.freedesktop.org>,
        Linux LED Subsystem <linux-leds@...r.kernel.org>,
        devicetree@...r.kernel.org,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Linux Fbdev development list <linux-fbdev@...r.kernel.org>,
        Jonathan Marek <jonathan@...ek.ca>
Subject: Re: [PATCH v2 2/3] dt-bindings: backlight: add lm3630a bindings

On Tue, Apr 2, 2019 at 8:24 AM Brian Masney <masneyb@...tation.org> wrote:
>
> On Tue, Apr 02, 2019 at 07:56:55AM -0500, Dan Murphy wrote:
> > This would connect control bank B to control bank A.  Or just use a flag to denote to connect them
> > and not use led-sources.  But led-sources is the property of choice.
> >
> > led@0 {
> >       reg = <0>;
> >       led-sources = < 0 1 >;
> >       label = "main-lcd";
> >       default-brightness = <200>;
> >       max-brightness = <255>;
> > };
>
> OK, I see. I wondered how we could do that in device tree.
>
> > > +    properties:
> > > +      label:
> > > +        description: |
> > > +          The label for this LED. If omitted, the label is taken from the node
> > > +          name (excluding the unit address). It has to uniquely identify a
> > > +          device, i.e. no other LED class device can be assigned the same label.
> > > +
> > > +      led-sources:
> > > +        description: |
> > > +          List of device current outputs the LED is connected to.
> > > +        allOf:
> > > +          - $ref: /schemas/types.yaml#/definitions/uint32-array
> > > +          - minItems: 1
> > > +            maxItems: 2
> > > +            items:
> > > +              minimum: 0
> > > +              maximum: 1
> > > +
> >
> > label and led-sources are already defined in the common.txt no need to redefine them here.
>
> If I'm going to use the new-style bindings, then I'll need to convert
> common.txt over to use the new format as well so that the automated
> schema validations will work. I'm willing to do that work if there is
> interest from the LED / backlight maintainers. The main issue is that
> there are 62 references to the file common.txt in the directory
> Documentation/devicetree/bindings/leds/. Would the maintainers prefer:

That would be awesome.

> - Once common.txt is converted to common.yaml, make common.txt only
>   have a line stating that the common bindings were moved into
>   common.yaml. We can remove this file once all of the other bindings
>   are converted to the new-style format.
>
> - Update all references to common.txt to common.yaml. (1 patch or 62
>   patches?)

I'd probably go with the former if I had to pick. The real
complication here is there's some other changes in flight.

>
> - Or, just go with the older-style binding format for now.

I'm okay if you write it with the assumption that the common
properties have a schema even if they don't yet. All that means is you
don't need to define the type, but only the additional constraints.
There doesn't have to be a reference back to the common property
(those references tend to get broken as we can see here). With
everything as structured data, we could even generate references or
have some tool that can lookup the common definitions.

Rob

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ