]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
eth: fbnic: Configure RDE settings for pause frame
authorMohsin Bashir <mohsin.bashr@gmail.com>
Thu, 13 Nov 2025 23:26:10 +0000 (15:26 -0800)
committerJakub Kicinski <kuba@kernel.org>
Tue, 18 Nov 2025 00:57:32 +0000 (16:57 -0800)
commit0135333914d63181f823bd340ae96737c8a820ca
treed554dcd7fbe2ceebeabba2c7467db536d45a55fb
parent122ac16b8c95423da011e4c07a818138cb297ed9
eth: fbnic: Configure RDE settings for pause frame

fbnic supports pause frames. When pause frames are enabled presumably
user expects lossless operation from the NIC. Make sure we configure
RDE (Rx DMA Engine) to DROP_NEVER mode to avoid discards due to delays
in fetching Rx descriptors from the host.

While at it enable DROP_NEVER when NIC only has a single queue
configured. In this case the NIC acts as a FIFO so there's no risk
of head-of-line blocking other queues by making RDE wait. If pause
is disabled this just moves the packet loss from the DMA engine to
the Rx buffer.

Remove redundant call to fbnic_config_drop_mode_rcq(), introduced by
commit 0cb4c0a13723 ("eth: fbnic: Implement Rx queue
alloc/start/stop/free"). This call does not add value as
fbnic_enable_rcq(), which is called immediately afterward, already
handles this.

Although we do not support autoneg at this time, preserve tx_pause in
.mac_link_up instead of fbnic_phylink_get_pauseparam()

Signed-off-by: Mohsin Bashir <mohsin.bashr@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Link: https://patch.msgid.link/20251113232610.1151712-1-mohsin.bashr@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/meta/fbnic/fbnic_netdev.h
drivers/net/ethernet/meta/fbnic/fbnic_phylink.c
drivers/net/ethernet/meta/fbnic/fbnic_txrx.c
drivers/net/ethernet/meta/fbnic/fbnic_txrx.h