Cadence MACB/GEM Ethernet controller

Schema identifier ($id): "http://devicetree.org/schemas/net/cdns,macb.yaml#"

Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"

Maintainers (maintainers): "Nicolas Ferre <nicolas.ferre@microchip.com>", "Claudiu Beznea <claudiu.beznea@microchip.com>"

Properties and child nodes (properties) #

compatible — required here #

Exactly one of these rules must match (oneOf) #

Rule 1

Array item rules (items)

Item 1

Allowed values (enum): "cdns,at91rm9200-emac"

Item 2

Exact value (const): "cdns,emac"

Rule 2

Array item rules (items)

Item 1

Allowed values (enum): "cdns,zynq-gem", "cdns,zynqmp-gem"

Item 2

Exact value (const): "cdns,gem"

Deprecated (deprecated): true

Rule 3

Array item rules (items)

Item 1

Allowed values (enum): "xlnx,versal-gem", "xlnx,zynq-gem", "xlnx,zynqmp-gem"

Item 2

Exact value (const): "cdns,gem"

Rule 4

Array item rules (items)

Item 1

Allowed values (enum): "cdns,at91sam9260-macb", "cdns,sam9x60-macb", "microchip,mpfs-macb"

Item 2

Exact value (const): "cdns,macb"

Rule 5

Array item rules (items)

Item 1

Exact value (const): "microchip,pic64gx-macb"

Item 2

Exact value (const): "microchip,mpfs-macb"

Item 3

Exact value (const): "cdns,macb"

Rule 6

Array item rules (items)

Item 1

Allowed values (enum): "atmel,sama5d3-macb"

Item 2

Allowed values (enum): "cdns,at91sam9260-macb"

Item 3

Exact value (const): "cdns,macb"

Rule 7

Allowed values (enum): "atmel,sama5d2-gem", "atmel,sama5d29-gem", "atmel,sama5d3-gem", "atmel,sama5d4-gem", "cdns,emac", "cdns,gem", "cdns,macb", "cdns,np4-macb", "microchip,sama7g5-emac", "microchip,sama7g5-gem", "mobileye,eyeq5-gem", "raspberrypi,rp1-gem", "sifive,fu540-c000-gem"

Rule 8

Array item rules (items)

Item 1

Allowed values (enum): "microchip,sam9x7-gem", "microchip,sama7d65-gem"

Item 2

Exact value (const): "microchip,sama7g5-gem"

reg — required here #

Minimum number of items (minItems): 1

Array item rules (items) #

Item 1

Basic register set

Item 2

GEMGXL Management block registers on SiFive FU540-C000 SoC

interrupts — required here #

Minimum number of items (minItems): 1

Maximum number of items (maxItems): 8

One interrupt per available hardware queue

clocks — required here #

Minimum number of items (minItems): 1

Maximum number of items (maxItems): 5

clock-names — required here #

Minimum number of items (minItems): 1

Array item rules (items) #

Item 1

Allowed values (enum): "ether_clk", "hclk", "pclk"

Item 2

Allowed values (enum): "hclk", "pclk"

Item 3

Allowed values (enum): "tx_clk", "tsu_clk"

Item 4

Allowed values (enum): "rx_clk", "tsu_clk"

Item 5

Exact value (const): "tsu_clk"

local-mac-address — not listed as required here #

true — No constraints added by this property rule.

phy-mode — required here #

true — No constraints added by this property rule.

phy-handle — not listed as required here #

true — No constraints added by this property rule.

phys — not listed as required here #

Maximum number of items (maxItems): 1

resets — not listed as required here #

Maximum number of items (maxItems): 1

Recommended with ZynqMP, specify reset control for this controller instance with zynqmp-reset driver.

reset-names — not listed as required here #

Maximum number of items (maxItems): 1

true — No constraints added by this property rule.

iommus — not listed as required here #

Maximum number of items (maxItems): 1

power-domains — not listed as required here #

Maximum number of items (maxItems): 1

cdns,refclk-ext — not listed as required here #

Value type (type): "boolean"

This selects if the REFCLK for RMII is provided by an external source. For RGMII mode this selects if the 125MHz REF clock is provided by an external source.

cdns,rx-watermark — not listed as required here #

Shared schema rule ($ref): /schemas/types.yaml#/definitions/uint32

When the receive partial store and forward mode is activated, the receiver will only begin to forward the packet to the external AHB or AXI slave when enough packet data is stored in the SRAM packet buffer. rx-watermark corresponds to the number of SRAM buffer locations, that need to be filled, before the forwarding process is activated. Width of the SRAM is platform dependent, and can be 4, 8 or 16 bytes.

#address-cells — not listed as required here #

Exact value (const): 1

#size-cells — not listed as required here #

Exact value (const): 0

mdio — not listed as required here #

Value type (type): "object"

Node containing PHY children. If this node is not present, then PHYs will be direct children.

Properties matching a name pattern (patternProperties) #

^ethernet-phy@[0-9a-f]$ — name matches this regular expression #

Value type (type): "object"

