net/sfc/base: define a handle to denote default RSS context

Make the existing filter-specific define more general.
This is the same as MC_CMD_RSS_CONTEXT_ALLOC_OUT_RSS_CONTEXT_ID_INVALID.

Signed-off-by: Mark Spender <mspender@solarflare.com>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Andy Moreton <amoreton@solarflare.com>
This commit is contained in:
Mark Spender 2017-08-30 19:17:32 +01:00 committed by Ferruh Yigit
parent 879b01bdfa
commit ec850627dc
3 changed files with 5 additions and 3 deletions

View File

@ -1882,6 +1882,9 @@ efx_rx_scatter_enable(
__in unsigned int buf_size);
#endif /* EFSYS_OPT_RX_SCATTER */
/* Handle to represent use of the default RSS context. */
#define EFX_RSS_CONTEXT_DEFAULT 0xffffffff
#if EFSYS_OPT_RX_SCALE
typedef enum efx_rx_hash_alg_e {
@ -2309,7 +2312,6 @@ typedef struct efx_filter_spec_s {
/* Default values for use in filter specifications */
#define EFX_FILTER_SPEC_RSS_CONTEXT_DEFAULT 0xffffffff
#define EFX_FILTER_SPEC_RX_DMAQ_ID_DROP 0xfff
#define EFX_FILTER_SPEC_VID_UNSPEC 0xffff

View File

@ -302,7 +302,7 @@ efx_filter_spec_init_rx(
memset(spec, 0, sizeof (*spec));
spec->efs_priority = priority;
spec->efs_flags = EFX_FILTER_FLAG_RX | flags;
spec->efs_rss_context = EFX_FILTER_SPEC_RSS_CONTEXT_DEFAULT;
spec->efs_rss_context = EFX_RSS_CONTEXT_DEFAULT;
spec->efs_dmaq_id = (uint16_t)erp->er_index;
}

View File

@ -803,7 +803,7 @@ sfc_flow_parse_attr(const struct rte_flow_attr *attr,
}
flow->spec.efs_flags |= EFX_FILTER_FLAG_RX;
flow->spec.efs_rss_context = EFX_FILTER_SPEC_RSS_CONTEXT_DEFAULT;
flow->spec.efs_rss_context = EFX_RSS_CONTEXT_DEFAULT;
return 0;
}