devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] dt-bindings: clock: si5351: Make compatible string required property
@ 2024-10-02  7:51 Michal Simek
  2024-10-02  8:19 ` Krzysztof Kozlowski
  0 siblings, 1 reply; 9+ messages in thread
From: Michal Simek @ 2024-10-02  7:51 UTC (permalink / raw)
  To: linux-kernel, monstr, michal.simek, git
  Cc: Alvin Šipraga, Conor Dooley, Krzysztof Kozlowski,
	Michael Turquette, Rob Herring, Stephen Boyd,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	open list:COMMON CLK FRAMEWORK

Compatible property is likely also required property.

Signed-off-by: Michal Simek <michal.simek@amd.com>
---

 Documentation/devicetree/bindings/clock/silabs,si5351.yaml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/clock/silabs,si5351.yaml b/Documentation/devicetree/bindings/clock/silabs,si5351.yaml
index d3e0ec29993b..3442400715d0 100644
--- a/Documentation/devicetree/bindings/clock/silabs,si5351.yaml
+++ b/Documentation/devicetree/bindings/clock/silabs,si5351.yaml
@@ -187,6 +187,7 @@ allOf:
           maxItems: 1
 
 required:
+  - compatible
   - reg
   - "#address-cells"
   - "#size-cells"
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [PATCH] dt-bindings: clock: si5351: Make compatible string required property
  2024-10-02  7:51 [PATCH] dt-bindings: clock: si5351: Make compatible string required property Michal Simek
@ 2024-10-02  8:19 ` Krzysztof Kozlowski
  2024-10-02  8:24   ` Michal Simek
  0 siblings, 1 reply; 9+ messages in thread
From: Krzysztof Kozlowski @ 2024-10-02  8:19 UTC (permalink / raw)
  To: Michal Simek, linux-kernel, monstr, michal.simek, git
  Cc: Alvin Šipraga, Conor Dooley, Krzysztof Kozlowski,
	Michael Turquette, Rob Herring, Stephen Boyd,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	open list:COMMON CLK FRAMEWORK

On 02/10/2024 09:51, Michal Simek wrote:
> Compatible property is likely also required property.
> 
> Signed-off-by: Michal Simek <michal.simek@amd.com>
> ---

That's a convention but not necessary, a no-op.

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] dt-bindings: clock: si5351: Make compatible string required property
  2024-10-02  8:19 ` Krzysztof Kozlowski
@ 2024-10-02  8:24   ` Michal Simek
  2024-10-02 10:31     ` Michal Simek
  2024-10-02 12:02     ` Krzysztof Kozlowski
  0 siblings, 2 replies; 9+ messages in thread
From: Michal Simek @ 2024-10-02  8:24 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-kernel, monstr, michal.simek, git
  Cc: Alvin Šipraga, Conor Dooley, Krzysztof Kozlowski,
	Michael Turquette, Rob Herring, Stephen Boyd,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	open list:COMMON CLK FRAMEWORK



On 10/2/24 10:19, Krzysztof Kozlowski wrote:
> On 02/10/2024 09:51, Michal Simek wrote:
>> Compatible property is likely also required property.
>>
>> Signed-off-by: Michal Simek <michal.simek@amd.com>
>> ---
> 
> That's a convention but not necessary, a no-op.

But how do you identify device then?
Or are you saying that device description is valid even if there is no 
compatible string?

M


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] dt-bindings: clock: si5351: Make compatible string required property
  2024-10-02  8:24   ` Michal Simek
