# Google SC7280-Herobrine ASoC sound card driver

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

> Device-tree binding reference for Google SC7280-Herobrine ASoC sound card driver.

<!-- 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;google&#44;sc7280&#45;herobrine&#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;Judy Hsiao &#60;judyhsiao&#64;chromium&#46;org&#62;&#34;</code></span>

<div id="dt-6d1c5ef59f0239d38c02">
<p style="white-space: pre-wrap">This binding describes the SC7280 sound card which uses LPASS for audio.</p>
</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>sound&#45;card&#45;common&#46;yaml&#35;</code>](</kernel/hardware/devicetree-bindings/dt-sound/sound-card-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

**Allowed values (<code>enum</code>):** <a id="dt-207128c21dbd6355c894"></a> <span id="dt-bd234eb96375d77ca611"><code>&#34;google&#44;sc7280&#45;herobrine&#34;</code></span>

<a id="dt-2efe70314a961a652abe"></a>

### <code>&#35;address&#45;cells</code> — required here

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

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

### <code>&#35;size&#45;cells</code> — required here

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

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

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

<a id="dt-69b595deb9397f5735fe"></a>

### <code>&#94;dai&#45;link&#64;&#91;0&#45;9a&#45;f&#93;&#36;</code> — name matches this regular expression

<div id="dt-72941e04f840c5217809">
<p style="white-space: pre-wrap">Each subnode represents a dai link. Subnodes of each dai links would be cpu/codec dais.</p>
</div>

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

<a id="dt-66efe4743561b7ad6f28"></a>

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

<a id="dt-3f0797849a27a6409caf"></a>

**<code>link&#45;name</code> — required here**

<div id="dt-a65023459673639d6a46">
<p style="white-space: pre-wrap">Indicates dai-link name and PCM stream name.</p>
</div>

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

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

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

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

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

<div id="dt-14894401a863327af699">
<p style="white-space: pre-wrap">dai link address.</p>
</div>

<a id="dt-217ddcfa1dafcefe6227"></a>

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

<div id="dt-23b0700c7d0aaa3a8062">
<p style="white-space: pre-wrap">Holds subnode which indicates cpu dai.</p>
</div>

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

<a id="dt-0b9107a78669902063f0"></a>

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

<a id="dt-566d39f66a1e7dd7217b"></a>

**<code>sound&#45;dai</code> — required here**

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

**Required in this object (<code>required</code>):** <a id="dt-60b25b26bb1373c38488"></a> <span id="dt-f49e339101bebff90fc1"><code>&#34;sound&#45;dai&#34;</code></span>

<a id="dt-50cce4b2fd9ec2d30691"></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-b1d039535d1669be748b"></a>

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

<div id="dt-27f86cfbbfdaf820aafb">
<p style="white-space: pre-wrap">Holds subnode which indicates codec dai.</p>
</div>

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

<a id="dt-49f343d6211b7d8c6a50"></a>

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

<a id="dt-47fd42628461a16023ae"></a>

**<code>sound&#45;dai</code> — required here**

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

**Required in this object (<code>required</code>):** <a id="dt-110cb81084de063d2cda"></a> <span id="dt-5f7918838f769f2e9d72"><code>&#34;sound&#45;dai&#34;</code></span>

<a id="dt-c79904517ee5bb6501b6"></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-9110e604fdd22bc6efba"></a>

**<code>platform</code> — not listed as required here**

<div id="dt-30cd40eb9476d16dc021">
<p style="white-space: pre-wrap">Holds subnode which includes the phandle of q6apm platform device.</p>
</div>

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

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

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

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

**<code>sound&#45;dai</code> — required here**

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

**Required in this object (<code>required</code>):** <a id="dt-0993a3be1bbaa3054f9c"></a> <span id="dt-e260f4a033ef7d04d19e"><code>&#34;sound&#45;dai&#34;</code></span>

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

**Properties not matched by properties or patternProperties in this schema (<code>additionalProperties</code>)**

<code>false</code>

