1 /* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB
2 * Copyright (c) 2019 Mellanox Technologies
10 struct mlx5_flow_root_namespace;
13 struct mlx5_fs_dr_action {
14 struct mlx5dr_action *dr_action;
17 struct mlx5_fs_dr_rule {
18 struct mlx5dr_rule *dr_rule;
19 /* Only actions created by fs_dr */
20 struct mlx5dr_action **dr_actions;
24 struct mlx5_fs_dr_domain {
25 struct mlx5dr_domain *dr_domain;
28 struct mlx5_fs_dr_matcher {
29 struct mlx5dr_matcher *dr_matcher;
32 struct mlx5_fs_dr_table {
33 struct mlx5dr_table *dr_table;
34 struct mlx5dr_action *miss_action;
37 #ifdef CONFIG_MLX5_SW_STEERING
39 bool mlx5_fs_dr_is_supported(struct mlx5_core_dev *dev);
41 int mlx5_fs_dr_action_get_pkt_reformat_id(struct mlx5_pkt_reformat *pkt_reformat);
43 const struct mlx5_flow_cmds *mlx5_fs_cmd_get_dr_cmds(void);
47 static inline const struct mlx5_flow_cmds *mlx5_fs_cmd_get_dr_cmds(void)
52 static inline u32 mlx5_fs_dr_action_get_pkt_reformat_id(struct mlx5_pkt_reformat *pkt_reformat)
57 static inline bool mlx5_fs_dr_is_supported(struct mlx5_core_dev *dev)
62 #endif /* CONFIG_MLX5_SW_STEERING */