diff mbox series

[net-next] dt-bindings: net: ti: k3-am654-cpsw-nuss: Document Serdes PHY

Message ID 20230306094750.159657-1-s-vadapalli@ti.com (mailing list archive)
State Superseded
Delegated to: Netdev Maintainers
Headers show
Series [net-next] dt-bindings: net: ti: k3-am654-cpsw-nuss: Document Serdes PHY | expand

Checks

Context Check Description
netdev/series_format success Single patches do not need cover letters
netdev/tree_selection success Clearly marked for net-next
netdev/fixes_present success Fixes tag not required for -next series
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 0 this patch: 0
netdev/cc_maintainers warning 1 maintainers not CCed: grygorii.strashko@ti.com
netdev/build_clang success Errors and warnings before: 0 this patch: 0
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/deprecated_api success None detected
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 0 this patch: 0
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 27 lines checked
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Siddharth Vadapalli March 6, 2023, 9:47 a.m. UTC
Update bindings to include Serdes PHY as an optional PHY, in addition to
the existing CPSW MAC's PHY. The CPSW MAC's PHY is required while the
Serdes PHY is optional. The Serdes PHY handle has to be provided only
when the Serdes is being configured in a Single-Link protocol. Using the
name "serdes-phy" to represent the Serdes PHY handle, the am65-cpsw-nuss
driver can obtain the Serdes PHY and request the Serdes to be
configured.

Signed-off-by: Siddharth Vadapalli <s-vadapalli@ti.com>
---

Hello,

This patch corresponds to the Serdes PHY bindings that were missed out in
the series at:
Link: https://lore.kernel.org/r/20230104103432.1126403-1-s-vadapalli@ti.com/
This was pointed out at:
https://lore.kernel.org/r/CAMuHMdW5atq-FuLEL3htuE3t2uO86anLL3zeY7n1RqqMP_rH1g@mail.gmail.com/

 .../bindings/net/ti,k3-am654-cpsw-nuss.yaml   | 21 +++++++++++++++++--
 1 file changed, 19 insertions(+), 2 deletions(-)

Comments

Rob Herring (Arm) March 7, 2023, 2:01 p.m. UTC | #1
On Mon, Mar 06, 2023 at 03:17:50PM +0530, Siddharth Vadapalli wrote:
> Update bindings to include Serdes PHY as an optional PHY, in addition to
> the existing CPSW MAC's PHY. The CPSW MAC's PHY is required while the
> Serdes PHY is optional. The Serdes PHY handle has to be provided only
> when the Serdes is being configured in a Single-Link protocol. Using the
> name "serdes-phy" to represent the Serdes PHY handle, the am65-cpsw-nuss
> driver can obtain the Serdes PHY and request the Serdes to be
> configured.
> 
> Signed-off-by: Siddharth Vadapalli <s-vadapalli@ti.com>
> ---
> 
> Hello,
> 
> This patch corresponds to the Serdes PHY bindings that were missed out in
> the series at:
> Link: https://lore.kernel.org/r/20230104103432.1126403-1-s-vadapalli@ti.com/
> This was pointed out at:
> https://lore.kernel.org/r/CAMuHMdW5atq-FuLEL3htuE3t2uO86anLL3zeY7n1RqqMP_rH1g@mail.gmail.com/
> 
>  .../bindings/net/ti,k3-am654-cpsw-nuss.yaml   | 21 +++++++++++++++++--
>  1 file changed, 19 insertions(+), 2 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml b/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml
> index 900063411a20..fab7df437dcc 100644
> --- a/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml
> +++ b/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml
> @@ -126,8 +126,25 @@ properties:
>              description: CPSW port number
>  
>            phys:
> -            maxItems: 1
> -            description: phandle on phy-gmii-sel PHY
> +            minItems: 1
> +            maxItems: 2
> +            description:
> +              phandle(s) on CPSW MAC's PHY (Required) and the Serdes
> +              PHY (Optional). phandle to the Serdes PHY is required
> +              when the Serdes has to be configured in Single-Link
> +              configuration.

Like this:

minItems: 1
items:
  - description: CPSW MAC's PHY
  - description: Serdes PHY. Serdes PHY is required
      when the Serdes has to be configured in Single-Link

> +
> +          phy-names:
> +            oneOf:
> +              - items:
> +                  - const: mac-phy
> +                  - const: serdes-phy
> +              - items:
> +                  - const: mac-phy