@ 2024-10-02 10:31     ` Michal Simek
  2024-10-02 12:17       ` Krzysztof Kozlowski
  2024-10-02 12:02     ` Krzysztof Kozlowski
  1 sibling, 1 reply; 9+ messages in thread
From: Michal Simek @ 2024-10-02 10:31 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-kernel, monstr, michal.simek, git
  Cc: Alvin Šipraga, Conor Dooley, Krzysztof Kozlowski,
	Michael Turquette, Rob Herring, Stephen Boyd,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	open list:COMMON CLK FRAMEWORK



On 10/2/24 10:24, Michal Simek wrote:
> 
> 
> On 10/2/24 10:19, Krzysztof Kozlowski wrote:
>> On 02/10/2024 09:51, Michal Simek wrote:
>>> Compatible property is likely also required property.
>>>
>>> Signed-off-by: Michal Simek <michal.simek@amd.com>
>>> ---
>>
>> That's a convention but not necessary, a no-op.
> 
> But how do you identify device then?
> Or are you saying that device description is valid even if there is no 
> compatible string?

One more thing
commit 524dfbc4e9fc ("dt-bindings: clock: si5351: convert to yaml") is showing
that compatible property was required in txt file.

-Required properties:
-- compatible: shall be one of the following:
-       "silabs,si5351a" - Si5351a, QFN20 package
-       "silabs,si5351a-msop" - Si5351a, MSOP10 package

I can update commit message to describe it too.

M

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] dt-bindings: clock: si5351: Make compatible string required property
  2024-10-02  8:24   ` Michal Simek
  2024-10-02 10:31     ` Michal Simek
@ 2024-10-02 12:02     ` Krzysztof Kozlowski
  1 sibling, 0 replies; 9+ messages in thread
From: Krzysztof Kozlowski @ 2024-10-02 12:02 UTC (permalink / raw)
  To: Michal Simek, linux-kernel, monstr, michal.simek, git
  Cc: Alvin Šipraga, Conor Dooley, Krzysztof Kozlowski,
	Michael Turquette, Rob Herring, Stephen Boyd,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	open list:COMMON CLK FRAMEWORK

On 02/10/2024 10:24, Michal Simek wrote:
> 
> 
> On 10/2/24 10:19, Krzysztof Kozlowski wrote:
>> On 02/10/2024 09:51, Michal Simek wrote:
>>> Compatible property is likely also required property.
>>>
>>> Signed-off-by: Michal Simek <michal.simek@amd.com>
>>> ---
>>
>> That's a convention but not necessary, a no-op.
> 
> But how do you identify device then?
> Or are you saying that device description is valid even if there is no 
> compatible string?

No. I meant your change means nothing to the schema. It's a noop.
Compatible is implied.

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] dt-bindings: clock: si5351: Make compatible string required property
  2024-10-02 10:31     ` Michal Simek
@ 2024-10-02 12:17       ` Krzysztof Kozlowski
  2024-10-02 21:41         ` Rob Herring
  0 siblings, 1 reply; 9+ messages in thread
From: Krzysztof Kozlowski @ 2024-10-02 12:17 UTC (permalink / raw)
  To: Michal Simek, linux-kernel, monstr, michal.simek, git
  Cc: Alvin Šipraga, Conor Dooley, Krzysztof Kozlowski,
	Michael Turquette, Rob Herring, Stephen Boyd,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	open list:COMMON CLK FRAMEWORK

On 02/10/2024 12:31, Michal Simek wrote:
> 
> 
> On 10/2/24 10:24, Michal Simek wrote:
>>
>>
>> On 10/2/24 10:19, Krzysztof Kozlowski wrote:
>>> On 02/10/2024 09:51, Michal Simek wrote:
>>>> Compatible property is likely also required property.
>>>>
>>>> Signed-off-by: Michal Simek <michal.simek@amd.com>
>>>> ---
>>>
>>> That's a convention but not necessary, a no-op.
>>
>> But how do you identify device then?
>> Or are you saying that device description is valid even if there is no 
>> compatible string?
> 
> One more thing
> commit 524dfbc4e9fc ("dt-bindings: clock: si5351: convert to yaml") is showing
> that compatible property was required in txt file.
> 
> -Required properties:
> -- compatible: shall be one of the following:
> -       "silabs,si5351a" - Si5351a, QFN20 package
> -       "silabs,si5351a-msop" - Si5351a, MSOP10 package
> 
> I can update commit message to describe it too.

Devices do not work without compatible, so this is obvious... and like
said - it is already required, so the change is redundant. Does not
harm, though.

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] dt-bindings: clock: si5351: Make compatible string required property
  2024-10-02 12:17       ` Krzysztof Kozlowski
