linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michael Walle <michael@walle.cc>
To: Russell King - ARM Linux admin <linux@armlinux.org.uk>
Cc: bcm-kernel-feedback-list@broadcom.com, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	Florian Fainelli <f.fainelli@gmail.com>,
	Andrew Lunn <andrew@lunn.ch>,
	Heiner Kallweit <hkallweit1@gmail.com>,
	"David S . Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>
Subject: Re: [PATCH net-next] net: phy: introduce phydev->port
Date: Wed, 10 Feb 2021 13:10:43 +0100	[thread overview]
Message-ID: <f2791b563e18107d8b015e35832a45d5@walle.cc> (raw)
In-Reply-To: <20210210115415.GV1463@shell.armlinux.org.uk>

Am 2021-02-10 12:54, schrieb Russell King - ARM Linux admin:
> On Wed, Feb 10, 2021 at 12:20:02PM +0100, Michael Walle wrote:
>> 
>> Am 2021-02-09 17:38, schrieb Michael Walle:
>> > --- a/drivers/net/phy/phy.c
>> > +++ b/drivers/net/phy/phy.c
>> > @@ -308,7 +308,7 @@ void phy_ethtool_ksettings_get(struct phy_device
>> > *phydev,
>> >  	if (phydev->interface == PHY_INTERFACE_MODE_MOCA)
>> >  		cmd->base.port = PORT_BNC;
>> >  	else
>> > -		cmd->base.port = PORT_MII;
>> > +		cmd->base.port = phydev->port;
>> >  	cmd->base.transceiver = phy_is_internal(phydev) ?
>> >  				XCVR_INTERNAL : XCVR_EXTERNAL;
>> >  	cmd->base.phy_address = phydev->mdio.addr;
>> 
>> Russell, the phylink has a similiar place where PORT_MII is set. I 
>> don't
>> know if we'd have to change that, too.
> 
> What would we change it to?

It was just a question whether we have to change it and I take from your
answer we do not. I was just curious because there is the same edge case
for the PORT_BNC like in the phy core.

> If there's no PHY attached and no SFP, what kind of interface do we
> have? As we've no idea what's on the media side, assuming that we are
> presenting a MII-like interface to stuff outside of what we control is
> entirely reasonable.
> 
> Claiming the world is TP would be entirely wrong, there may not be a
> RJ45 jack. Consider the case where the MAC is connected to a switch.
> It's a MII-like link. It's certianly not TP, BNC, fiber, AUI, or
> direct attach.

Yes, I get your point.

-michael

  reply	other threads:[~2021-02-10 12:15 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-09 16:38 [PATCH net-next] net: phy: introduce phydev->port Michael Walle
2021-02-09 23:01 ` Florian Fainelli
2021-02-10  1:51 ` Andrew Lunn
2021-02-10 11:01   ` Russell King - ARM Linux admin
2021-02-10  1:53 ` Andrew Lunn
2021-02-10 11:20 ` Michael Walle
2021-02-10 11:54   ` Russell King - ARM Linux admin
2021-02-10 12:10     ` Michael Walle [this message]
2021-02-10 18:34   ` Florian Fainelli

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=f2791b563e18107d8b015e35832a45d5@walle.cc \
    --to=michael@walle.cc \
    --cc=andrew@lunn.ch \
    --cc=bcm-kernel-feedback-list@broadcom.com \
    --cc=davem@davemloft.net \
    --cc=f.fainelli@gmail.com \
    --cc=hkallweit1@gmail.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --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).