Unicast Source Address Filter
The MAC can also perform a perfect filtering based on the source address field of the received frames. Group
filtering with SA is also supported. You can filter a group of addresses by masking one or more bytes of the
address.
†
Inverse Filtering Operation (Invert the Filter Match Result at Final Output)
For both Destination and Source address filtering, there is an option to invert the filter-match result at the
final output. The result of the unicast or multicast destination address filter is inverted in this mode.
†
VLAN Filtering
The EMAC supports the two kinds of VLAN filtering:
• VLAN tag-based filtering
†
• VLAN hash filtering
†
VLAN Tag-Based Filtering
In the VLAN tag-based frame filtering, the MAC compares the VLAN tag of the received frame and provides
the VLAN frame status to the application. Based on the programmed mode, the MAC compares the lower
12 bits or all 16 bits of the received VLAN tag to determine the perfect match. If VLAN tag filtering is enabled,
the MAC forwards the VLAN-tagged frames along with VLAN tag match status and drops the VLAN frames
that do not match. You can also enable the inverse matching for VLAN frames. In addition, you can enable
matching of SVLAN tagged frames along with the default Customer Virtual Local Area Network (C-VLAN)
tagged frames.
†
VLAN Hash Filtering with a 16-Bit Hash Table
The MAC provides VLAN hash filtering with a 16-bit hash table. The MAC also supports the inverse matching
of the VLAN frames. In inverse matching mode, when the VLAN tag of a frame matches the perfect or hash
filter, the packet should be dropped. If the VLAN perfect and VLAN hash match are enabled, a frame is
considered as matched if either the VLAN hash or the VLAN perfect filter matches. When inverse match is
set, a packet is forwarded only when both perfect and hash filters indicate mismatch.
†
Layer 3 and Layer 4 Filters
Layer 3 filtering refers to source address and destination address filtering. Layer 4 filtering refers to source
port and destination port filtering. The frames are filtered in the following ways:
†
• Matched frames
†
• Unmatched frames
†
• Non-TCP or UDP IP frames
†
Matched Frames
The MAC forwards the frames, which match all enabled fields, to the application along with the status. The
MAC gives the matched field status only if one of the following conditions is true:
†
• All enabled Layer 3 and Layer 4 fields match.
†
• At least one of the enabled field matches and other fields are bypassed or disabled.
†
Using the CSR set, you can define up to four filters, identified as filter 0 through filter 3. When multiple
Layer 3 and Layer 4 filters are enabled, any filter match is considered as a match. If more than one filter
Altera Corporation
Ethernet Media Access Controller
17-21
Unicast Source Address Filter
cv_54017
2013.12.30