@ 2024-10-02 21:41         ` Rob Herring
  2024-10-03  5:57           ` Michal Simek
  0 siblings, 1 reply; 9+ messages in thread
From: Rob Herring @ 2024-10-02 21:41 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Michal Simek, linux-kernel, monstr, michal.simek, git,
	Alvin Šipraga, Conor Dooley, Krzysztof Kozlowski,
	Michael Turquette, Stephen Boyd,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	open list:COMMON CLK FRAMEWORK

On Wed, Oct 02, 2024 at 02:17:22PM +0200, Krzysztof Kozlowski wrote:
> On 02/10/2024 12:31, Michal Simek wrote:
> > 
> > 
> > On 10/2/24 10:24, Michal Simek wrote:
> >>
> >>
> >> On 10/2/24 10:19, Krzysztof Kozlowski wrote:
> >>> On 02/10/2024 09:51, Michal Simek wrote:
> >>>> Compatible property is likely also required property.
> >>>>
> >>>> Signed-off-by: Michal Simek <michal.simek@amd.com>
> >>>> ---
> >>>
> >>> That's a convention but not necessary, a no-op.
> >>
> >> But how do you identify device then?
> >> Or are you saying that device description is valid even if there is no 
> >> compatible string?
> > 
> > One more thing
> > commit 524dfbc4e9fc ("dt-bindings: clock: si5351: convert to yaml") is showing
> > that compatible property was required in txt file.
> > 
> > -Required properties:
> > -- compatible: shall be one of the following:
> > -       "silabs,si5351a" - Si5351a, QFN20 package
> > -       "silabs,si5351a-msop" - Si5351a, MSOP10 package
> > 
> > I can update commit message to describe it too.
> 
> Devices do not work without compatible, so this is obvious... and like
> said - it is already required, so the change is redundant. Does not
> harm, though.

To put it another way, by the time the schema is applied, we already 
know that compatible is present because that is *how* the schema gets 
applied in the first place.

Rob

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] dt-bindings: clock: si5351: Make compatible string required property
  2024-10-02 21:41         ` Rob Herring
@ 2024-10-03  5:57           ` Michal Simek
  2024-10-03  7:02             ` Krzysztof Kozlowski
  0 siblings, 1 reply; 9+ messages in thread
From: Michal Simek @ 2024-10-03  5:57 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski
  Cc: linux-kernel, monstr, michal.simek, git, Alvin Šipraga,
	Conor Dooley, Krzysztof Kozlowski, Michael Turquette,
	Stephen Boyd,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	open list:COMMON CLK FRAMEWORK



On 10/2/24 23:41, Rob Herring wrote:
> On Wed, Oct 02, 2024 at 02:17:22PM +0200, Krzysztof Kozlowski wrote:
>> On 02/10/2024 12:31, Michal Simek wrote:
>>>
>>>
>>> On 10/2/24 10:24, Michal Simek wrote:
>>>>
>>>>
>>>> On 10/2/24 10:19, Krzysztof Kozlowski wrote:
>>>>> On 02/10/2024 09:51, Michal Simek wrote:
>>>>>> Compatible property is likely also required property.
>>>>>>
>>>>>> Signed-off-by: Michal Simek <michal.simek@amd.com>
>>>>>> ---
>>>>>
>>>>> That's a convention but not necessary, a no-op.
>>>>
>>>> But how do you identify device then?
>>>> Or are you saying that device description is valid even if there is no
>>>> compatible string?
>>>
>>> One more thing
>>> commit 524dfbc4e9fc ("dt-bindings: clock: si5351: convert to yaml") is showing
>>> that compatible property was required in txt file.
>>>
>>> -Required properties:
>>> -- compatible: shall be one of the following:
>>> -       "silabs,si5351a" - Si5351a, QFN20 package
>>> -       "silabs,si5351a-msop" - Si5351a, MSOP10 package
>>>
>>> I can update commit message to describe it too.
>>
>> Devices do not work without compatible, so this is obvious... and like
>> said - it is already required, so the change is redundant. Does not
>> harm, though.
> 
> To put it another way, by the time the schema is applied, we already
> know that compatible is present because that is *how* the schema gets
> applied in the first place.

I get that argument but then based on this we should remove all records about 
compatible string as required property.

Thanks,
Michal

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] dt-bindings: clock: si5351: Make compatible string required property
  2024-10-03  5:57           ` Michal Simek
