diff mbox series

[v2,1/2] dt-bindings: net: adin: add recovered clock output

Message ID 20240124102554.1327853-1-f.pfitzner@pengutronix.de (mailing list archive)
State Changes Requested
Delegated to: Netdev Maintainers
Headers show
Series [v2,1/2] dt-bindings: net: adin: add recovered clock output | expand

Commit Message

Fabian Pfitzner Jan. 24, 2024, 10:25 a.m. UTC
The ADIN1300 offers three distinct output clocks which can be accessed
through the GP_CLK pin. The DT only offers two of the possible options
and thus the 125MHz-recovered output clock is missing.

As there is no other way to configure this pin than through the DT it
should be possible to do so for all available outputs.

Signed-off-by: Fabian Pfitzner <f.pfitzner@pengutronix.de>
---
 Documentation/devicetree/bindings/net/adi,adin.yaml | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)


base-commit: 6613476e225e090cc9aad49be7fa504e290dd33d

Comments

Conor Dooley Jan. 24, 2024, 4:12 p.m. UTC | #1
On Wed, Jan 24, 2024 at 11:25:54AM +0100, Fabian Pfitzner wrote:
> The ADIN1300 offers three distinct output clocks which can be accessed
> through the GP_CLK pin. The DT only offers two of the possible options
> and thus the 125MHz-recovered output clock is missing.
> 
> As there is no other way to configure this pin than through the DT it
> should be possible to do so for all available outputs.
> 
> Signed-off-by: Fabian Pfitzner <f.pfitzner@pengutronix.de>

Acked-by: Conor Dooley <conor.dooley@microchip.com>

Cheers,
Conor.

> ---
>  Documentation/devicetree/bindings/net/adi,adin.yaml | 7 +++++--
>  1 file changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/net/adi,adin.yaml b/Documentation/devicetree/bindings/net/adi,adin.yaml
> index 929cf8c0b0fd..04059393b756 100644
> --- a/Documentation/devicetree/bindings/net/adi,adin.yaml
> +++ b/Documentation/devicetree/bindings/net/adi,adin.yaml
> @@ -38,14 +38,17 @@ properties:
>  
>    adi,phy-output-clock:
>      description: |
> -      Select clock output on GP_CLK pin. Two clocks are available:
> -      A 25MHz reference and a free-running 125MHz.
> +      Select clock output on GP_CLK pin. Three clocks are available:
> +        - 25MHz reference
> +        - free-running 125MHz
> +        - recovered 125MHz
>        The phy can alternatively automatically switch between the reference and
>        the 125MHz clocks based on its internal state.
>      $ref: /schemas/types.yaml#/definitions/string
>      enum:
>        - 25mhz-reference
>        - 125mhz-free-running
> +      - 125mhz-recovered
>        - adaptive-free-running
>  
>    adi,phy-output-reference-clock:
> 
> base-commit: 6613476e225e090cc9aad49be7fa504e290dd33d
> -- 
> 2.39.2
>
Jakub Kicinski Jan. 25, 2024, 1:57 a.m. UTC | #2
On Wed, 24 Jan 2024 11:25:54 +0100 Fabian Pfitzner wrote:
> The ADIN1300 offers three distinct output clocks which can be accessed
> through the GP_CLK pin. The DT only offers two of the possible options
> and thus the 125MHz-recovered output clock is missing.
> 
> As there is no other way to configure this pin than through the DT it
> should be possible to do so for all available outputs.

Hi Fabian!

If you want to use PHY-recovered clock you should really use the DPLL
subsystem. It will also allow you to configure other PHYs taking this
signal as an input, to forward the clock phase. Read lock state. Etc.

Even if the patches are good (which I'm not saying they are yet ;)) -
you'll have to repost this as a new thread, unfortunately. I'm not sure
why by the way this was posted made patchwork think that the patches
are separate series:

https://patchwork.kernel.org/project/netdevbpf/list/?series=819440
https://patchwork.kernel.org/project/netdevbpf/list/?series=818548

each of which is incomplete, since it only has one patch but subject
says "1/2" and "2/2".
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/net/adi,adin.yaml b/Documentation/devicetree/bindings/net/adi,adin.yaml
index 929cf8c0b0fd..04059393b756 100644
--- a/Documentation/devicetree/bindings/net/adi,adin.yaml
+++ b/Documentation/devicetree/bindings/net/adi,adin.yaml
@@ -38,14 +38,17 @@  properties:
 
   adi,phy-output-clock:
     description: |
-      Select clock output on GP_CLK pin. Two clocks are available:
-      A 25MHz reference and a free-running 125MHz.
+      Select clock output on GP_CLK pin. Three clocks are available:
+        - 25MHz reference
+        - free-running 125MHz
+        - recovered 125MHz
       The phy can alternatively automatically switch between the reference and
       the 125MHz clocks based on its internal state.
     $ref: /schemas/types.yaml#/definitions/string
     enum:
       - 25mhz-reference
       - 125mhz-free-running
+      - 125mhz-recovered
       - adaptive-free-running
 
   adi,phy-output-reference-clock: