devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
To: Michal Simek <michal.simek@amd.com>,
	linux-kernel@vger.kernel.org, monstr@monstr.eu,
	michal.simek@xilinx.com, git@xilinx.com
Cc: Conor Dooley <conor+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Moritz Fischer <mdf@kernel.org>, Rob Herring <robh+dt@kernel.org>,
	Tom Rix <trix@redhat.com>, Wu Hao <hao.wu@intel.com>,
	Xu Yilun <yilun.xu@intel.com>,
	"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS"
	<devicetree@vger.kernel.org>,
	"open list:FPGA MANAGER FRAMEWORK" <linux-fpga@vger.kernel.org>
Subject: Re: [PATCH v2] dt-bindings: fpga: Convert fpga-region binding to yaml
Date: Wed, 17 Jan 2024 09:14:28 +0100	[thread overview]
Message-ID: <b2dd8bcd-1e23-4b68-b7b7-c01b034fc1fe@linaro.org> (raw)
In-Reply-To: <66fbb19e-72cc-4fb9-9069-abc351b1525a@amd.com>

On 17/01/2024 09:07, Michal Simek wrote:
>>> +patternProperties:
>>> +  "@(0|[1-9a-f][0-9a-f]*)$":
>>> +    type: object
>>
>> You put (0|[...) to disallow @0001? I personally would not care, dtc
>> handles this, and the pattern is confusing. Just @[0-9a-z]+$
> 
> This is actually taken from dtschema/schemas/simple-bus.yaml to allow all nodes 
> with regs.
> 
>>
>>> +
>>> +  "^[^@]+$": true
>>
>> I dislike it. How is this binding supposed to be used? If in standalone
>> way, then you allow any property so what's the point of this schema? If
>> fpga-bridge.yaml is referenced by other device-specific binding, then
>> all properties will be evaluated here, so the same: you allow any property.
>>
>> Depending on the usage, this might be just like other generic, common
>> schemas, so end with "additionalPropeties: true".
> 
> ok. I am fine with it.

But please verify my idea. If it is used standalone, then you should
drop both above patterns + additionalProps:false. If it is used as
generic schema referenced by something, then you could keep one pattern
for object, but actually it is redundant, so I propose to drop them and
additionalProps:true.

Best regards,
Krzysztof


  reply	other threads:[~2024-01-17  8:14 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-16 14:04 [PATCH v2] dt-bindings: fpga: Convert fpga-region binding to yaml Michal Simek
2024-01-17  7:52 ` Krzysztof Kozlowski
2024-01-17  8:07   ` Michal Simek
2024-01-17  8:14     ` Krzysztof Kozlowski [this message]
2024-01-17  8:27       ` Michal Simek
2024-01-17  8:47   ` Michal Simek

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=b2dd8bcd-1e23-4b68-b7b7-c01b034fc1fe@linaro.org \
    --to=krzysztof.kozlowski@linaro.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=git@xilinx.com \
    --cc=hao.wu@intel.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-fpga@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mdf@kernel.org \
    --cc=michal.simek@amd.com \
    --cc=michal.simek@xilinx.com \
    --cc=monstr@monstr.eu \
    --cc=robh+dt@kernel.org \
    --cc=trix@redhat.com \
    --cc=yilun.xu@intel.com \
    /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).