Skip to content

Commit 510f9f6

Browse files
kliteynSaeed Mahameed
authored andcommitted
net/mlx5: HWS, added API and enabled HWS support
Enabling HWS support in the mlx5 driver: - added HWS API header - added HWS files in the mlx5 driver makefile - added kconfig flag that enables HWS compilation Reviewed-by: Erez Shitrit <[email protected]> Signed-off-by: Yevgeny Kliteynik <[email protected]> Signed-off-by: Saeed Mahameed <[email protected]>
1 parent 2ca6259 commit 510f9f6

File tree

6 files changed

+994
-4
lines changed

6 files changed

+994
-4
lines changed

Documentation/networking/device_drivers/ethernet/mellanox/mlx5/kconfig.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,9 @@ Enabling the driver and kconfig options
130130

131131
| Build support for software-managed steering in the NIC.
132132
133+
**CONFIG_MLX5_HW_STEERING=(y/n)**
134+
135+
| Build support for hardware-managed steering in the NIC.
133136
134137
**CONFIG_MLX5_TC_CT=(y/n)**
135138

drivers/net/ethernet/mellanox/mlx5/core/Kconfig

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,16 @@ config MLX5_SW_STEERING
172172
help
173173
Build support for software-managed steering in the NIC.
174174

175+
config MLX5_HW_STEERING
176+
bool "Mellanox Technologies hardware-managed steering"
177+
depends on MLX5_CORE_EN && MLX5_ESWITCH
178+
default y
179+
help
180+
Build support for Hardware-Managed Flow Steering (HMFS) in the NIC.
181+
HMFS is a new approach to managing steering rules where STEs are
182+
written to ICM by HW (as opposed to SW in software-managed steering),
183+
which allows higher rate of rule insertion.
184+
175185
config MLX5_SF
176186
bool "Mellanox Technologies subfunction device support using auxiliary device"
177187
depends on MLX5_CORE && MLX5_CORE_EN

drivers/net/ethernet/mellanox/mlx5/core/Makefile

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,27 @@ mlx5_core-$(CONFIG_MLX5_SW_STEERING) += steering/dr_domain.o steering/dr_table.o
119119
steering/dr_action.o steering/fs_dr.o \
120120
steering/dr_definer.o steering/dr_ptrn.o \
121121
steering/dr_arg.o steering/dr_dbg.o lib/smfs.o
122+
123+
#
124+
# HW Steering
125+
#
126+
mlx5_core-$(CONFIG_MLX5_HW_STEERING) += steering/hws/mlx5hws_cmd.o \
127+
steering/hws/mlx5hws_context.o \
128+
steering/hws/mlx5hws_pat_arg.o \
129+
steering/hws/mlx5hws_buddy.o \
130+
steering/hws/mlx5hws_pool.o \
131+
steering/hws/mlx5hws_table.o \
132+
steering/hws/mlx5hws_action.o \
133+
steering/hws/mlx5hws_rule.o \
134+
steering/hws/mlx5hws_matcher.o \
135+
steering/hws/mlx5hws_send.o \
136+
steering/hws/mlx5hws_definer.o \
137+
steering/hws/mlx5hws_bwc.o \
138+
steering/hws/mlx5hws_debug.o \
139+
steering/hws/mlx5hws_vport.o \
140+
steering/hws/mlx5hws_bwc_complex.o
141+
142+
122143
#
123144
# SF device
124145
#
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# SPDX-License-Identifier: GPL-2.0-only
2+
subdir-ccflags-y += -I$(src)/..

0 commit comments

Comments
 (0)