lkml.org 
[lkml]   [2020]   [Nov]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/2] net: dsa: ksz8795: adjust CPU link to host interface
On Sun, Nov 29, 2020 at 11:24:00AM +0100, Jean Pihet wrote:
> Add support for RGMII in 100 and 1000 Mbps.
>
> Adjust the CPU port based on the host interface settings: interface
> MII type, speed, duplex.

Please could you add some extra information here why this is needed. I
suspect you have back to back PHYs on the CPU port?

> +void ksz8795_adjust_link(struct dsa_switch *ds, int port,
> + struct phy_device *phydev)
> +{
> + struct ksz_device *dev = ds->priv;
> + struct ksz_port *p = &dev->ports[port];
> +
> + /* Adjust the link interface mode and speed for the CPU port */
> + if (port == dev->cpu_port)

dsa_is_cpu_port(ds, port)

Andrew

\
 
 \ /
  Last update: 2020-11-29 18:08    [W:0.487 / U:0.496 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site