]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
net: stmmac: add warning when TSO is requested but unsupported
authorRussell King (Oracle) <rmk+kernel@armlinux.org.uk>
Wed, 1 Apr 2026 07:22:10 +0000 (08:22 +0100)
committerJakub Kicinski <kuba@kernel.org>
Thu, 2 Apr 2026 18:28:20 +0000 (11:28 -0700)
Add a warning message if TSO is requested by the platform glue code but
the core wasn't configured for TSO.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Link: https://patch.msgid.link/E1w7pty-0000000Eatt-2TjZ@rmk-PC.armlinux.org.uk
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c

index c9cb81ae812e32028ae030d64d6bf10614725a19..3c416fe79c159623c9510ad947a49f1a30617b44 100644 (file)
@@ -4392,8 +4392,10 @@ static void stmmac_set_gso_features(struct net_device *ndev)
        if (!(priv->plat->flags & STMMAC_FLAG_TSO_EN))
                return;
 
-       if (!priv->dma_cap.tsoen)
+       if (!priv->dma_cap.tsoen) {
+               dev_warn(priv->device, "platform requests unsupported TSO\n");
                return;
+       }
 
        ndev->hw_features |= NETIF_F_TSO | NETIF_F_TSO6;
        if (priv->plat->core_type == DWMAC_CORE_GMAC4)