gmacgrp_vlan_tag

          Register 7 (VLAN Tag Register)   

The VLAN Tag register contains the IEEE 802.1Q VLAN Tag to identify the VLAN frames. The MAC compares the 13th and 14th bytes of the receiving frame (Length/Type) with 16'h8100, and the following two bytes are compared with the VLAN tag. If a match occurs, the MAC sets the received VLAN bit in the receive frame status. The legal length of the frame is increased from 1,518 bytes to 1,522 bytes.
If the VLAN Tag register is configured to be double-synchronized to the (G)MII clock domain, then consecutive writes to these register should be performed only after at least four clock cycles in the destination clock domain.
      
Module Instance Base Address Register Address
i_emac_emac0 0xFF800000 0xFF80001C
i_emac_emac1 0xFF802000 0xFF80201C
i_emac_emac2 0xFF804000 0xFF80401C

Size: 32

Offset: 0x1C

Access: RW

Important: The value of a reserved bit must be maintained in software. When you modify registers containing reserved bit fields, you must use a read-modify-write operation to preserve state and prevent indeterminate system behavior.
Bit Fields
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16

reserved_31_20

RO 0x0

vthm

RO 0x0

esvl

RW 0x0

vtim

RW 0x0

etv

RW 0x0

15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0

vl

RW 0x0

gmacgrp_vlan_tag Fields

Bit Name Description Access Reset
31:20 reserved_31_20
Reserved
RO 0x0
19 vthm
VLAN Tag Hash Table Match Enable

When set, the most significant four bits of the VLAN tag's CRC are used to index the content of Register 354 (VLAN Hash Table Register). A value of 1 in the VLAN Hash Table register, corresponding to the index, indicates that the frame matched the VLAN hash table.

When Bit 16 (ETV) is set, the CRC of the 12-bit VLAN Identifier (VID) is used for comparison whereas when ETV is reset, the CRC of the 16-bit VLAN tag is used for comparison.

When reset, the VLAN Hash Match operation is not performed. If the VLAN Hash feature is not enabled during core configuration, this bit is reserved (RO with default value).
RO 0x0
18 esvl
Enable S-VLAN 

When this bit is set, the MAC transmitter and receiver also consider the S-VLAN (Type = 0x88A8) frames as valid VLAN tagged frames.
RW 0x0
17 vtim
VLAN Tag Inverse Match Enable

When set, this bit enables the VLAN Tag inverse matching. The frames that do not have matching VLAN Tag are marked as matched.

When reset, this bit enables the VLAN Tag perfect matching. The frames with matched VLAN Tag are marked as matched.
RW 0x0
16 etv
Enable 12-Bit VLAN Tag Comparison

When this bit is set, a 12-bit VLAN identifier is used for comparing and filtering instead of the complete 16-bit VLAN tag. Bits [11:0] of VLAN tag are compared with the corresponding field in the received VLAN-tagged frame. Similarly, when enabled, only 12 bits of the VLAN tag in the received frame are used for hash-based VLAN filtering. 

When this bit is reset, all 16 bits of the 15th and 16th bytes of the received VLAN frame are used for comparison and VLAN hash filtering.
Value Description
0x0 DISABLED
0x1 ENABLED
RW 0x0
15:0 vl
VLAN Tag Identifier for Receive Frames

This field contains the 802.1Q VLAN tag to identify the VLAN frames and is compared to the 15th and 16th bytes of the frames being received for VLAN frames. The following list describes the bits of this field:

 * Bits [15:13]: User Priority
 * Bit 12: Canonical Format Indicator (CFI) or Drop Eligible Indicator (DEI)
 * Bits[11:0]: VLAN tag's VLAN Identifier (VID) field 

When the ETV bit is set, only the VID (Bits[11:0]) is used for comparison. 
If VL (VL[11:0] if ETV is set) is all zeros, the MAC does not check the fifteenth and 16th bytes for VLAN tag comparison, and declares all frames with a Type field value of 0x8100 or 0x88a8 as VLAN frames.
RW 0x0