40- and 100-Gbps Ethernet MAC and PHY MegaCore Function User Guide

ID 683114
Date 6/15/2022
Public
Document Table of Contents

3.4.1.18. MAC Address Registers

All MAC addresses are stored in 2 words of 24 bits (3 bytes) in natural reading order. For example, an Altera Device ID of 00-07-ED-11-22-33 is stored with the more significant word set to 24’h0007ED and the least significant word set to 24’h112233.

The following table describes the MAC address registers. Additional information about the MADDR_CTRL register follows the table.

Table 63.  MAC Address Registers

Address

Name

Bit

Description

HW Reset Value

Access

0x140

MADDR_CTRL

[31]

When set to 1, the source address is Inserted in TX packets.

1’b0

RW

[30]

When set to 1, enables the IP core to check the destination address in RX packets. When set to 0, all RX packets are considered to have a matching destination address.

If you enable destination address filtering, by setting bit 0 of the RX_FILTER_CTRL register (offset 0x103) to the value of 0, but this bit, bit 30 of the MADDR_CTRL register, is also set to the value of 0, the IP core considers all destination addresses to match.

1’b0

RW

[29:1]

Reserved.

0x00000000

[0]

When set to 1, enables destination address 0x160-0x161 checking. If this bit has the value of 0 and bit 30 has the value of 1, the IP core considers all destination addresses to not match.

1’b0

RW

0x141

SRC_AD_LO

[23:0]

Source address (lower 24 bits).

0x00FF1234

RW

0x142

SRC_AD_HI

[23:0]

Source address (upper 24 bits).

0x000007ED

RW

0x160

DST_AD0_LO

[23:0]

Destination address 0 (lower 24 bits).

0x00000000

RW

0x161

DST_AD0_HI

[23:0]

Destination address 0 (upper 24 bits).

0x00000000

RW

0x162-0x17f

RESERVED

[31:0]

Reserved.

0x00000000

The MADDR_CTRL register bits 0 and 30 together with the RX_FILTER_CTRL register bit 0 (offset 0x103, Table 3–37 on page 3–59) control address checking as follows:

Table 64.  Destination Address Checking Behavior
RX_FILTER_CTRL[0] MADDR_CTRL[30] MADDR_CTRL[0]

Behavior

1

Promiscuous receive mode: IP core accepts frames regardless of destination address.

0

0

IP core treats all packets as if they have a matching address. (However, the IP core may filter packets based on other criteria).

1

0

IP core treats all packets as if they have a destination address that does not match (and therefore, accepts no packets).

1

1

IP core performs destination address checking and filters out packets whose destination address does not match the address specified in the DST_AD0_LO and DST_AD0_HI registers.