net/sfc/base: add Medford2 support to FILTER module
Signed-off-by: Andy Moreton <amoreton@solarflare.com> Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
This commit is contained in:
parent
70dcfd3bd1
commit
f4642251f8
@ -7,7 +7,7 @@
|
||||
#include "efx.h"
|
||||
#include "efx_impl.h"
|
||||
|
||||
#if EFSYS_OPT_HUNTINGTON || EFSYS_OPT_MEDFORD
|
||||
#if EFSYS_OPT_HUNTINGTON || EFSYS_OPT_MEDFORD || EFSYS_OPT_MEDFORD2
|
||||
|
||||
#if EFSYS_OPT_FILTER
|
||||
|
||||
@ -95,7 +95,8 @@ ef10_filter_init(
|
||||
ef10_filter_table_t *eftp;
|
||||
|
||||
EFSYS_ASSERT(enp->en_family == EFX_FAMILY_HUNTINGTON ||
|
||||
enp->en_family == EFX_FAMILY_MEDFORD);
|
||||
enp->en_family == EFX_FAMILY_MEDFORD ||
|
||||
enp->en_family == EFX_FAMILY_MEDFORD2);
|
||||
|
||||
#define MATCH_MASK(match) (EFX_MASK32(match) << EFX_LOW_BIT(match))
|
||||
EFX_STATIC_ASSERT(EFX_FILTER_MATCH_REM_HOST ==
|
||||
@ -150,7 +151,8 @@ ef10_filter_fini(
|
||||
__in efx_nic_t *enp)
|
||||
{
|
||||
EFSYS_ASSERT(enp->en_family == EFX_FAMILY_HUNTINGTON ||
|
||||
enp->en_family == EFX_FAMILY_MEDFORD);
|
||||
enp->en_family == EFX_FAMILY_MEDFORD ||
|
||||
enp->en_family == EFX_FAMILY_MEDFORD2);
|
||||
|
||||
if (enp->en_filter.ef_ef10_filter_table != NULL) {
|
||||
EFSYS_KMEM_FREE(enp->en_esip, sizeof (ef10_filter_table_t),
|
||||
@ -495,7 +497,8 @@ ef10_filter_restore(
|
||||
efx_rc_t rc;
|
||||
|
||||
EFSYS_ASSERT(enp->en_family == EFX_FAMILY_HUNTINGTON ||
|
||||
enp->en_family == EFX_FAMILY_MEDFORD);
|
||||
enp->en_family == EFX_FAMILY_MEDFORD ||
|
||||
enp->en_family == EFX_FAMILY_MEDFORD2);
|
||||
|
||||
for (tbl_id = 0; tbl_id < EFX_EF10_FILTER_TBL_ROWS; tbl_id++) {
|
||||
|
||||
@ -570,7 +573,8 @@ ef10_filter_add_internal(
|
||||
boolean_t locked = B_FALSE;
|
||||
|
||||
EFSYS_ASSERT(enp->en_family == EFX_FAMILY_HUNTINGTON ||
|
||||
enp->en_family == EFX_FAMILY_MEDFORD);
|
||||
enp->en_family == EFX_FAMILY_MEDFORD ||
|
||||
enp->en_family == EFX_FAMILY_MEDFORD2);
|
||||
|
||||
hash = ef10_filter_hash(spec);
|
||||
|
||||
@ -842,7 +846,8 @@ ef10_filter_delete(
|
||||
boolean_t locked = B_FALSE;
|
||||
|
||||
EFSYS_ASSERT(enp->en_family == EFX_FAMILY_HUNTINGTON ||
|
||||
enp->en_family == EFX_FAMILY_MEDFORD);
|
||||
enp->en_family == EFX_FAMILY_MEDFORD ||
|
||||
enp->en_family == EFX_FAMILY_MEDFORD2);
|
||||
|
||||
hash = ef10_filter_hash(spec);
|
||||
|
||||
@ -1636,4 +1641,4 @@ ef10_filter_default_rxq_clear(
|
||||
|
||||
#endif /* EFSYS_OPT_FILTER */
|
||||
|
||||
#endif /* EFSYS_OPT_HUNTINGTON || EFSYS_OPT_MEDFORD */
|
||||
#endif /* EFSYS_OPT_HUNTINGTON || EFSYS_OPT_MEDFORD || EFSYS_OPT_MEDFORD2 */
|
||||
|
@ -56,7 +56,7 @@ static const efx_filter_ops_t __efx_filter_siena_ops = {
|
||||
};
|
||||
#endif /* EFSYS_OPT_SIENA */
|
||||
|
||||
#if EFSYS_OPT_HUNTINGTON || EFSYS_OPT_MEDFORD
|
||||
#if EFSYS_OPT_HUNTINGTON || EFSYS_OPT_MEDFORD || EFSYS_OPT_MEDFORD2
|
||||
static const efx_filter_ops_t __efx_filter_ef10_ops = {
|
||||
ef10_filter_init, /* efo_init */
|
||||
ef10_filter_fini, /* efo_fini */
|
||||
@ -66,7 +66,7 @@ static const efx_filter_ops_t __efx_filter_ef10_ops = {
|
||||
ef10_filter_supported_filters, /* efo_supported_filters */
|
||||
ef10_filter_reconfigure, /* efo_reconfigure */
|
||||
};
|
||||
#endif /* EFSYS_OPT_HUNTINGTON || EFSYS_OPT_MEDFORD */
|
||||
#endif /* EFSYS_OPT_HUNTINGTON || EFSYS_OPT_MEDFORD || EFSYS_OPT_MEDFORD2 */
|
||||
|
||||
__checkReturn efx_rc_t
|
||||
efx_filter_insert(
|
||||
@ -145,6 +145,12 @@ efx_filter_init(
|
||||
break;
|
||||
#endif /* EFSYS_OPT_MEDFORD */
|
||||
|
||||
#if EFSYS_OPT_MEDFORD2
|
||||
case EFX_FAMILY_MEDFORD2:
|
||||
efop = &__efx_filter_ef10_ops;
|
||||
break;
|
||||
#endif /* EFSYS_OPT_MEDFORD2 */
|
||||
|
||||
default:
|
||||
EFSYS_ASSERT(0);
|
||||
rc = ENOTSUP;
|
||||
|
Loading…
Reference in New Issue
Block a user