From: "Wells Lu 呂芳騰" <wells.lu@sunplus.com>
To: Andrew Lunn <andrew@lunn.ch>
Cc: "Wells Lu" <wellslutw@gmail.com>,
"davem@davemloft.net" <davem@davemloft.net>,
"kuba@kernel.org" <kuba@kernel.org>,
"robh+dt@kernel.org" <robh+dt@kernel.org>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"p.zabel@pengutronix.de" <p.zabel@pengutronix.de>,
"Vincent Shih 施錕鴻" <vincent.shih@sunplus.com>
Subject: RE: [PATCH net-next v3 2/2] net: ethernet: Add driver for Sunplus SP7021
Date: Thu, 2 Dec 2021 18:46:40 +0000 [thread overview]
Message-ID: <2fded2fc3a1344d0882ae2f186257911@sphcmbx02.sunplus.com.tw> (raw)
In-Reply-To: <YajEbXtBwlDL4gOL@lunn.ch>
Hi Andrew,
Thank you for explanation.
I'll add phy_support_asym_pause() after PHY connected next patch.
I found some drivers call phy_set_max_speed() to set PHY speed to
100M after PHY connected. Is that necessary? From 'supported', PHY
supports 10M/100M already.
I also found some drivers call phy_start_aneg() after PHY started.
Is that necessary? From status register of PHY, 'auto-nego' has
completed.
Best regards,
Wells
> > I printed out the value of 'supported' and 'advertising'.
> > 'supported' shows PHY device supports Pause and AsymPause (0x62cf).
> > But 'advertising' shows PHY device does not support Pause or AsymPause (0x02cf).
> > Is this correct?
> >
> > How to let link partner know local node supports Pause & AsymPause
> > (flow control)?
> >
>
> 'supported' indicates that the PHY can do. It has the ability to advertise pause. But we
> don't automatically copy those bits into 'advertising' because we don't know if the MAC
> actually supports pause/asym pause.
>
> The MAC driver needs to call phy_support_sym_pause() or
> phy_support_asym_pause() to let phylib know what it can do. phylib will then add the
> appropriate bits to 'advertising'.
>
> > Will mii_read() and mii_write() be called in interrupt context?
>
> No. Only thread context, because it uses a mutex to prevent multiple accesses at the same
> time.
>
> Andrew
next prev parent reply other threads:[~2021-12-02 18:47 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-30 10:02 [PATCH net-next v3 0/2] This is a patch series for pinctrl driver for Sunplus SP7021 SoC Wells Lu
2021-11-30 10:02 ` [PATCH net-next v3 1/2] devicetree: bindings: net: Add bindings doc for Sunplus SP7021 Wells Lu
2021-12-01 1:56 ` Andrew Lunn
2021-12-01 7:02 ` Wells Lu 呂芳騰
2021-11-30 10:02 ` [PATCH net-next v3 2/2] net: ethernet: Add driver " Wells Lu
2021-11-30 13:51 ` kernel test robot
2021-12-01 3:30 ` Andrew Lunn
2021-12-02 11:20 ` Wells Lu 呂芳騰
2021-12-02 13:04 ` Andrew Lunn
2021-12-02 18:46 ` Wells Lu 呂芳騰 [this message]
2021-12-02 19:03 ` Andrew Lunn
2021-12-03 1:36 ` Wells Lu 呂芳騰
2021-11-30 20:17 ` [PATCH net-next v3 0/2] This is a patch series for pinctrl driver for Sunplus SP7021 SoC Andrew Lunn
2021-12-01 1:42 ` Wells Lu 呂芳騰
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=2fded2fc3a1344d0882ae2f186257911@sphcmbx02.sunplus.com.tw \
--to=wells.lu@sunplus.com \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=p.zabel@pengutronix.de \
--cc=robh+dt@kernel.org \
--cc=vincent.shih@sunplus.com \
--cc=wellslutw@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).