]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
sfxge(4): split EFX_FILTER_MATCH_LOC_MAC_IG back into separate flags
authorarybchik <arybchik@FreeBSD.org>
Thu, 29 Dec 2016 07:02:32 +0000 (07:02 +0000)
committerarybchik <arybchik@FreeBSD.org>
Thu, 29 Dec 2016 07:02:32 +0000 (07:02 +0000)
commit9cf23bd08aba19b741a59f297f690fdd3bde69e4
tree9df7b3350a361e37731647ac66bafc13c7435a9d
parente79229e84d66b7f5f727192f835f21a13d746eb0
sfxge(4): split EFX_FILTER_MATCH_LOC_MAC_IG back into separate flags

The flag EFX_FILTER_MATCH_LOC_MAC_IG to represent filtering on the
individual/group bit of the MAC address (with the two cases being
distingusished by the MAC address in the filter specification) was
introduced to mirror the Linux driver filtering code, but the
implementations are different enough anyway that it isn't of much value.

Having separate flags for unknown unicast and multicast simplifies
the code and allows the set of flags to match those used by MCDI.

It will also makes it easier to report whether these filters are
supported.

In the MCDI definitions, the unknown multicast and unicast flags have
the values 0x40000000 and 0x80000000 respectively, and so using the
same values for simplicity requires 32 bits in the filter specification
to store the flags. This means the structure is now a little bigger
than 64 bytes, but filters are not often used on critical paths so this
shouldn't have much impact - on Linux they are also bigger than they
used to be.

Submitted by:   Mark Spender <mspender at solarflare.com>
Reviewed by:    gnn
Sponsored by:   Solarflare Communications, Inc.
MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D8951
sys/dev/sfxge/common/ef10_filter.c
sys/dev/sfxge/common/efx.h
sys/dev/sfxge/common/efx_filter.c