From: Andrew Lunn <andrew@lunn.ch>
To: Raju Lakkaraju <Raju.Lakkaraju@microchip.com>
Cc: netdev@vger.kernel.org, davem@davemloft.net,
linux@armlinux.org.uk, kuba@kernel.org, hkallweit1@gmail.com,
richardcochran@gmail.com, rdunlap@infradead.org,
Bryan.Whitehead@microchip.com, edumazet@google.com,
pabeni@redhat.com, linux-kernel@vger.kernel.org,
horms@kernel.org, UNGLinuxDriver@microchip.com
Subject: Re: [PATCH net-next V4 5/5] net: lan743x: Add support to ethtool phylink get and set settings
Date: Fri, 30 Aug 2024 22:55:10 +0200 [thread overview]
Message-ID: <9f74455e-45ec-495a-bc8e-1c61caab747c@lunn.ch> (raw)
In-Reply-To: <20240829055132.79638-6-Raju.Lakkaraju@microchip.com>
> @@ -3055,6 +3071,10 @@ static void lan743x_phylink_mac_link_up(struct phylink_config *config,
> cap & FLOW_CTRL_TX,
> cap & FLOW_CTRL_RX);
>
> + if (phydev)
> + lan743x_mac_eee_enable(adapter, phydev->enable_tx_lpi &&
> + phydev->eee_enabled);
This is wrong. The documentation says:
/**
* phy_support_eee - Set initial EEE policy configuration
* @phydev: Target phy_device struct
*
* This function configures the initial policy for Energy Efficient Ethernet
* (EEE) on the specified PHY device, influencing that EEE capabilities are
* advertised before the link is established. It should be called during PHY
* registration by the MAC driver and/or the PHY driver (for SmartEEE PHYs)
* if MAC supports LPI or PHY is capable to compensate missing LPI functionality
* of the MAC.
*
* The function sets default EEE policy parameters, including preparing the PHY
* to advertise EEE capabilities based on hardware support.
*
* It also sets the expected configuration for Low Power Idle (LPI) in the MAC
* driver. If the PHY framework determines that both local and remote
* advertisements support EEE, and the negotiated link mode is compatible with
* EEE, it will set enable_tx_lpi = true. The MAC driver is expected to act on
* this setting by enabling the LPI timer if enable_tx_lpi is set.
*/
So you should only be looking at enable_tx_lpi.
Also, do you actually call phy_support_eee() anywhere? I don't see it
in this patch, but maybe it was already there?
Adrew
next prev parent reply other threads:[~2024-08-30 20:55 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-29 5:51 [PATCH net-next V4 0/5] Add support to PHYLINK for LAN743x/PCI11x1x chips Raju Lakkaraju
2024-08-29 5:51 ` [PATCH net-next V4 1/5] net: phylink: Add phylink_set_fixed_link() to configure fixed link state in phylink Raju Lakkaraju
2024-08-30 20:37 ` Andrew Lunn
2024-08-29 5:51 ` [PATCH net-next V4 2/5] net: lan743x: Create separate PCS power reset function Raju Lakkaraju
2024-08-29 5:51 ` [PATCH net-next V4 3/5] net: lan743x: Create separate Link Speed Duplex state function Raju Lakkaraju
2024-08-29 5:51 ` [PATCH net-next V4 4/5] net: lan743x: Migrate phylib to phylink Raju Lakkaraju
2024-08-29 7:49 ` Maxime Chevallier
2024-08-30 5:36 ` Raju Lakkaraju
2024-08-29 5:51 ` [PATCH net-next V4 5/5] net: lan743x: Add support to ethtool phylink get and set settings Raju Lakkaraju
2024-08-30 20:55 ` Andrew Lunn [this message]
2024-09-04 8:23 ` Raju Lakkaraju
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=9f74455e-45ec-495a-bc8e-1c61caab747c@lunn.ch \
--to=andrew@lunn.ch \
--cc=Bryan.Whitehead@microchip.com \
--cc=Raju.Lakkaraju@microchip.com \
--cc=UNGLinuxDriver@microchip.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkallweit1@gmail.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=rdunlap@infradead.org \
--cc=richardcochran@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
all inboxes | Powered by JetHome®