linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: Jeff LaBundy <jeff@labundy.com>
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	Linux Input <linux-input@vger.kernel.org>,
	devicetree@vger.kernel.org
Subject: Re: [PATCH 1/2] dt-bindings: input: Add bindings for Azoteq IQS269A
Date: Fri, 1 May 2020 07:51:04 -0500	[thread overview]
Message-ID: <CAL_Jsq+1GudY__zznL-KuLbsePZzHGFSQk3OHUugqyrkPo3Ltw@mail.gmail.com> (raw)
In-Reply-To: <20200501012313.GA14243@labundy.com>

On Thu, Apr 30, 2020 at 8:23 PM Jeff LaBundy <jeff@labundy.com> wrote:
>
> Hi Rob,
>
> Thank you for your thorough review.
>
> On Thu, Apr 30, 2020 at 10:11:08AM -0500, Rob Herring wrote:
> > On Sun, Apr 19, 2020 at 06:47:47PM -0500, Jeff LaBundy wrote:
> > > This patch adds device tree bindings for the Azoteq IQS269A
> > > capacitive touch controller.
> > >
> > > Signed-off-by: Jeff LaBundy <jeff@labundy.com>
> > > ---
> > >  .../devicetree/bindings/input/iqs269a.yaml         | 591 +++++++++++++++++++++
> > >  1 file changed, 591 insertions(+)
> > >  create mode 100644 Documentation/devicetree/bindings/input/iqs269a.yaml
> >
> > Kind of a lot of properties compared to other devices. Why so many? That
> > said, nothing looks to be obviously something that doesn't belong in DT.
>
> I don't disagree; this device simply has a lot of knobs for accommodating
> multiple sensing modes across different applications. Once I added support
> for the ones I expected to be most commonly used, however, I didn't see a
> reason to exclude the remaining minority and risk having to add something
> later.
>
> >
> > No interdependencies between properties? If there are, use
> > 'dependencies'.
>
> Strictly speaking, no; each property can be specified independently of any
> other property and the device's registers will be updated accordingly.
>
> That being said, a couple of properties do impose restrictions on others
> within specific channels for certain applications. It wasn't clear if/how
> 'dependencies' could describe these conditional relationships, so I opted
> to include a note in the descriptions where applicable.
>
> [...]
>
> > > +
> > > +  azoteq,rate-np-ms:
> > > +    allOf:
> > > +      - $ref: /schemas/types.yaml#/definitions/uint32
> >
> > With a unit suffix, you can drop the type $ref.
>
> Sure thing, thank you for catching these. Once I remove $ref in these cases,
> is an 'allOf' still required above the remaining minimum/maximum/etc.?

No. Actually, you can now drop 'allOf' even with $ref. With
json-schema draft 2019.9, the behavior has changed such that $ref can
be mixed with other schema. So now that most everyone has learned the
old way, we're switching. You can use either form, but without 'allOf'
you'll need dt-schema to be up to date (2020.4).

> > > +      - minimum: 0
> > > +        maximum: 255
> > > +        default: 16
> > > +    description: Specifies the report rate (in ms) during normal-power mode.
> > > +
>
> On a related note, should all items under an 'allOf' be preceded by a hyphen?

No. It's logically equivalent, but the error reporting is worse.

Rob

      reply	other threads:[~2020-05-01 12:51 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-19 23:47 [PATCH 1/2] dt-bindings: input: Add bindings for Azoteq IQS269A Jeff LaBundy
2020-04-19 23:47 ` [PATCH 2/2] input: misc: Add support " Jeff LaBundy
2020-04-20 17:09   ` Dmitry Torokhov
2020-05-17 21:21     ` Jeff LaBundy
2020-04-30 15:11 ` [PATCH 1/2] dt-bindings: input: Add bindings " Rob Herring
2020-05-01  1:23   ` Jeff LaBundy
2020-05-01 12:51     ` Rob Herring [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAL_Jsq+1GudY__zznL-KuLbsePZzHGFSQk3OHUugqyrkPo3Ltw@mail.gmail.com \
    --to=robh@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dmitry.torokhov@gmail.com \
    --cc=jeff@labundy.com \
    --cc=linux-input@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).