]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5e: Drop the len output parameter from mlx5e_xdp_handle
authorMaxim Mikityanskiy <maximmi@nvidia.com>
Thu, 27 Jan 2022 14:42:18 +0000 (16:42 +0200)
committerSaeed Mahameed <saeedm@nvidia.com>
Thu, 17 Mar 2022 18:51:55 +0000 (11:51 -0700)
commit2d65245ced04cb28a321dec6a8ebae802f4a90be
tree8fc918b52cb96b4212fb1c838bbf52bfdd0949e3
parentfce077bda2ff05cbb2cbd913fdc8fc1c304b66dd
net/mlx5e: Drop the len output parameter from mlx5e_xdp_handle

The len parameter of mlx5e_xdp_handle is used to output the new packet
length after XDP has processed the packet and returned XDP_PASS.
However, this value can be calculated on the caller site, as the caller
knows if it was an XDP_PASS.

This commit drops the len parameter and moves the calculation to the
caller, reducing the number of parameters passed to the function and
preparing for XDP support in non-linear legacy RQ.

Signed-off-by: Maxim Mikityanskiy <maximmi@nvidia.com>
Reviewed-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
drivers/net/ethernet/mellanox/mlx5/core/en/xdp.c
drivers/net/ethernet/mellanox/mlx5/core/en/xdp.h
drivers/net/ethernet/mellanox/mlx5/core/en/xsk/rx.c
drivers/net/ethernet/mellanox/mlx5/core/en_rx.c