# Qualcomm QCA807x Ethernet PHY

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

> Device-tree binding reference for Qualcomm QCA807x Ethernet PHY.

<!-- 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;qcom&#44;qca807x&#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;Christian Marangi &#60;ansuelsmth&#64;gmail&#46;com&#62;&#34;</code></span>, <span id="dt-0f999bb9185dbf6b58d8"><code>&#34;Robert Marko &#60;robert&#46;marko&#64;sartura&#46;hr&#62;&#34;</code></span>

<div id="dt-6d1c5ef59f0239d38c02">
<p style="white-space: pre-wrap">Qualcomm QCA8072/5 Ethernet PHY is PHY package of 2 or 5
IEEE 802.3 clause 22 compliant 10BASE-Te, 100BASE-TX and
1000BASE-T PHY-s.</p>
<p style="white-space: pre-wrap">They feature 2 SerDes, one for PSGMII or QSGMII connection with
MAC, while second one is SGMII for connection to MAC or fiber.</p>
<p style="white-space: pre-wrap">Both models have a combo port that supports 1000BASE-X and
100BASE-FX fiber.</p>
<p style="white-space: pre-wrap">Each PHY inside of QCA807x series has 4 digitally controlled
output only pins that natively drive LED-s for up to 2 attached
LEDs. Some vendor also use these 4 output for GPIO usage without
attaching LEDs.</p>
<p style="white-space: pre-wrap">Note that output pins can be set to drive LEDs OR GPIO, mixed
definition are not accepted.</p>
</div>

