* [PATCH net-next] net: enetc: use .mac_select_pcs() interface
@ 2022-01-25 16:31 Russell King (Oracle)
2022-01-26 16:40 ` patchwork-bot+netdevbpf
0 siblings, 1 reply; 2+ messages in thread
From: Russell King (Oracle) @ 2022-01-25 16:31 UTC (permalink / raw)
To: Claudiu Manoil; +Cc: David S. Miller, Jakub Kicinski, netdev
Convert the PCS selection to use mac_select_pcs, which allows the PCS
to perform any validation it needs.
Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
CFT patch message id E1mxq4r-00GWrp-Ay@rmk-PC.armlinux.org.uk
drivers/net/ethernet/freescale/enetc/enetc_pf.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/drivers/net/ethernet/freescale/enetc/enetc_pf.c b/drivers/net/ethernet/freescale/enetc/enetc_pf.c
index ed16a5ac9ad0..a0c75c717073 100644
--- a/drivers/net/ethernet/freescale/enetc/enetc_pf.c
+++ b/drivers/net/ethernet/freescale/enetc/enetc_pf.c
@@ -934,18 +934,21 @@ static void enetc_mdiobus_destroy(struct enetc_pf *pf)
enetc_imdio_remove(pf);
}
+static struct phylink_pcs *
+enetc_pl_mac_select_pcs(struct phylink_config *config, phy_interface_t iface)
+{
+ struct enetc_pf *pf = phylink_to_enetc_pf(config);
+
+ return pf->pcs;
+}
+
static void enetc_pl_mac_config(struct phylink_config *config,
unsigned int mode,
const struct phylink_link_state *state)
{
struct enetc_pf *pf = phylink_to_enetc_pf(config);
- struct enetc_ndev_priv *priv;
enetc_mac_config(&pf->si->hw, state->interface);
-
- priv = netdev_priv(pf->si->ndev);
- if (pf->pcs)
- phylink_set_pcs(priv->phylink, pf->pcs);
}
static void enetc_force_rgmii_mac(struct enetc_hw *hw, int speed, int duplex)
@@ -1062,6 +1065,7 @@ static void enetc_pl_mac_link_down(struct phylink_config *config,
static const struct phylink_mac_ops enetc_mac_phylink_ops = {
.validate = phylink_generic_validate,
+ .mac_select_pcs = enetc_pl_mac_select_pcs,
.mac_config = enetc_pl_mac_config,
.mac_link_up = enetc_pl_mac_link_up,
.mac_link_down = enetc_pl_mac_link_down,
--
2.30.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH net-next] net: enetc: use .mac_select_pcs() interface
2022-01-25 16:31 [PATCH net-next] net: enetc: use .mac_select_pcs() interface Russell King (Oracle)
@ 2022-01-26 16:40 ` patchwork-bot+netdevbpf
0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-01-26 16:40 UTC (permalink / raw)
To: Russell King; +Cc: claudiu.manoil, davem, kuba, netdev
Hello:
This patch was applied to netdev/net-next.git (master)
by David S. Miller <davem@davemloft.net>:
On Tue, 25 Jan 2022 16:31:10 +0000 you wrote:
> Convert the PCS selection to use mac_select_pcs, which allows the PCS
> to perform any validation it needs.
>
> Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
> ---
> CFT patch message id E1mxq4r-00GWrp-Ay@rmk-PC.armlinux.org.uk
>
> [...]
Here is the summary with links:
- [net-next] net: enetc: use .mac_select_pcs() interface
https://git.kernel.org/netdev/net-next/c/5fd16021578e
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-01-26 16:40 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-25 16:31 [PATCH net-next] net: enetc: use .mac_select_pcs() interface Russell King (Oracle)
2022-01-26 16:40 ` patchwork-bot+netdevbpf
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.