mlx4: handle non-napi callers to napi_poll
authorJonathan Lemon <bsd@fb.com>
Thu, 8 Oct 2020 18:45:26 +0000 (11:45 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 Oct 2020 08:06:58 +0000 (09:06 +0100)
commitb09bf8410dcf78cd61e1e52a95e7fb3d97677241
treead4e38553a6dc1ec1526f65aa74d08228bb4b745
parentf6b47285c4a47f9d8ad9a29161f0df2fdd40e432
mlx4: handle non-napi callers to napi_poll

[ Upstream commit b2b8a92733b288128feb57ffa694758cf475106c ]

netcons calls napi_poll with a budget of 0 to transmit packets.
Handle this by:
 - skipping RX processing
 - do not try to recycle TX packets to the RX cache

Signed-off-by: Jonathan Lemon <jonathan.lemon@gmail.com>
Reviewed-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/ethernet/mellanox/mlx4/en_rx.c
drivers/net/ethernet/mellanox/mlx4/en_tx.c