netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michal Smulski <michal.smulski@ooma.com>
To: "Andrew Lunn" <andrew@lunn.ch>, "Marek Behún" <marek.behun@nic.cz>
Cc: "f.fainelli@gmail.com" <f.fainelli@gmail.com>,
	"olteanv@gmail.com" <olteanv@gmail.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>
Subject: RE: [PATCH net-next v2] net: dsa: mv88e6xxx: implement USXGMII mode for mv88e6393x
Date: Mon, 29 May 2023 17:23:12 +0000	[thread overview]
Message-ID: <BYAPR14MB291865D8A5763CFA9552774FE34A9@BYAPR14MB2918.namprd14.prod.outlook.com> (raw)
In-Reply-To: <512cef84-b7f0-4532-86a3-6972d05ca25d@lunn.ch>


If I understand this correctly, you are asking to create a function for USXGMII similar to:

static int mv88e6390_serdes_pcs_get_state_sgmii(struct mv88e6xxx_chip *chip,
	int port, int lane, struct phylink_link_state *state)

However, the datasheet for 88e6393x chips does not document any registers for USXGMII interface (as it does for SGMII). You can only see that 10G link is valid by looking at MV88E6390_10G_STAT1 & MDIO_STAT1_LSTATUS which has already been implemented in:
static int mv88e6390_serdes_pcs_get_state_10g(struct mv88e6xxx_chip *chip,
	int port, int lane, struct phylink_link_state *state)
The datasheet states that in USXGMII mode the link is always set to 10GBASE-R coding for all data rates.

From the logs, I see that that the link is configured using in-band information. However, there is no register access in MV88E6393x that would allow to either control or get status information (speed, duplex, flow control, auto-negotiation, etc). Most of "useful" registers are already defined in mv88e6xxx/serdes.h file.

[   50.624175] mv88e6085 0x0000000008b96000:02: configuring for inband/usxgmii link mode
...
[  387.116463] fsl_dpaa2_eth dpni.3 eth1: configuring for inband/usxgmii link mode
[  387.132554] fsl_dpaa2_eth dpni.3 eth1: Link is Up - 10Gbps/Full - flow control off

If I misunderstood what is requested, please give me a bit more information what I should be adding for this patch to be accepted.

Regards,
Michal

-----Original Message-----
From: Andrew Lunn <andrew@lunn.ch> 
Sent: Monday, May 29, 2023 8:11 AM
To: Marek Behún <marek.behun@nic.cz>
Cc: Michal Smulski <msmulski2@gmail.com>; f.fainelli@gmail.com; olteanv@gmail.com; netdev@vger.kernel.org; Michal Smulski <michal.smulski@ooma.com>
Subject: Re: [PATCH net-next v2] net: dsa: mv88e6xxx: implement USXGMII mode for mv88e6393x

CAUTION: This email is originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.


On Sun, May 28, 2023 at 11:25:22AM +0200, Marek Behún wrote:
> You need also to implement serdes_pcs_get_state for USXGMII.
>
> Preferably by adding USXGMII relevant register constants into 
> include/uapi/linux/mii.h, and using them to parse state register.

And if a standard is being followed here, please try to make the code as helpers, so other USXGMII implementations can use them.

Thanks

        Andrew

  reply	other threads:[~2023-05-29 17:23 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-27 17:20 [PATCH net-next v2] net: dsa: mv88e6xxx: implement USXGMII mode for mv88e6393x Michal Smulski
2023-05-28  9:25 ` Marek Behún
2023-05-29 15:11   ` Andrew Lunn
2023-05-29 17:23     ` Michal Smulski [this message]
2023-05-30 13:54       ` Marek Behún
2023-05-31  5:54         ` Michal Smulski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=BYAPR14MB291865D8A5763CFA9552774FE34A9@BYAPR14MB2918.namprd14.prod.outlook.com \
    --to=michal.smulski@ooma.com \
    --cc=andrew@lunn.ch \
    --cc=f.fainelli@gmail.com \
    --cc=marek.behun@nic.cz \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).