2024-02-22 08:28:36

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH] dt-bindings: usb: analogix,anx7411: drop redundant connector properties

The binding references usb-connector.yaml schema, which lists all
allowed properties and ends with unevaluatedProperties:false, so we can
simplify analogix,anx7411 binding by dropping everything covered by
usb-connector.yaml.

Suggested-by: Pavel Machek <[email protected]>
Signed-off-by: Krzysztof Kozlowski <[email protected]>
---
.../devicetree/bindings/usb/analogix,anx7411.yaml | 13 -------------
1 file changed, 13 deletions(-)

diff --git a/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml b/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
index e4d893369d57..3f5857aee3b0 100644
--- a/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
+++ b/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
@@ -23,24 +23,11 @@ properties:
connector:
type: object
$ref: ../connector/usb-connector.yaml
- unevaluatedProperties: false
-
- description:
- Properties for usb c connector.

properties:
compatible:
const: usb-c-connector

- power-role: true
-
- data-role: true
-
- try-power-role: true
-
- required:
- - compatible
-
required:
- compatible
- reg
--
2.34.1



2024-02-22 16:09:23

by Conor Dooley

[permalink] [raw]
Subject: Re: [PATCH] dt-bindings: usb: analogix,anx7411: drop redundant connector properties

On Thu, Feb 22, 2024 at 09:28:19AM +0100, Krzysztof Kozlowski wrote:
> The binding references usb-connector.yaml schema, which lists all
> allowed properties and ends with unevaluatedProperties:false, so we can
> simplify analogix,anx7411 binding by dropping everything covered by
> usb-connector.yaml.
>
> Suggested-by: Pavel Machek <[email protected]>
> Signed-off-by: Krzysztof Kozlowski <[email protected]>
> ---
> .../devicetree/bindings/usb/analogix,anx7411.yaml | 13 -------------
> 1 file changed, 13 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml b/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
> index e4d893369d57..3f5857aee3b0 100644
> --- a/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
> +++ b/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
> @@ -23,24 +23,11 @@ properties:
> connector:
> type: object
> $ref: ../connector/usb-connector.yaml
> - unevaluatedProperties: false

The connector schema sets `additionalProperties: true`. Is removing this
correct?


> -
> - description:
> - Properties for usb c connector.
>
> properties:
> compatible:
> const: usb-c-connector
>
> - power-role: true
> -
> - data-role: true
> -
> - try-power-role: true
> -
> - required:
> - - compatible
> -
> required:
> - compatible
> - reg
> --
> 2.34.1
>


Attachments:
(No filename) (1.45 kB)
signature.asc (235.00 B)
Download all attachments

2024-02-22 16:56:32

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH] dt-bindings: usb: analogix,anx7411: drop redundant connector properties

On 22/02/2024 17:08, Conor Dooley wrote:
> On Thu, Feb 22, 2024 at 09:28:19AM +0100, Krzysztof Kozlowski wrote:
>> The binding references usb-connector.yaml schema, which lists all
>> allowed properties and ends with unevaluatedProperties:false, so we can
>> simplify analogix,anx7411 binding by dropping everything covered by
>> usb-connector.yaml.
>>
>> Suggested-by: Pavel Machek <[email protected]>
>> Signed-off-by: Krzysztof Kozlowski <[email protected]>
>> ---
>> .../devicetree/bindings/usb/analogix,anx7411.yaml | 13 -------------
>> 1 file changed, 13 deletions(-)
>>
>> diff --git a/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml b/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
>> index e4d893369d57..3f5857aee3b0 100644
>> --- a/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
>> +++ b/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
>> @@ -23,24 +23,11 @@ properties:
>> connector:
>> type: object
>> $ref: ../connector/usb-connector.yaml
>> - unevaluatedProperties: false
>
> The connector schema sets `additionalProperties: true`. Is removing this
> correct?
>

I think you look at some old version:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/devicetree/bindings/connector/usb-connector.yaml?h=v6.8-rc5#n327

Best regards,
Krzysztof


2024-02-22 17:31:16

by Conor Dooley

[permalink] [raw]
Subject: Re: [PATCH] dt-bindings: usb: analogix,anx7411: drop redundant connector properties

On Thu, Feb 22, 2024 at 05:56:12PM +0100, Krzysztof Kozlowski wrote:
> On 22/02/2024 17:08, Conor Dooley wrote:
> > On Thu, Feb 22, 2024 at 09:28:19AM +0100, Krzysztof Kozlowski wrote:
> >> The binding references usb-connector.yaml schema, which lists all
> >> allowed properties and ends with unevaluatedProperties:false, so we can
> >> simplify analogix,anx7411 binding by dropping everything covered by
> >> usb-connector.yaml.
> >>
> >> Suggested-by: Pavel Machek <[email protected]>
> >> Signed-off-by: Krzysztof Kozlowski <[email protected]>
> >> ---
> >> .../devicetree/bindings/usb/analogix,anx7411.yaml | 13 -------------
> >> 1 file changed, 13 deletions(-)
> >>
> >> diff --git a/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml b/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
> >> index e4d893369d57..3f5857aee3b0 100644
> >> --- a/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
> >> +++ b/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
> >> @@ -23,24 +23,11 @@ properties:
> >> connector:
> >> type: object
> >> $ref: ../connector/usb-connector.yaml
> >> - unevaluatedProperties: false
> >
> > The connector schema sets `additionalProperties: true`. Is removing this
> > correct?
> >
>
> I think you look at some old version:
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/devicetree/bindings/connector/usb-connector.yaml?h=v6.8-rc5#n327

Huh, you are correct. I had a stable kernel checked out somehow in the
git worktree I apply dt patches to while reviewing them rather than
linux-next. Sorry about that..
Acked-by: Conor Dooley <[email protected]>

Cheers,
Conor.


Attachments:
(No filename) (1.71 kB)
signature.asc (235.00 B)
Download all attachments

2024-02-22 21:39:17

by Pavel Machek

[permalink] [raw]
Subject: Re: [PATCH] dt-bindings: usb: analogix,anx7411: drop redundant connector properties

Hi!

> The binding references usb-connector.yaml schema, which lists all
> allowed properties and ends with unevaluatedProperties:false, so we can
> simplify analogix,anx7411 binding by dropping everything covered by
> usb-connector.yaml.
>

Reviewed-by: Pavel Machek <[email protected]>

Thank you.

> +++ b/Documentation/devicetree/bindings/usb/analogix,anx7411.yaml
> @@ -23,24 +23,11 @@ properties:
> connector:
> type: object
> $ref: ../connector/usb-connector.yaml

You wanted me to use absolute path here -- $ref:
/schemas/connector/usb-connector.yaml -- so it may be worth fixing
here as well.

Best regards,
Pavel
--
People of Russia, stop Putin before his war on Ukraine escalates.


Attachments:
(No filename) (736.00 B)
signature.asc (201.00 B)
Download all attachments