Not allowed by this rule.

**Required in this object (<code>required</code>):** <a id="dt-7bcf45976ce987f36f75"></a> <span id="dt-7813f4a58c31aa2c9096"><code>&#34;link&#45;name&#34;</code></span>, <span id="dt-2410623bf08c9dbd70dd"><code>&#34;cpu&#34;</code></span>, <span id="dt-618465df7840453c60d2"><code>&#34;codec&#34;</code></span>, <span id="dt-51dd527650b860bb3187"><code>&#34;reg&#34;</code></span>

<a id="dt-172f034be50abb56d12b"></a>

#### Properties not matched by properties or patternProperties in this schema (<code>additionalProperties</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>, <span id="dt-ee7433925c1528c16b99"><code>&#34;&#35;address&#45;cells&#34;</code></span>, <span id="dt-f3765998c4e103e45f2f"><code>&#34;&#35;size&#45;cells&#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/sound/qcom,lpass.h&gt;
sound {
    compatible = "google,sc7280-herobrine";
    model = "sc7280-wcd938x-max98360a-4dmic";

    audio-routing =
        "IN1_HPHL", "HPHL_OUT",
        "IN2_HPHR", "HPHR_OUT",
        "AMIC1", "MIC BIAS1",
        "AMIC2", "MIC BIAS2",
        "VA DMIC0", "MIC BIAS3",
        "VA DMIC1", "MIC BIAS3",
        "VA DMIC2", "MIC BIAS4",
        "VA DMIC3", "MIC BIAS4",
        "TX SWR_ADC0", "ADC1_OUTPUT",
        "TX SWR_ADC1", "ADC2_OUTPUT",
        "TX SWR_ADC2", "ADC3_OUTPUT",
        "TX SWR_DMIC0", "DMIC1_OUTPUT",
        "TX SWR_DMIC1", "DMIC2_OUTPUT",
        "TX SWR_DMIC2", "DMIC3_OUTPUT",
        "TX SWR_DMIC3", "DMIC4_OUTPUT";

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

    dai-link@0 {
        link-name = "WCD Playback";
        reg = &lt;LPASS_CDC_DMA_RX0&gt;;
        cpu {
            sound-dai = &lt;&amp;lpass_cpu LPASS_CDC_DMA_RX0&gt;;
        };

        codec {
            sound-dai = &lt;&amp;wcd938x 0&gt;, &lt;&amp;swr0 0&gt;, &lt;&amp;rxmacro 0&gt;;
        };
    };
    dai-link@1 {
        link-name = "WCD Capture";
        reg = &lt;LPASS_CDC_DMA_TX3&gt;;
        cpu {
            sound-dai = &lt;&amp;lpass_cpu LPASS_CDC_DMA_TX3&gt;;
        };

        codec {
            sound-dai = &lt;&amp;wcd938x 1&gt;, &lt;&amp;swr1 0&gt;, &lt;&amp;txmacro 0&gt;;
        };
    };

    dai-link@2 {
        link-name = "MI2S Playback";
        reg = &lt;MI2S_SECONDARY&gt;;
        cpu {
            sound-dai = &lt;&amp;lpass_cpu MI2S_SECONDARY&gt;;
        };

        codec {
            sound-dai = &lt;&amp;max98360a&gt;;
        };
    };

    dai-link@3 {
        link-name = "DMIC Capture";
        reg = &lt;LPASS_CDC_DMA_VA_TX0&gt;;
        cpu {
            sound-dai = &lt;&amp;lpass_cpu LPASS_CDC_DMA_VA_TX0&gt;;
        };

        codec {
            sound-dai = &lt;&amp;vamacro 0&gt;;
        };
    };

    dai-link@5 {
        link-name = "DP Playback";
        reg = &lt;LPASS_DP_RX&gt;;
        cpu {
            sound-dai = &lt;&amp;lpass_cpu LPASS_DP_RX&gt;;
        };

        codec {
            sound-dai = &lt;&amp;mdss_dp&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>