Shared schema rule ($ref): ethernet-phy.yaml#

Properties and child nodes (properties) #

reset-gpios — not listed as required here

true — No constraints added by this property rule.

magic-packet — not listed as required here

Value type (type): "boolean"

Deprecated (deprecated): true

Indicates that the hardware supports waking up via magic packet.

Properties not evaluated by applicable rules (unevaluatedProperties) #

false

Not allowed by this rule.

Required in this object (required): "compatible", "reg", "interrupts", "clocks", "clock-names", "phy-mode"

All of these rules must match (allOf) #

Rule 1 #

Shared schema rule ($ref): ethernet-controller.yaml#

Rule 2 #

Condition (if) #

This rule must not match (not)

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Exact value (const): "sifive,fu540-c000-gem"

When the condition matches (then) #

Properties and child nodes (properties)

reg — not listed as required here

Maximum number of items (maxItems): 1

Rule 3 #

Condition (if) #

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Exact value (const): "mobileye,eyeq5-gem"

When the condition matches (then) #

Required in this object (required): "phys"

Properties not evaluated by applicable rules (unevaluatedProperties) #

false

Not allowed by this rule.

Examples (examples) #

macb0: ethernet@fffc4000 {
        compatible = "cdns,macb";
        reg = <0xfffc4000 0x4000>;
        interrupts = <21>;
        cdns,rx-watermark = <0x44>;
        phy-mode = "rmii";
        local-mac-address = [3a 0e 03 04 05 06];
        clock-names = "pclk", "hclk", "tx_clk";
        clocks = <&clkc 30>, <&clkc 30>, <&clkc 13>;
        #address-cells = <1>;
        #size-cells = <0>;

        ethernet-phy@1 {
                reg = <0x1>;
                reset-gpios = <&pioE 6 1>;
        };
};
#include <dt-bindings/power/xlnx-zynqmp-power.h>
#include <dt-bindings/reset/xlnx-zynqmp-resets.h>
#include <dt-bindings/phy/phy.h>

bus {
        #address-cells = <2>;
        #size-cells = <2>;
        gem1: ethernet@ff0c0000 {
                compatible = "xlnx,zynqmp-gem", "cdns,gem";
                interrupt-parent = <&gic>;
                interrupts = <0 59 4>, <0 59 4>;
                reg = <0x0 0xff0c0000 0x0 0x1000>;
                clocks = <&zynqmp_clk 31>, <&zynqmp_clk 105>,
                         <&zynqmp_clk 51>, <&zynqmp_clk 50>,
                         <&zynqmp_clk 44>;
                clock-names = "pclk", "hclk", "tx_clk", "rx_clk", "tsu_clk";
                #address-cells = <1>;
                #size-cells = <0>;
                iommus = <&smmu 0x875>;
                power-domains = <&zynqmp_firmware PD_ETH_1>;
                resets = <&zynqmp_reset ZYNQMP_RESET_GEM1>;
                reset-names = "gem1_rst";
                phy-mode = "sgmii";
                phys = <&psgtr 1 PHY_TYPE_SGMII 1 1>;
                fixed-link {
                        speed = <1000>;
                        full-duplex;
                        pause;
                };
        };
};

Source notes #

Annotations retained from the schema source

Line 1: SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)

Line 18: Atmel at91rm9200 SoC

Line 19: Generic

Line 23: Xilinx Zynq-7xxx SoC

Line 24: Xilinx Zynq Ultrascale+ MPSoC

Line 25: Generic

Line 30: Xilinx Versal

Line 31: Xilinx Zynq-7xxx SoC

Line 32: Xilinx Zynq Ultrascale+ MPSoC

Line 33: Generic

Line 37: Atmel at91sam9 SoCs

Line 38: Microchip sam9x60 SoC

Line 39: Microchip PolarFire SoC

Line 40: Generic

Line 42: Microchip PIC64GX SoC

Line 43: Microchip PolarFire SoC

Line 44: Generic

Line 47: 10/100Mbit IP on Atmel sama5d3 SoCs

Line 49: Atmel at91sam9 SoCs.

Line 50: Generic

Line 53: GEM IP (10/100) on Atmel sama5d2 SoCs

Line 54: GEM XL IP (10/100) on Atmel sama5d29 SoCs

Line 55: Gigabit IP on Atmel sama5d3 SoCs

Line 56: GEM IP (10/100) on Atmel sama5d4 SoCs

Line 57: Generic

Line 58: Generic

Line 59: Generic

Line 60: NP4 SoC devices

Line 61: Microchip SAMA7G5 ethernet interface

Line 62: Microchip SAMA7G5 gigabit ethernet interface

Line 63: Mobileye EyeQ5 SoCs

Line 64: Raspberry Pi RP1 gigabit ethernet interface

Line 65: SiFive FU540-C000 SoC

Line 69: Microchip SAM9X7 gigabit ethernet interface

Line 70: Microchip SAMA7D65 gigabit ethernet interface

Line 71: Microchip SAMA7G5 gigabit ethernet interface

Edit this page