# Marvell MV88E6xxx DSA switch family

_Peios Kernel / Hardware and drivers / Device-tree binding reference / Network bindings / dsa_

> Device-tree binding reference for Marvell MV88E6xxx DSA switch family.

<!-- SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) -->


<a id="dt-root"></a>

**Schema identifier (<code>&#36;id</code>):** <span id="dt-09f478f44eb202ea573e"><code>&#34;http&#58;&#47;&#47;devicetree&#46;org&#47;schemas&#47;net&#47;dsa&#47;marvell&#44;mv88e6xxx&#46;yaml&#35;&#34;</code></span>

**Schema dialect (<code>&#36;schema</code>):** <span id="dt-dcb375baab6014763a68"><code>&#34;http&#58;&#47;&#47;devicetree&#46;org&#47;meta&#45;schemas&#47;core&#46;yaml&#35;&#34;</code></span>

<a id="dt-e46b5a5dd81dbd751c9f"></a>

**Maintainers (<code>maintainers</code>):** <a id="dt-fbc39820abb8bb999095"></a> <span id="dt-fb78ddfc22abfc6fe56d"><code>&#34;Andrew Lunn &#60;andrew&#64;lunn&#46;ch&#62;&#34;</code></span>

<div id="dt-6d1c5ef59f0239d38c02">
<p style="white-space: pre-wrap">The Marvell MV88E6xxx switch series has been produced and sold by Marvell since at least 2008. The switch has a few compatibles which just indicate the base address of the switch, then operating systems can investigate switch ID registers to find out which actual version of the switch it is dealing with.</p>
</div>

<a id="dt-e1f655ed0ff4d595dadc"></a>

## Properties and child nodes (<code>properties</code>)

<a id="dt-5c1d81699dcbe840de83"></a>

### <code>compatible</code> — required here

<a id="dt-39566f01414e34c67b85"></a>

#### Exactly one of these rules must match (<code>oneOf</code>)

<a id="dt-fe13e24e5c9612880f47"></a>

**Rule 1**

> **Allowed values (<code>enum</code>):** <a id="dt-617e1a2040e2496013d4"></a> <span id="dt-c31075c43df89b2793e3"><code>&#34;marvell&#44;mv88e6085&#34;</code></span>, <span id="dt-44b402f75e7bf3caf313"><code>&#34;marvell&#44;mv88e6190&#34;</code></span>, <span id="dt-f03e1478792ca587ff5c"><code>&#34;marvell&#44;mv88e6250&#34;</code></span>
>
> <div id="dt-ab1c3e7063bd95dc962e">
> <pre><code>marvell,mv88e6085: This switch uses base address 0x10.
>   This switch and its siblings will be autodetected from
>   ID registers found in the switch, so only "marvell,mv88e6085" should be
>   specified. This includes the following list of MV88Exxxx switches:
>   6085, 6095, 6097, 6123, 6131, 6141, 6161, 6165, 6171, 6172, 6175, 6176,
>   6185, 6240, 6320, 6321, 6341, 6350, 6351, 6352
> marvell,mv88e6190: This switch uses base address 0x00.
>   This switch and its siblings will be autodetected from
>   ID registers found in the switch, so only "marvell,mv88e6190" should be
>   specified. This includes the following list of MV88Exxxx switches:
>   6190, 6190X, 6191, 6290, 6361, 6390, 6390X
> marvell,mv88e6250: This switch uses base address 0x08 or 0x18.
>   This switch and its siblings will be autodetected from
>   ID registers found in the switch, so only "marvell,mv88e6250" should be
>   specified. This includes the following list of MV88Exxxx switches:
>   6220, 6250</code></pre>
> </div>

<a id="dt-7482b6e745c4f056161a"></a>

**Rule 2**

> <a id="dt-4c3e118873fbaedb5de2"></a>
>
> **Array item rules (<code>items</code>)**
>
> <a id="dt-b02d8860067795c00ae4"></a>
>
> **Item 1**
>
> > **Exact value (<code>const</code>):** <span id="dt-82dceb5784ff71f5fdf5"><code>&#34;marvell&#44;turris&#45;mox&#45;mv88e6085&#34;</code></span>
>
> <a id="dt-bdc26de0ccb1d52bb6a4"></a>
>
> **Item 2**
>
> > **Exact value (<code>const</code>):** <span id="dt-cc26fa5d96bc7cf0a818"><code>&#34;marvell&#44;mv88e6085&#34;</code></span>

<a id="dt-39cb5b72c94e12bd53ea"></a>

**Rule 3**

> <a id="dt-e626d61e9d5d76cc48f9"></a>
>
> **Array item rules (<code>items</code>)**
>
> <a id="dt-6b46935eab08de6d1f0a"></a>
>
> **Item 1**
>
> > **Exact value (<code>const</code>):** <span id="dt-b4cf31a5f463012e1429"><code>&#34;marvell&#44;turris&#45;mox&#45;mv88e6190&#34;</code></span>
>
> <a id="dt-5ea82ea034747ba6da29"></a>
>
> **Item 2**
>
> > **Exact value (<code>const</code>):** <span id="dt-e9c55cb91230c7ee5a28"><code>&#34;marvell&#44;mv88e6190&#34;</code></span>

<a id="dt-9c1635fdb65d87e33d77"></a>

### <code>reg</code> — required here

**Maximum number of items (<code>maxItems</code>):** <span id="dt-71421d35675d9a533ad2"><code>1</code></span>

<a id="dt-883702bde41372a2a2c5"></a>

### <code>eeprom&#45;length</code> — not listed as required here

**Shared schema rule (<code>&#36;ref</code>):** <span id="dt-cc880ee33bbfecc1c457">[<code>&#47;schemas&#47;types&#46;yaml&#35;&#47;definitions&#47;uint32</code>](</kernel/hardware/devicetree-bindings/dt-shared/types.md#dt-d57795d6573ee5d67d37>)</span>

<div id="dt-0cb7613d77f96a249be3">
<p style="white-space: pre-wrap">Set to the length of an EEPROM connected to the switch. Must be set if the switch can not detect the presence and/or size of a connected EEPROM, otherwise optional.</p>
</div>

<a id="dt-fdf18029f1f43a541a62"></a>

### <code>reset&#45;gpios</code> — not listed as required here

<div id="dt-451564af2b6998692dea">
<p style="white-space: pre-wrap">GPIO to be used to reset the whole device</p>
</div>

**Maximum number of items (<code>maxItems</code>):** <span id="dt-140c9736042c6903f7ff"><code>1</code></span>

<a id="dt-c2de09e7f7fd211b679d"></a>

### <code>interrupts</code> — not listed as required here

<div id="dt-b3ddec0f69e9f0c0dc40">
<p style="white-space: pre-wrap">The switch provides an external interrupt line, but it is not always used by target systems.</p>
</div>

**Maximum number of items (<code>maxItems</code>):** <span id="dt-b7823fb65b2f27642d26"><code>1</code></span>

<a id="dt-b98252f9c39642b1db8f"></a>

### <code>interrupt&#45;controller</code> — not listed as required here

<div id="dt-a1941b3c575a7b0aef84">
<p style="white-space: pre-wrap">The switch has an internal interrupt controller used by the different sub-blocks.</p>
</div>

<a id="dt-8586fac2d9a71adf4795"></a>

### <code>&#35;interrupt&#45;cells</code> — not listed as required here

<div id="dt-0cc2c51365b6879fba3b">
<p style="white-space: pre-wrap">The internal interrupt controller only supports triggering on active high level interrupts so the second cell must always be set to IRQ_TYPE_LEVEL_HIGH.</p>
</div>

**Exact value (<code>const</code>):** <span id="dt-317bbf786489389e8233"><code>2</code></span>

<a id="dt-61fd0c6095df05615feb"></a>

### <code>mdio</code> — not listed as required here

**Shared schema rule (<code>&#36;ref</code>):** <span id="dt-980b6ef0e51b942a4596">[<code>&#47;schemas&#47;net&#47;mdio&#46;yaml&#35;</code>](</kernel/hardware/devicetree-bindings/dt-net/mdio.md#dt-root>)</span>

<a id="dt-3293bd7c0139f521bb91"></a>

#### Properties not evaluated by applicable rules (<code>unevaluatedProperties</code>)

<code>false</code>

Not allowed by this rule.

<div id="dt-b86f745d7bfe1958a20c">
<p style="white-space: pre-wrap">Marvell MV88E6xxx switches have an varying combination of internal and external MDIO buses, in some cases a combined bus that can be used both internally and externally. This node is for the primary bus, used internally and sometimes also externally.</p>
</div>

<a id="dt-55880d4b722d065e3901"></a>

### <code>mdio&#45;external</code> — not listed as required here

**Shared schema rule (<code>&#36;ref</code>):** <span id="dt-dbf95caf0b8e37a0c1b6">[<code>&#47;schemas&#47;net&#47;mdio&#46;yaml&#35;</code>](</kernel/hardware/devicetree-bindings/dt-net/mdio.md#dt-root>)</span>

<a id="dt-29472542b4dc3f6257b4"></a>

#### Properties not evaluated by applicable rules (<code>unevaluatedProperties</code>)

<code>false</code>

Not allowed by this rule.

<div id="dt-411a6b23024759b8ed0a">
<p style="white-space: pre-wrap">Marvell MV88E6xxx switches that have a separate external MDIO bus use this port to access external components on the MDIO bus.</p>
</div>

<a id="dt-c0c92edb2b08ccb94879"></a>

#### Properties and child nodes (<code>properties</code>)

<a id="dt-aec0d24e8184f30b5b7c"></a>

**<code>compatible</code> — required here**

**Exact value (<code>const</code>):** <span id="dt-9b73b94a2b705eaa8cf9"><code>&#34;marvell&#44;mv88e6xxx&#45;mdio&#45;external&#34;</code></span>

**Required in this object (<code>required</code>):** <a id="dt-09b61c065f51e8c15677"></a> <span id="dt-4a2b8d44064a83fc90d8"><code>&#34;compatible&#34;</code></span>

<a id="dt-935ee547587f3e75de61"></a>

## All of these rules must match (<code>allOf</code>)

<a id="dt-d33de94ac1d3652cd22a"></a>

### Rule 1

> **Shared schema rule (<code>&#36;ref</code>):** <span id="dt-95c8874f25311f4b1ab1">[<code>dsa&#46;yaml&#35;&#47;&#36;defs&#47;ethernet&#45;ports</code>](</kernel/hardware/devicetree-bindings/dt-net/dsa/dsa.md#dt-902a57891fd19db703ff>)</span>

**Required in this object (<code>required</code>):** <a id="dt-8313173ff1c9b300d560"></a> <span id="dt-048b70ee865d6847aa3d"><code>&#34;compatible&#34;</code></span>, <span id="dt-ee7433925c1528c16b99"><code>&#34;reg&#34;</code></span>

<a id="dt-63ab525a9812ac23c446"></a>

## Properties not evaluated by applicable rules (<code>unevaluatedProperties</code>)

<code>false</code>

Not allowed by this rule.

<a id="dt-1a130cabaa8a47b058bf"></a>

## Examples (<code>examples</code>)

<pre id="dt-0bd6510295af0c95ff2d"><code class="language-dts">#include &lt;dt-bindings/gpio/gpio.h&gt;
mdio {
    #address-cells = &lt;1&gt;;
    #size-cells = &lt;0&gt;;

    ethernet-switch@0 {
        compatible = "marvell,mv88e6085";
        reg = &lt;0&gt;;
        reset-gpios = &lt;&amp;gpio5 1 GPIO_ACTIVE_LOW&gt;;

        mdio {
            #address-cells = &lt;1&gt;;
            #size-cells = &lt;0&gt;;

            sw_phy0: ethernet-phy@0 {
                reg = &lt;0x0&gt;;
            };

            sw_phy1: ethernet-phy@1 {
                reg = &lt;0x1&gt;;
            };

            sw_phy2: ethernet-phy@2 {
                reg = &lt;0x2&gt;;
            };

            sw_phy3: ethernet-phy@3 {
                reg = &lt;0x3&gt;;
            };
        };

        ethernet-ports {
            #address-cells = &lt;1&gt;;
            #size-cells = &lt;0&gt;;

            ethernet-port@0 {
                reg = &lt;0&gt;;
                label = "lan4";
                phy-handle = &lt;&amp;sw_phy0&gt;;
                phy-mode = "internal";
            };

            ethernet-port@1 {
                reg = &lt;1&gt;;
                label = "lan3";
                phy-handle = &lt;&amp;sw_phy1&gt;;
                phy-mode = "internal";
            };

            ethernet-port@2 {
                reg = &lt;2&gt;;
                label = "lan2";
                phy-handle = &lt;&amp;sw_phy2&gt;;
                phy-mode = "internal";
            };

            ethernet-port@3 {
                reg = &lt;3&gt;;
                label = "lan1";
                phy-handle = &lt;&amp;sw_phy3&gt;;
                phy-mode = "internal";
            };

            ethernet-port@5 {
                reg = &lt;5&gt;;
                ethernet = &lt;&amp;fec&gt;;
                phy-mode = "rgmii-id";

                fixed-link {
                    speed = &lt;1000&gt;;
                    full-duplex;
                };
            };
        };
    };
};
</code></pre>

<pre id="dt-bae0d43ea48e35208b4a"><code class="language-dts">#include &lt;dt-bindings/interrupt-controller/irq.h&gt;
mdio {
    #address-cells = &lt;1&gt;;
    #size-cells = &lt;0&gt;;

    ethernet-switch@0 {
        compatible = "marvell,mv88e6190";
        #interrupt-cells = &lt;2&gt;;
        interrupt-controller;
        interrupt-parent = &lt;&amp;gpio1&gt;;
        interrupts = &lt;7 IRQ_TYPE_LEVEL_LOW&gt;;
        pinctrl-0 = &lt;&amp;switch_interrupt_pins&gt;;
        pinctrl-names = "default";
        reg = &lt;0&gt;;

        mdio {
            #address-cells = &lt;1&gt;;
            #size-cells = &lt;0&gt;;

            switch0phy1: ethernet-phy@1 {
                reg = &lt;0x1&gt;;
            };

            switch0phy2: ethernet-phy@2 {
                reg = &lt;0x2&gt;;
            };

            switch0phy3: ethernet-phy@3 {
                reg = &lt;0x3&gt;;
            };

            switch0phy4: ethernet-phy@4 {
                reg = &lt;0x4&gt;;
            };

            switch0phy5: ethernet-phy@5 {
                reg = &lt;0x5&gt;;
            };

            switch0phy6: ethernet-phy@6 {
                reg = &lt;0x6&gt;;
            };

            switch0phy7: ethernet-phy@7 {
                reg = &lt;0x7&gt;;
            };

            switch0phy8: ethernet-phy@8 {
                reg = &lt;0x8&gt;;
            };
        };

        mdio-external {
            compatible = "marvell,mv88e6xxx-mdio-external";
            #address-cells = &lt;1&gt;;
            #size-cells = &lt;0&gt;;

            phy1: ethernet-phy@b {
                reg = &lt;0xb&gt;;
                compatible = "ethernet-phy-ieee802.3-c45";
            };

            phy2: ethernet-phy@c {
                reg = &lt;0xc&gt;;
                compatible = "ethernet-phy-ieee802.3-c45";
            };
        };

        ethernet-ports {
            #address-cells = &lt;1&gt;;
            #size-cells = &lt;0&gt;;

            ethernet-port@0 {
                ethernet = &lt;&amp;eth0&gt;;
                phy-mode = "rgmii";
                reg = &lt;0&gt;;

                fixed-link {
                    full-duplex;
                    pause;
                    speed = &lt;1000&gt;;
                };
            };

            ethernet-port@1 {
                label = "lan1";
                phy-handle = &lt;&amp;switch0phy1&gt;;
                reg = &lt;1&gt;;
            };

            ethernet-port@2 {
                label = "lan2";
                phy-handle = &lt;&amp;switch0phy2&gt;;
                reg = &lt;2&gt;;
            };

            ethernet-port@3 {
                label = "lan3";
                phy-handle = &lt;&amp;switch0phy3&gt;;
                reg = &lt;3&gt;;
            };

            ethernet-port@4 {
                label = "lan4";
                phy-handle = &lt;&amp;switch0phy4&gt;;
                reg = &lt;4&gt;;
            };

            ethernet-port@5 {
                label = "lan5";
                phy-handle = &lt;&amp;switch0phy5&gt;;
                reg = &lt;5&gt;;
            };

            ethernet-port@6 {
                label = "lan6";
                phy-handle = &lt;&amp;switch0phy6&gt;;
                reg = &lt;6&gt;;
            };

            ethernet-port@7 {
                label = "lan7";
                phy-handle = &lt;&amp;switch0phy7&gt;;
                reg = &lt;7&gt;;
            };

            ethernet-port@8 {
                label = "lan8";
                phy-handle = &lt;&amp;switch0phy8&gt;;
                reg = &lt;8&gt;;
            };

            ethernet-port@9 {
                /* 88X3310P external phy */
                label = "lan9";
                phy-handle = &lt;&amp;phy1&gt;;
                phy-mode = "xaui";
                reg = &lt;9&gt;;
            };

            ethernet-port@a {
                /* 88X3310P external phy */
                label = "lan10";
                phy-handle = &lt;&amp;phy2&gt;;
                phy-mode = "xaui";
                reg = &lt;0xa&gt;;
            };
        };
    };
};
</code></pre>

## Source notes

<details>
<summary>Annotations retained from the schema source</summary>

<p id="dt-comment-0"><strong>Line 1:</strong> <span> SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)</span></p>

</details>
