Skip to content

Commit aa571b6

Browse files
Bartosz Golaszewskikuba-moo
authored andcommitted
net: stmmac: add new switch to struct plat_stmmacenet_data
On some platforms, the PCS can be integrated in the MAC so the driver will not see any PCS link activity. Add a switch that allows the platform drivers to let the core code know. Signed-off-by: Bartosz Golaszewski <[email protected]> Reviewed-by: Jose Abreu <[email protected]> Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 463120c commit aa571b6

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

drivers/net/ethernet/stmicro/stmmac/stmmac_main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5798,7 +5798,7 @@ static void stmmac_common_interrupt(struct stmmac_priv *priv)
57985798
}
57995799

58005800
/* PCS link status */
5801-
if (priv->hw->pcs) {
5801+
if (priv->hw->pcs && !priv->plat->has_integrated_pcs) {
58025802
if (priv->xstats.pcs_link)
58035803
netif_carrier_on(priv->dev);
58045804
else

include/linux/stmmac.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,5 +293,6 @@ struct plat_stmmacenet_data {
293293
bool sph_disable;
294294
bool serdes_up_after_phy_linkup;
295295
const struct dwmac4_addrs *dwmac4_addrs;
296+
bool has_integrated_pcs;
296297
};
297298
#endif

0 commit comments

Comments
 (0)