]> git.itanic.dy.fi Git - linux-stable/commit
net: ixp4xx_eth: Support changing the MTU
authorLinus Walleij <linus.walleij@linaro.org>
Wed, 4 Oct 2023 22:43:53 +0000 (00:43 +0200)
committerJakub Kicinski <kuba@kernel.org>
Fri, 6 Oct 2023 22:52:08 +0000 (15:52 -0700)
commit4f08c25702399a53129c5152c5598a3ab6360e1d
treef5b7d6d92a129dfe53f1f4b81fe33fc19d84941c
parent0ff85cb9ce6631d7615fbfc0f816696c71556843
net: ixp4xx_eth: Support changing the MTU

As we don't specify the MTU in the driver, the framework
will fall back to 1500 bytes and this doesn't work very
well when we try to attach a DSA switch:

  eth1: mtu greater than device maximum
  ixp4xx_eth c800a000.ethernet eth1: error -22 setting
  MTU to 1504 to include DSA overhead

After locating an out-of-tree patch in OpenWrt I found
suitable code to set the MTU on the interface and ported
it and updated it. Now the MTU gets set properly.

Reviewed-by: Jacob Keller <jacob.e.keller@intel.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Link: https://lore.kernel.org/r/20231005-ixp4xx-eth-mtu-v4-1-08c66ed0bc69@linaro.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/xscale/ixp4xx_eth.c