Skip to content

Commit 73ac123

Browse files
kliteynNipaLocal
authored and
NipaLocal
committed
net/mlx5: DR, Fix 'stack guard page was hit' error in dr_rule
This patch reduces the size of hw_ste_arr_optimized array that is allocated on stack from 640 bytes (5 match STEs + 5 action STES) to 448 bytes (2 match STEs + 5 action STES). This fixes the 'stack guard page was hit' issue, while still fitting majority of the usecases (up to 2 match STEs). Signed-off-by: Yevgeny Kliteynik <[email protected]> Reviewed-by: Alex Vesker <[email protected]> Signed-off-by: Tariq Toukan <[email protected]> Reviewed-by: Wojciech Drewek <[email protected]> Signed-off-by: NipaLocal <nipa@local>
1 parent 810a97e commit 73ac123

File tree

1 file changed

+1
-1
lines changed
  • drivers/net/ethernet/mellanox/mlx5/core/steering

1 file changed

+1
-1
lines changed

drivers/net/ethernet/mellanox/mlx5/core/steering/dr_rule.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
/* don't try to optimize STE allocation if the stack is too constaraining */
88
#define DR_RULE_MAX_STES_OPTIMIZED 0
99
#else
10-
#define DR_RULE_MAX_STES_OPTIMIZED 5
10+
#define DR_RULE_MAX_STES_OPTIMIZED 2
1111
#endif
1212
#define DR_RULE_MAX_STE_CHAIN_OPTIMIZED (DR_RULE_MAX_STES_OPTIMIZED + DR_ACTION_MAX_STES)
1313

0 commit comments

Comments
 (0)