Drop this and use minItems in 1st 'items' entry.

> +            description:
> +              Identifiers for the CPSW MAC's PHY and the Serdes PHY.
> +              CPSW MAC's PHY is required and therefore "mac-phy" is
> +              required, while "serdes-phy" is optional.

No need to state in plain text what the schema already says.

Rob
Siddharth Vadapalli March 8, 2023, 4:19 a.m. UTC | #2
Hello Rob,

On 07/03/23 19:31, Rob Herring wrote:
> On Mon, Mar 06, 2023 at 03:17:50PM +0530, Siddharth Vadapalli wrote:
>> Update bindings to include Serdes PHY as an optional PHY, in addition to
>> the existing CPSW MAC's PHY. The CPSW MAC's PHY is required while the
>> Serdes PHY is optional. The Serdes PHY handle has to be provided only
>> when the Serdes is being configured in a Single-Link protocol. Using the
>> name "serdes-phy" to represent the Serdes PHY handle, the am65-cpsw-nuss
>> driver can obtain the Serdes PHY and request the Serdes to be
>> configured.
>>
>> Signed-off-by: Siddharth Vadapalli <s-vadapalli@ti.com>
>> ---
>>
>> Hello,
>>
>> This patch corresponds to the Serdes PHY bindings that were missed out in
>> the series at:
>> Link: https://lore.kernel.org/r/20230104103432.1126403-1-s-vadapalli@ti.com/
>> This was pointed out at:
>> https://lore.kernel.org/r/CAMuHMdW5atq-FuLEL3htuE3t2uO86anLL3zeY7n1RqqMP_rH1g@mail.gmail.com/
>>
>>  .../bindings/net/ti,k3-am654-cpsw-nuss.yaml   | 21 +++++++++++++++++--
>>  1 file changed, 19 insertions(+), 2 deletions(-)
>>
>> diff --git a/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml b/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml
>> index 900063411a20..fab7df437dcc 100644
>> --- a/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml
>> +++ b/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml
>> @@ -126,8 +126,25 @@ properties:
>>              description: CPSW port number
>>  
>>            phys:
>> -            maxItems: 1
>> -            description: phandle on phy-gmii-sel PHY
>> +            minItems: 1
>> +            maxItems: 2
>> +            description:
>> +              phandle(s) on CPSW MAC's PHY (Required) and the Serdes
>> +              PHY (Optional). phandle to the Serdes PHY is required
>> +              when the Serdes has to be configured in Single-Link
>> +              configuration.
> 
> Like this:
> 
> minItems: 1
> items:
>   - description: CPSW MAC's PHY
>   - description: Serdes PHY. Serdes PHY is required
>       when the Serdes has to be configured in Single-Link
> 
>> +
>> +          phy-names:
>> +            oneOf:
>> +              - items:
>> +                  - const: mac-phy
>> +                  - const: serdes-phy
>> +              - items:
>> +                  - const: mac-phy
> 
> Drop this and use minItems in 1st 'items' entry.
> 
>> +            description:
>> +              Identifiers for the CPSW MAC's PHY and the Serdes PHY.
>> +              CPSW MAC's PHY is required and therefore "mac-phy" is
>> +              required, while "serdes-phy" is optional.
> 
> No need to state in plain text what the schema already says.

Thank you for reviewing the patch. I will implement your feedback and post the
v2 patch.

Regards,
Siddharth.
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml b/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml
index 900063411a20..fab7df437dcc 100644
--- a/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml
+++ b/Documentation/devicetree/bindings/net/ti,k3-am654-cpsw-nuss.yaml
@@ -126,8 +126,25 @@  properties:
             description: CPSW port number
 
           phys:
-            maxItems: 1
-            description: phandle on phy-gmii-sel PHY
+            minItems: 1
+            maxItems: 2
+            description:
+              phandle(s) on CPSW MAC's PHY (Required) and the Serdes
+              PHY (Optional). phandle to the Serdes PHY is required
+              when the Serdes has to be configured in Single-Link
+              configuration.
+
+          phy-names:
+            oneOf:
+              - items:
+                  - const: mac-phy
+                  - const: serdes-phy
+              - items:
+                  - const: mac-phy
+            description:
+              Identifiers for the CPSW MAC's PHY and the Serdes PHY.
+              CPSW MAC's PHY is required and therefore "mac-phy" is
+              required, while "serdes-phy" is optional.
 
           label:
             description: label associated with this port