@@ -155,11 +155,21 @@ enum flow_action_mangle_base {
155155 FLOW_ACT_MANGLE_HDR_TYPE_UDP ,
156156};
157157
158- #define FLOW_ACTION_HW_STATS_TYPE_IMMEDIATE BIT(0)
159- #define FLOW_ACTION_HW_STATS_TYPE_DELAYED BIT(1)
160- #define FLOW_ACTION_HW_STATS_TYPE_ANY (FLOW_ACTION_HW_STATS_TYPE_IMMEDIATE | \
161- FLOW_ACTION_HW_STATS_TYPE_DELAYED)
162- #define FLOW_ACTION_HW_STATS_TYPE_DISABLED 0
158+ enum flow_action_hw_stats_type_bit {
159+ FLOW_ACTION_HW_STATS_TYPE_IMMEDIATE_BIT ,
160+ FLOW_ACTION_HW_STATS_TYPE_DELAYED_BIT ,
161+ };
162+
163+ enum flow_action_hw_stats_type {
164+ FLOW_ACTION_HW_STATS_TYPE_DISABLED = 0 ,
165+ FLOW_ACTION_HW_STATS_TYPE_IMMEDIATE =
166+ BIT (FLOW_ACTION_HW_STATS_TYPE_IMMEDIATE_BIT ),
167+ FLOW_ACTION_HW_STATS_TYPE_DELAYED =
168+ BIT (FLOW_ACTION_HW_STATS_TYPE_DELAYED_BIT ),
169+ FLOW_ACTION_HW_STATS_TYPE_ANY =
170+ FLOW_ACTION_HW_STATS_TYPE_IMMEDIATE |
171+ FLOW_ACTION_HW_STATS_TYPE_DELAYED ,
172+ };
163173
164174typedef void (* action_destr )(void * priv );
165175
@@ -175,7 +185,7 @@ void flow_action_cookie_destroy(struct flow_action_cookie *cookie);
175185
176186struct flow_action_entry {
177187 enum flow_action_id id ;
178- u8 hw_stats_type ;
188+ enum flow_action_hw_stats_type hw_stats_type ;
179189 action_destr destructor ;
180190 void * destructor_priv ;
181191 union {
0 commit comments