@ 2024-10-03  7:02             ` Krzysztof Kozlowski
  0 siblings, 0 replies; 9+ messages in thread
From: Krzysztof Kozlowski @ 2024-10-03  7:02 UTC (permalink / raw)
  To: Michal Simek, Rob Herring
  Cc: linux-kernel, monstr, michal.simek, git, Alvin Šipraga,
	Conor Dooley, Krzysztof Kozlowski, Michael Turquette,
	Stephen Boyd,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	open list:COMMON CLK FRAMEWORK

On 03/10/2024 07:57, Michal Simek wrote:
> 
> 
> On 10/2/24 23:41, Rob Herring wrote:
>> On Wed, Oct 02, 2024 at 02:17:22PM +0200, Krzysztof Kozlowski wrote:
>>> On 02/10/2024 12:31, Michal Simek wrote:
>>>>
>>>>
>>>> On 10/2/24 10:24, Michal Simek wrote:
>>>>>
>>>>>
>>>>> On 10/2/24 10:19, Krzysztof Kozlowski wrote:
>>>>>> On 02/10/2024 09:51, Michal Simek wrote:
>>>>>>> Compatible property is likely also required property.
>>>>>>>
>>>>>>> Signed-off-by: Michal Simek <michal.simek@amd.com>
>>>>>>> ---
>>>>>>
>>>>>> That's a convention but not necessary, a no-op.
>>>>>
>>>>> But how do you identify device then?
>>>>> Or are you saying that device description is valid even if there is no
>>>>> compatible string?
>>>>
>>>> One more thing
>>>> commit 524dfbc4e9fc ("dt-bindings: clock: si5351: convert to yaml") is showing
>>>> that compatible property was required in txt file.
>>>>
>>>> -Required properties:
>>>> -- compatible: shall be one of the following:
>>>> -       "silabs,si5351a" - Si5351a, QFN20 package
>>>> -       "silabs,si5351a-msop" - Si5351a, MSOP10 package
>>>>
>>>> I can update commit message to describe it too.
>>>
>>> Devices do not work without compatible, so this is obvious... and like
>>> said - it is already required, so the change is redundant. Does not
>>> harm, though.
>>
>> To put it another way, by the time the schema is applied, we already
>> know that compatible is present because that is *how* the schema gets
>> applied in the first place.
> 
> I get that argument but then based on this we should remove all records about 
> compatible string as required property.

We could... but we have a style of keeping it. What is the harm in
having it in 99% of bindings and missing in a few?

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2024-10-03  7:02 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-02  7:51 [PATCH] dt-bindings: clock: si5351: Make compatible string required property Michal Simek
2024-10-02  8:19 ` Krzysztof Kozlowski
2024-10-02  8:24   ` Michal Simek
2024-10-02 10:31     ` Michal Simek
2024-10-02 12:17       ` Krzysztof Kozlowski
2024-10-02 21:41         ` Rob Herring
2024-10-03  5:57           ` Michal Simek
2024-10-03  7:02             ` Krzysztof Kozlowski
2024-10-02 12:02     ` Krzysztof Kozlowski

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).