[PATCH 1/6] dt-bindings: mips: realtek: Add rtl930x-soc compatible

Chris Packham posted 6 patches 1 year, 5 months ago
There is a newer version of this series
[PATCH 1/6] dt-bindings: mips: realtek: Add rtl930x-soc compatible
Posted by Chris Packham 1 year, 5 months ago
Add the rtl930x-soc and RTL9302C board to the list of Realtek compatible
strings.

Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
---
 Documentation/devicetree/bindings/mips/realtek-rtl.yaml | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/devicetree/bindings/mips/realtek-rtl.yaml b/Documentation/devicetree/bindings/mips/realtek-rtl.yaml
index f8ac309d2994..f59249a2cefe 100644
--- a/Documentation/devicetree/bindings/mips/realtek-rtl.yaml
+++ b/Documentation/devicetree/bindings/mips/realtek-rtl.yaml
@@ -19,6 +19,8 @@ properties:
       - items:
           - enum:
               - cisco,sg220-26
+              - realtek,RTL9302C
           - const: realtek,rtl8382-soc
+          - const: realtek,rtl930x-soc
 
 additionalProperties: true
-- 
2.45.2
Re: [PATCH 1/6] dt-bindings: mips: realtek: Add rtl930x-soc compatible
Posted by Krzysztof Kozlowski 1 year, 5 months ago
On 21/06/2024 06:27, Chris Packham wrote:
> Add the rtl930x-soc and RTL9302C board to the list of Realtek compatible
> strings.

No, you did not do this. You added fallback, without any rationale.

> 
> Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
> ---
>  Documentation/devicetree/bindings/mips/realtek-rtl.yaml | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/mips/realtek-rtl.yaml b/Documentation/devicetree/bindings/mips/realtek-rtl.yaml
> index f8ac309d2994..f59249a2cefe 100644
> --- a/Documentation/devicetree/bindings/mips/realtek-rtl.yaml
> +++ b/Documentation/devicetree/bindings/mips/realtek-rtl.yaml
> @@ -19,6 +19,8 @@ properties:
>        - items:
>            - enum:
>                - cisco,sg220-26
> +              - realtek,RTL9302C
>            - const: realtek,rtl8382-soc
> +          - const: realtek,rtl930x-soc

Does not look right. First: Not tested. Second: does not really make
sense and commit msg does not explain it to me. Also, no wildcards.

Best regards,
Krzysztof
Re: [PATCH 1/6] dt-bindings: mips: realtek: Add rtl930x-soc compatible
Posted by Conor Dooley 1 year, 5 months ago
On Fri, Jun 21, 2024 at 04:27:32PM +1200, Chris Packham wrote:
> Add the rtl930x-soc and RTL9302C board to the list of Realtek compatible
> strings.
> 
> Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
> ---
>  Documentation/devicetree/bindings/mips/realtek-rtl.yaml | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/mips/realtek-rtl.yaml b/Documentation/devicetree/bindings/mips/realtek-rtl.yaml
> index f8ac309d2994..f59249a2cefe 100644
> --- a/Documentation/devicetree/bindings/mips/realtek-rtl.yaml
> +++ b/Documentation/devicetree/bindings/mips/realtek-rtl.yaml
> @@ -19,6 +19,8 @@ properties:
>        - items:
>            - enum:
>                - cisco,sg220-26
> +              - realtek,RTL9302C

lower case please.

>            - const: realtek,rtl8382-soc
> +          - const: realtek,rtl930x-soc

Please avoid wildcards in compatibles. Can you add the actual compatible
instead please.

Also, I think this patch is wrong. It will disallow
compatible = "cisco,sg220-26", "realtek,rtl8382-soc"
and instead require
compatible = "cisco,sg220-26", "realtek,rtl8382-soc", "realtek,rtl930x-soc"
  or
compatible = "realtek,RTL9302C, "realtek,rtl8382-soc", "realtek,rtl930x-soc"

Cheers,
Conor.

>  
>  additionalProperties: true
> -- 
> 2.45.2
>