netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Russell King (Oracle)" <linux@armlinux.org.uk>
To: Maxime Chevallier <maxime.chevallier@bootlin.com>
Cc: Andrew Lunn <andrew@lunn.ch>,
	Heiner Kallweit <hkallweit1@gmail.com>,
	Alexandre Torgue <alexandre.torgue@foss.st.com>,
	Andrew Lunn <andrew+netdev@lunn.ch>,
	Bryan Whitehead <bryan.whitehead@microchip.com>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>,
	linux-arm-kernel@lists.infradead.org,
	linux-stm32@st-md-mailman.stormreply.com,
	Marcin Wojtas <marcin.s.wojtas@gmail.com>,
	Maxime Coquelin <mcoquelin.stm32@gmail.com>,
	netdev@vger.kernel.org, Paolo Abeni <pabeni@redhat.com>,
	Simon Horman <horms@kernel.org>,
	UNGLinuxDriver@microchip.com, Vladimir Oltean <olteanv@gmail.com>
Subject: Re: [PATCH RFC net-next 06/10] net: mvpp2: add EEE implementation
Date: Wed, 15 Jan 2025 15:46:24 +0000	[thread overview]
Message-ID: <Z4fYUAxIG6k0Uuka@shell.armlinux.org.uk> (raw)
In-Reply-To: <20250115155354.0acdacc7@fedora.home>

On Wed, Jan 15, 2025 at 03:53:54PM +0100, Maxime Chevallier wrote:
> Hello Russell,
> 
> On Tue, 14 Jan 2025 14:02:29 +0000
> "Russell King (Oracle)" <rmk+kernel@armlinux.org.uk> wrote:
> 
> > Add EEE support for mvpp2, using phylink's EEE implementation, which
> > means we just need to implement the two methods for LPI control, and
> > with the initial configuration. Only SGMII mode is supported, so only
> > 100M and 1G speeds.
> > 
> > Disabling LPI requires clearing a single bit. Enabling LPI needs a full
> > configuration of several values, as the timer values are dependent on
> > the MAC operating speed.
> > 
> > Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
> > --
> > v3: split LPI timer limit and validation into separate patches
> > ---
> >  drivers/net/ethernet/marvell/mvpp2/mvpp2.h    |  5 ++
> >  .../net/ethernet/marvell/mvpp2/mvpp2_main.c   | 86 +++++++++++++++++++
> >  2 files changed, 91 insertions(+)
> > 
> > diff --git a/drivers/net/ethernet/marvell/mvpp2/mvpp2.h b/drivers/net/ethernet/marvell/mvpp2/mvpp2.h
> > index 9e02e4367bec..364d038da7ea 100644
> > --- a/drivers/net/ethernet/marvell/mvpp2/mvpp2.h
> > +++ b/drivers/net/ethernet/marvell/mvpp2/mvpp2.h
> > @@ -481,6 +481,11 @@
> >  #define MVPP22_GMAC_INT_SUM_MASK		0xa4
> >  #define     MVPP22_GMAC_INT_SUM_MASK_LINK_STAT	BIT(1)
> >  #define	    MVPP22_GMAC_INT_SUM_MASK_PTP	BIT(2)
> > +#define MVPP2_GMAC_LPI_CTRL0			0xc0
> > +#define     MVPP2_GMAC_LPI_CTRL0_TS_MASK	GENMASK(8, 8)
> 
> I think this should be GENMASK(15, 8) :)

Bah.

Thanks for spotting... and people say GENMASK() is better than using
hex. I've disagreed with that, but tried to conform, but I keep making
mistakes with GENMASK(), but never have with hex notation. Maybe I'm
just different from most people, having been programming computers in
assembly since the 1980s, where the choices were decimal or hex!

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

  reply	other threads:[~2025-01-15 15:46 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-14 13:58 [PATCH RFC net-next 00/10] net: add phylink managed EEE support Russell King (Oracle)
2025-01-14 14:02 ` [PATCH RFC net-next 01/10] net: mdio: add definition for clock stop capable bit Russell King (Oracle)
2025-01-14 14:02 ` [PATCH RFC net-next 02/10] net: phy: add support for querying PHY clock stop capability Russell King (Oracle)
2025-01-14 14:02 ` [PATCH RFC net-next 03/10] net: phylink: add phylink_link_is_up() helper Russell King (Oracle)
2025-01-14 14:02 ` [PATCH RFC net-next 04/10] net: phylink: add EEE management Russell King (Oracle)
2025-01-15 15:55   ` Russell King (Oracle)
2025-01-14 14:02 ` [PATCH RFC net-next 05/10] net: mvneta: convert to phylink EEE implementation Russell King (Oracle)
2025-01-14 14:02 ` [PATCH RFC net-next 06/10] net: mvpp2: add " Russell King (Oracle)
2025-01-15 14:53   ` Maxime Chevallier
2025-01-15 15:46     ` Russell King (Oracle) [this message]
2025-01-14 14:02 ` [PATCH RFC net-next 07/10] net: lan743x: use netdev in lan743x_phylink_mac_link_down() Russell King (Oracle)
2025-01-14 14:02 ` [PATCH RFC net-next 08/10] net: lan743x: convert to phylink managed EEE Russell King (Oracle)
2025-01-14 14:02 ` [PATCH RFC net-next 09/10] net: stmmac: convert to phylink managed EEE support Russell King (Oracle)
2025-01-14 14:02 ` [PATCH RFC net-next 10/10] net: dsa: allow use of " Russell King (Oracle)
2025-01-14 19:26   ` Vladimir Oltean
2025-01-14 20:02     ` Russell King (Oracle)
2025-01-14 20:28       ` Vladimir Oltean

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=Z4fYUAxIG6k0Uuka@shell.armlinux.org.uk \
    --to=linux@armlinux.org.uk \
    --cc=UNGLinuxDriver@microchip.com \
    --cc=alexandre.torgue@foss.st.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=andrew@lunn.ch \
    --cc=bryan.whitehead@microchip.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=hkallweit1@gmail.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-stm32@st-md-mailman.stormreply.com \
    --cc=marcin.s.wojtas@gmail.com \
    --cc=maxime.chevallier@bootlin.com \
    --cc=mcoquelin.stm32@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=pabeni@redhat.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).