netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Lunn <andrew@lunn.ch>
To: Lukasz Stelmach <l.stelmach@samsung.com>
Cc: "Heiner Kallweit" <hkallweit1@gmail.com>,
	"Russell King" <linux@armlinux.org.uk>,
	"David S. Miller" <davem@davemloft.net>,
	"Jakub Kicinski" <kuba@kernel.org>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	"Bartłomiej Żolnierkiewicz" <b.zolnierkie@samsung.com>,
	"Marek Szyprowski" <m.szyprowski@samsung.com>
Subject: Re: [PATCH v2] net: phy: Prevent reporting advertised modes when autoneg is off
Date: Fri, 16 Oct 2020 23:00:55 +0200	[thread overview]
Message-ID: <20201016210055.GK139700@lunn.ch> (raw)
In-Reply-To: <dleftjzh4m3qtp.fsf%l.stelmach@samsung.com>

On Fri, Oct 16, 2020 at 09:37:22PM +0200, Lukasz Stelmach wrote:
> It was <2020-10-16 pią 20:09>, when Andrew Lunn wrote:
> > On Thu, Oct 15, 2020 at 10:44:35AM +0200, Łukasz Stelmach wrote:
> >> Do not report advertised link modes (local and remote) when
> >> autonegotiation is turned off. mii_ethtool_get_link_ksettings() exhibits
> >> the same behaviour and this patch aims at unifying the behavior of both
> >> functions.
> >
> > Does ethtool allow you to configure advertised modes with autoneg off?
> > If it can, it would be useful to see what is being configured, before
> > it is actually turned on.
> >
> > ethtool -s eth42 autoneg off advertise 0xf
> >
> > does not give an error on an interface i have.
> 
> Yes, this is a good point. Do you think I should change the if()[1] in 
> mii_ethtool_get_link_ksettings() instead? I really think these two
> function should report the same.

Yes, i would change mii. Ideally we want all drivers to use
phylib/phylink, not mii. So i would modify mii to match
phylib/phylink, not the other way around.

And then there will be drivers which do their own PHY handling, hidden
away in firmware, and not using either of mii or phylib/phylink. You
can expect them to be inconsistent.

    Andrew

      reply	other threads:[~2020-10-16 21:01 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20201015084513eucas1p234e2fa7a42b973ee7feafbdac6267a84@eucas1p2.samsung.com>
2020-10-15  8:44 ` [PATCH v2] net: phy: Prevent reporting advertised modes when autoneg is off Łukasz Stelmach
2020-10-16 18:09   ` Andrew Lunn
     [not found]     ` <CGME20201016193736eucas1p1eb94190e16b194f473ade8c49ca34275@eucas1p1.samsung.com>
2020-10-16 19:37       ` Lukasz Stelmach
2020-10-16 21:00         ` Andrew Lunn [this message]

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=20201016210055.GK139700@lunn.ch \
    --to=andrew@lunn.ch \
    --cc=b.zolnierkie@samsung.com \
    --cc=davem@davemloft.net \
    --cc=hkallweit1@gmail.com \
    --cc=kuba@kernel.org \
    --cc=l.stelmach@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=m.szyprowski@samsung.com \
    --cc=netdev@vger.kernel.org \
    /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).