summaryrefslogtreecommitdiff
path: root/include/linux/stmmac.h
diff options
context:
space:
mode:
authorZiyang Chen <ziyang.chen@corigine.com>2023-07-12 14:35:51 +0200
committerJakub Kicinski <kuba@kernel.org>2023-07-13 20:36:10 -0700
commitbec9ce34075e4b1c4a36d9eb7a40e84929d12aa8 (patch)
tree44edbfab33159a3199c13c8e67c3c21b5aa5befb /include/linux/stmmac.h
parent6f13b49b57f2cdcb9cab3841da8a441c3521d64e (diff)
nfp: prevent dropped counter increment during probe
The dev_rx_discards counter will increment by one when an interface is toggled up and down. The main reason is that the driver first sends a `NFP_NET_CFG_CTRL_ENABLE` configuration packet to the NIC to perform port initialisation when an interface is set up. But there is a race between physical link up and free list queue initialization which may lead to the configuration packet being discarded. To address this problem a new bit NFP_NET_CFG_CTRL_FREELIST_EN is added to perform free list initialisation on the NIC. The FREELIST_EN should be sent in advance to initialize free list queue. When a port is set to down, FREELIST_EN should be sent after CTRL_ENABLE to avoid packet discards. Signed-off-by: Ziyang Chen <ziyang.chen@corigine.com> Acked-by: Simon Horman <simon.horman@corigine.com> Signed-off-by: Louis Peens <louis.peens@corigine.com> Link: https://lore.kernel.org/r/20230712123551.13858-1-louis.peens@corigine.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'include/linux/stmmac.h')
0 files changed, 0 insertions, 0 deletions