# Realtek RT5651 audio CODEC

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

> Device-tree binding reference for Realtek RT5651 audio CODEC.

<!-- 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;sound&#47;realtek&#44;rt5651&#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;Bard Liao &#60;bardliao&#64;realtek&#46;com&#62;&#34;</code></span>

<div id="dt-6d1c5ef59f0239d38c02">
<p style="white-space: pre-wrap">This device supports I2C only.
Pins on the device (for linking into audio routes) for RT5651:</p>
<pre><code>  * DMIC L1
  * DMIC R1
  * IN1P
  * IN2P
  * IN2N
  * IN3P
  * HPOL
  * HPOR
  * LOUTL
  * LOUTR
  * PDML
  * PDMR</code></pre>
</div>

<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>&#47;schemas&#47;sound&#47;dai&#45;common&#46;yaml&#35;</code>](</kernel/hardware/devicetree-bindings/dt-sound/dai-common.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

**Exact value (<code>const</code>):** <span id="dt-1765195bf8e86c3ccec6"><code>&#34;realtek&#44;rt5651&#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-4e9a371963ac013ad39d"></a>

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

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

<a id="dt-041d7cd76b652a5de06a"></a>

### <code>clock&#45;names</code> — not listed as required here

**Exact value (<code>const</code>):** <span id="dt-882f4571b4b135d59582"><code>&#34;mclk&#34;</code></span>

<a id="dt-4a22cdb1eade348ac0d4"></a>

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

**Exact value (<code>const</code>):** <span id="dt-06650c5e4c981bc2a500"><code>0</code></span>

<a id="dt-9681b0329408fb8ed998"></a>

### <code>realtek&#44;in2&#45;differential</code> — not listed as required here

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

<div id="dt-e5f6808f012d4deca22c">
<p style="white-space: pre-wrap">Indicate MIC2 input are differential, rather than single-ended.</p>
</div>

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

### <code>realtek&#44;dmic&#45;en</code> — not listed as required here

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

<div id="dt-2f7275d709ff9ca9806c">
<p style="white-space: pre-wrap">Indicates DMIC is used.</p>
</div>

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

### <code>realtek&#44;jack&#45;detect&#45;source</code> — not listed as required here

**Shared schema rule (<code>&#36;ref</code>):** <span id="dt-80a25b49f6bb7d570d12">[<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-8a7203d0d077c8d34597">
<p style="white-space: pre-wrap">Select jack-detect input pin.</p>
</div>

**Allowed values (<code>enum</code>):** <a id="dt-ab6f56166a8a638eebfc"></a> <span id="dt-44d811338a8737125587"><code>1</code></span>, <span id="dt-cb2159a4bf1d4889ac72"><code>2</code></span>, <span id="dt-6fdd170c48c264a83965"><code>3</code></span>

<a id="dt-0626984c35eb271b5314"></a>

### <code>realtek&#44;jack&#45;detect&#45;not&#45;inverted</code> — not listed as required here

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

<div id="dt-b84100990f94cf6fb03c">
<p style="white-space: pre-wrap">Normal jack-detect switches give an inverted (active-low) signal. Set this bool in the rare case you've a jack-detect switch which is not inverted.</p>
</div>

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

### <code>realtek&#44;over&#45;current&#45;threshold&#45;microamp</code> — not listed as required here

<div id="dt-9dbfceeeabf971de2681">
<p style="white-space: pre-wrap">Micbias over-current detection threshold in µA.</p>
</div>

**Allowed values (<code>enum</code>):** <a id="dt-9f413e08998f118cea4a"></a> <span id="dt-2d8ca8ca85d61b7d2296"><code>600</code></span>, <span id="dt-a868f74ad005042da789"><code>1500</code></span>, <span id="dt-86ae8dbbed0366b79085"><code>2000</code></span>

<a id="dt-9999a74e3b99e651f0fa"></a>

### <code>realtek&#44;over&#45;current&#45;scale&#45;factor</code> — not listed as required here

**Shared schema rule (<code>&#36;ref</code>):** <span id="dt-925bb0a2e9bc58f1bd11">[<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-44af22f80db06e1577a8">
<p style="white-space: pre-wrap">Micbias over-current detection scale factor:</p>
<pre><code>  0: scale current by 0.5
  1: scale current by 0.75
  2: scale current by 1.0
  3: scale current by 1.5</code></pre>
</div>

**Allowed values (<code>enum</code>):** <a id="dt-81067ba9e86f7e43adbc"></a> <span id="dt-cd9b30401d213dc6b4bd"><code>0</code></span>, <span id="dt-8d408f6b9b941c726044"><code>1</code></span>, <span id="dt-6037e91b4de0a9bf45f5"><code>2</code></span>, <span id="dt-0e480d8198b9c990735c"><code>3</code></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-738c4b4f9e483441138b"></a>

## Properties not matched by properties or patternProperties in this schema (<code>additionalProperties</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">i2c {
    #address-cells = &lt;1&gt;;
    #size-cells = &lt;0&gt;;
    codec@1a {
        compatible = "realtek,rt5651";
        reg = &lt;0x1a&gt;;
        realtek,dmic-en;
        realtek,in2-differential;
    };
};
</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>
