All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Russell King (Oracle)" <linux@armlinux.org.uk>
To: Oleksandr Mazur <oleksandr.mazur@plvision.eu>
Cc: Andrew Lunn <andrew@lunn.ch>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"davem@davemloft.net" <davem@davemloft.net>,
	"edumazet@google.com" <edumazet@google.com>,
	"kuba@kernel.org" <kuba@kernel.org>,
	"pabeni@redhat.com" <pabeni@redhat.com>,
	Yevhen Orlov <yevhen.orlov@plvision.eu>,
	Taras Chornyi <taras.chornyi@plvision.eu>
Subject: Re: [PATCH V2 net-next] net: marvell: prestera: add phylink support
Date: Thu, 14 Jul 2022 13:39:00 +0100	[thread overview]
Message-ID: <YtAOZGLR1a74FnoQ@shell.armlinux.org.uk> (raw)
In-Reply-To: <GV1P190MB2019C2CFF4AB6934E8752A32E4889@GV1P190MB2019.EURP190.PROD.OUTLOOK.COM>

On Thu, Jul 14, 2022 at 08:56:26AM +0000, Oleksandr Mazur wrote:
> Hello Andrew, Russel,
> Thanks for the input and sorry for the inconviniences.
> 
> >First question which applies to everything in this patch is - why make
> >phylink conditional for this driver?
> 
> 1. As for the phylink ifdefs:
> The original idea was to support mac config on devices (DB boards) that don't have full sfp support on board, however we scrapped out
> this idea as we could simply use fixed-link DTS configs; also due to this solution being non-upstream-friendly.
> Please note that V2 holds no phylink ifdefs;

I didn't specifically ask about the ifdefs - I asked the general
question about "why make phylink conditional for this driver".
Yes, v1 had ifdefs. v2 does not, but phylink is _still_ conditional.
You are introduing lots of this pattern of code:

	if (blah->phy_link)
		do something phylink related
	else
		do something else

And I want to know why.

> >In SGMII mode, it is normal for the advertising
> >mask to indicate the media modes on the PHY to advertise
> 2. As for the SGMII mode, yes, Russel, you're right; V3 will hold a fix for this, and keep the inband enabled for SGMII.
> 
> >No way to restart 1000base-X autoneg?
> 3. As for AN restart, no, it's not yet supported by our FW as of now.

Maybe put a comment in the code to that effect?

> >I think you should be calling phylink_mac_change() here, rather than
> >below.
> 
> 4. V3 is gonna fix this, thanks for the input.

Thanks.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!

  reply	other threads:[~2022-07-14 12:39 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-13 17:20 [PATCH V2 net-next] net: marvell: prestera: add phylink support Oleksandr Mazur
2022-07-13 20:05 ` Russell King (Oracle)
2022-07-13 21:52   ` Andrew Lunn
2022-07-14  8:56     ` Oleksandr Mazur
2022-07-14 12:39       ` Russell King (Oracle) [this message]
2022-07-14 13:06         ` Andrew Lunn
2022-07-15  9:35           ` Oleksandr Mazur
2022-07-15  9:33         ` Oleksandr Mazur

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=YtAOZGLR1a74FnoQ@shell.armlinux.org.uk \
    --to=linux@armlinux.org.uk \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=oleksandr.mazur@plvision.eu \
    --cc=pabeni@redhat.com \
    --cc=taras.chornyi@plvision.eu \
    --cc=yevhen.orlov@plvision.eu \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.