**Shared schema rule (<code>&#36;ref</code>):** <span id="dt-d5c57c22d966a033492b">[<code>ethernet&#45;phy&#45;package&#46;yaml&#35;</code>](</kernel/hardware/devicetree-bindings/dt-net/ethernet-phy-package.md#dt-root>)</span>

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

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

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

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

**Allowed values (<code>enum</code>):** <a id="dt-207128c21dbd6355c894"></a> <span id="dt-bd234eb96375d77ca611"><code>&#34;qcom&#44;qca8072&#45;package&#34;</code></span>, <span id="dt-0d17ba1dd2e75413f7d4"><code>&#34;qcom&#44;qca8075&#45;package&#34;</code></span>

<a id="dt-8fa2f155934d0dd2d554"></a>

### <code>qcom&#44;package&#45;mode</code> — not listed as required here

<div id="dt-1d2b1db8870dca8f04af">
<p style="white-space: pre-wrap">PHY package can be configured in 3 mode following this table:</p>
<pre><code>              First Serdes mode       Second Serdes mode
Option 1      PSGMII for copper       Disabled
              ports 0-4
Option 2      PSGMII for copper       1000BASE-X / 100BASE-FX
              ports 0-4
Option 3      QSGMII for copper       SGMII for
              ports 0-3               copper port 4</code></pre>
<p style="white-space: pre-wrap">PSGMII mode (option 1 or 2) is configured dynamically based on
the presence of a connected SFP device.</p>
</div>

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

**Allowed values (<code>enum</code>):** <a id="dt-be328be1a9a57a9f4cf0"></a> <span id="dt-171eeb2c9be133beb99e"><code>&#34;qsgmii&#34;</code></span>, <span id="dt-2d13bf6ed5f4ee8dacc8"><code>&#34;psgmii&#34;</code></span>

**Default value (<code>default</code>):** <span id="dt-1a7c3d04ec199d34b10c"><code>&#34;psgmii&#34;</code></span>

<a id="dt-6bae0aac6bf258905d35"></a>

### <code>qcom&#44;tx&#45;drive&#45;strength&#45;milliwatt</code> — not listed as required here

<div id="dt-276042eec0b707515ccd">
<p style="white-space: pre-wrap">set the TX Amplifier value in mv.</p>
</div>

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

**Allowed values (<code>enum</code>):** <a id="dt-afbacc9fcaa9351daf2d"></a> <span id="dt-a63013b2906b241f440c"><code>140</code></span>, <span id="dt-a3b671681d3a6a99b6a4"><code>160</code></span>, <span id="dt-28cf27bd4879d862cd24"><code>180</code></span>, <span id="dt-e5940106cf078ebb4cfc"><code>200</code></span>, <span id="dt-7cce94cc6329f3257871"><code>220</code></span>, <span id="dt-82284e5883a1d69e5bdf"><code>240</code></span>, <span id="dt-5035fe5201dd7ca741d4"><code>260</code></span>, <span id="dt-50d6ef25b985ba979074"><code>280</code></span>, <span id="dt-ce8282d32e4e036492f7"><code>300</code></span>, <span id="dt-ba21b0d67286c1bcb389"><code>320</code></span>, <span id="dt-5c1311f479bce25bd5f7"><code>400</code></span>, <span id="dt-9a6dc92ed266e8ce4181"><code>500</code></span>, <span id="dt-c965b389b01464bd146b"><code>600</code></span>

**Default value (<code>default</code>):** <span id="dt-e7378a39628692aa4c39"><code>600</code></span>

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

## Properties matching a name pattern (<code>patternProperties</code>)

<a id="dt-36c875e2ba33beef6930"></a>

### <code>&#94;ethernet&#45;phy&#64;&#91;a&#45;f0&#45;9&#93;&#43;&#36;</code> — name matches this regular expression

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

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

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

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

**<code>qcom&#44;dac&#45;full&#45;amplitude</code> — not listed as required here**

<div id="dt-fe2b0a9219c4b4465f5e">
<p style="white-space: pre-wrap">Set Analog MDI driver amplitude to FULL.
With this not defined, amplitude is set to DSP. (amplitude is adjusted based on cable length)
With this enabled and qcom,dac-full-bias-current and qcom,dac-disable-bias-current-tweak disabled, bias current is half.</p>
</div>

**Value type (<code>type</code>):** <span id="dt-8753cca2c8756acb673b"><code>&#34;boolean&#34;</code></span>

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

**<code>qcom&#44;dac&#45;full&#45;bias&#45;current</code> — not listed as required here**

<div id="dt-5dae77c2c4e461775ce4">
<p style="white-space: pre-wrap">Set Analog MDI driver bias current to FULL.
With this not defined, bias current is set to DSP. (bias current is adjusted based on cable length)
Actual bias current might be different with qcom,dac-disable-bias-current-tweak disabled.</p>
</div>

**Value type (<code>type</code>):** <span id="dt-dac13d785b3e00e294b9"><code>&#34;boolean&#34;</code></span>

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

**<code>qcom&#44;dac&#45;disable&#45;bias&#45;current&#45;tweak</code> — not listed as required here**

<div id="dt-17953a423f43ca3d2364">
<p style="white-space: pre-wrap">Set Analog MDI driver bias current to disable tweak
to bias current.</p>
<p style="white-space: pre-wrap">With this not defined, bias current tweak are enabled
by default.</p>
<pre><code>With this enabled the following tweak are NOT applied:
- With both FULL amplitude and FULL bias current: bias current
  is set to half.
- With only DSP amplitude: bias current is set to half and
  is set to 1/4 with cable &lt; 10m.
- With DSP bias current (included both DSP amplitude and
  DSP bias current): bias current is half the detected current
  with cable &lt; 10m.</code></pre>
</div>

**Value type (<code>type</code>):** <span id="dt-1b4f1762d52c5cf4ad09"><code>&#34;boolean&#34;</code></span>

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

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

<code>true</code> — No constraints added by this property rule.

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

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

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

<a id="dt-0312a0a7b2ec336a311a"></a>

#### Condition (<code>if</code>)

> **Required in this object (<code>required</code>):** <a id="dt-9d5e392bee5212a08b4f"></a> <span id="dt-3a15b9d4872a3c0b993c"><code>&#34;gpio&#45;controller&#34;</code></span>

<a id="dt-85f27ca7462680033177"></a>

#### When the condition matches (<code>then</code>)

> <a id="dt-8682ab29f4ae7855154a"></a>
>
> **Properties and child nodes (<code>properties</code>)**
>
> <a id="dt-f232cc218584804dcc31"></a>
>
> **<code>leds</code> — not listed as required here**
>
> <code>false</code> — Not permitted by this property rule.

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

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

<code>false</code>

Not allowed by this rule.

**Required in this object (<code>required</code>):** <a id="dt-8313173ff1c9b300d560"></a> <span id="dt-048b70ee865d6847aa3d"><code>&#34;compatible&#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/leds/common.h&gt;

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

    ethernet-phy-package@0 {
        #address-cells = &lt;1&gt;;
        #size-cells = &lt;0&gt;;
        compatible = "qcom,qca8075-package";
        reg = &lt;0&gt;;

        qcom,package-mode = "qsgmii";

        ethernet-phy@0 {
            reg = &lt;0&gt;;

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

                led@0 {
                    reg = &lt;0&gt;;
                    color = &lt;LED_COLOR_ID_GREEN&gt;;
                    function = LED_FUNCTION_LAN;
                    default-state = "keep";
                };
            };
        };

        ethernet-phy@1 {
            reg = &lt;1&gt;;
        };

        ethernet-phy@2 {
            reg = &lt;2&gt;;

            gpio-controller;
            #gpio-cells = &lt;2&gt;;
        };

        ethernet-phy@3 {
            reg = &lt;3&gt;;
        };

        ethernet-phy@4 {
            reg = &lt;4&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>
