From patchwork Fri Jul 17 12:02:06 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cheng-yi Chiang X-Patchwork-Id: 11670055 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C8EE31392 for ; Fri, 17 Jul 2020 12:03:26 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E5FA32065F for ; Fri, 17 Jul 2020 12:03:25 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="WUamEdE8"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="Fiq88mJG" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E5FA32065F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id E35D3886; Fri, 17 Jul 2020 14:02:36 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz E35D3886 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1594987404; bh=hnfgoxXELokVIBOU6Yk9wrMZ6yPHZP7whW1Z1bPSBMw=; h=From:To:Subject:Date:Cc:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From; b=WUamEdE8/kEii+CXtjnRWmZizdxlD93CGNsrLUq+GhqR4fGvi+EjGwkwmxf2DFSJF OGAViHD26u3OyWtIA0CcqEU6MIGblB4UVlaubxfkrsrh/i21bOZKTf3oAbVRigyNID 0NMU13KFirv/vUmLdmLM/cfXDQ8KL2Ac06JyEfXU= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 7A8BDF801D8; Fri, 17 Jul 2020 14:02:36 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa1.perex.cz (Postfix, from userid 50401) id CCF8CF80217; Fri, 17 Jul 2020 14:02:35 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on alsa1.perex.cz X-Spam-Level: X-Spam-Status: No, score=-0.1 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from mail-pj1-x1041.google.com (mail-pj1-x1041.google.com [IPv6:2607:f8b0:4864:20::1041]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 7B489F8014E for ; Fri, 17 Jul 2020 14:02:24 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 7B489F8014E Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="Fiq88mJG" Received: by mail-pj1-x1041.google.com with SMTP id md7so6272363pjb.1 for ; Fri, 17 Jul 2020 05:02:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=L3pqPBmqTtCeYXo5oFQYdRCBTjDx4yuoNDp8LIqBhrc=; b=Fiq88mJGxvol+DfakU3u1Vx74pRzPYj7T7rmvxTYQ0R6XbPjlDyufuGXHO11rL4Aqu cxkaKvAndUauNZlZy+N01asDPJLjTFxRqEo+fYpTFPtizdn6V5RKvdsdvaukmq4Y5Wfg WhBvEwK69Z286KKGEqm/S0i9dtloZWeu2N070= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=L3pqPBmqTtCeYXo5oFQYdRCBTjDx4yuoNDp8LIqBhrc=; b=pjK4r/2E2msiebINB0W+10j3XLtWJ6pB/IqEQiwvs+GhZebWr57bxXx0LDURiyAk20 /xUILrftN1ZamrbUdMh4HU2nhYgxFPYRWAwf/ujwgo3AJSlIFN+HfEDZpf/dff1YB5QT Rn1mkOGx49/chhFxRmhcAGOjwLK6w44zR9uo3VShJCmEfGFiMRz+thnSoXMrHbHwJXNY 4Aara7B0bWvxzlm+NgF4rY12vlqMYY8kdnZrLuE2GAixLFE5lHJxZN5JHkkVfqVvTdEY Q7O9x2hfiAgA8tnzs2UBGBJaojIxU2i53MxeVpOUBUS3Gk8WRspr2J1oBOYnF7rO6Y2E gVQQ== X-Gm-Message-State: AOAM533xwTPUrRt43SzB++iFw8o5GyU0rzD+7HIYD91+EdZ5dXAmflA+ Lc4iUOa4kSPdoeqK1LOh5ixusg== X-Google-Smtp-Source: ABdhPJzC5HAlXulCQHydsosvZqKgOL2r1Sq7g4jGNcgmX3dlnIzS0V0GhWvXYW2BuiohLAxnovDWvg== X-Received: by 2002:a17:90a:1748:: with SMTP id 8mr9068453pjm.131.1594987342798; Fri, 17 Jul 2020 05:02:22 -0700 (PDT) Received: from localhost ([2401:fa00:1:10:de4a:3eff:fe7d:d39c]) by smtp.gmail.com with ESMTPSA id c188sm7770179pfc.143.2020.07.17.05.02.18 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 17 Jul 2020 05:02:21 -0700 (PDT) From: Cheng-Yi Chiang To: linux-kernel@vger.kernel.org Subject: [PATCH 1/2] ASoC: qcom: dt-bindings: Add sc7180 machine bindings Date: Fri, 17 Jul 2020 20:02:06 +0800 Message-Id: <20200717120207.3471030-1-cychiang@chromium.org> X-Mailer: git-send-email 2.28.0.rc0.105.gf9edc3c819-goog MIME-Version: 1.0 Cc: Taniya Das , devicetree@vger.kernel.org, tzungbi@chromium.org, Banajit Goswami , alsa-devel@alsa-project.org, linux-arm-msm@vger.kernel.org, Patrick Lai , Takashi Iwai , Liam Girdwood , Rob Herring , Bjorn Andersson , Andy Gross , Rohit kumar , Mark Brown , dianders@chromium.org, dgreid@chromium.org, linux-arm-kernel@lists.infradead.org, Cheng-Yi Chiang X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" Add devicetree bindings documentation file for sc7180 sound card. Signed-off-by: Cheng-Yi Chiang --- .../bindings/sound/qcom,sc7180.yaml | 123 ++++++++++++++++++ 1 file changed, 123 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/qcom,sc7180.yaml diff --git a/Documentation/devicetree/bindings/sound/qcom,sc7180.yaml b/Documentation/devicetree/bindings/sound/qcom,sc7180.yaml new file mode 100644 index 000000000000..d60d2880d991 --- /dev/null +++ b/Documentation/devicetree/bindings/sound/qcom,sc7180.yaml @@ -0,0 +1,123 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/sound/qcom,sc7180.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Qualcomm Technologies Inc. SC7180 ASoC sound card driver + +maintainers: + - Rohit kumar + - Cheng-Yi Chiang + +description: | + This binding describes the SC7180 sound card, which uses LPASS for audio. + +definitions: + + link-name: + description: Indicates dai-link name and PCM stream name. + $ref: /schemas/types.yaml#/definitions/string + maxItems: 1 + + dai: + type: object + properties: + sound-dai: + maxItems: 1 + $ref: /schemas/types.yaml#/definitions/phandle-array + description: phandle array of the codec or CPU DAI + + required: + - sound-dai + + unidirectional: + description: Specify direction of unidirectional dai link. + 0 for playback only. 1 for capture only. + $ref: /schemas/types.yaml#/definitions/uint32 + +properties: + compatible: + contains: + enum: + - qcom,sc7180-sndcard + + audio-routing: + $ref: /schemas/types.yaml#/definitions/non-unique-string-array + description: |- + A list of the connections between audio components. Each entry is a + pair of strings, the first being the connection's sink, the second + being the connection's source. + + model: + $ref: /schemas/types.yaml#/definitions/string + description: User specified audio sound card name + +patternProperties: + "^dai-link-[0-9]+$": + description: | + Each subnode represents a dai link. Subnodes of each dai links would be + cpu/codec dais. + + type: object + + properties: + link-name: + $ref: "#/definitions/link-name" + + unidirectional: + $ref: "#/definitions/unidirectional" + + cpu: + $ref: "#/definitions/dai" + + codec: + $ref: "#/definitions/dai" + + required: + - link-name + - cpu + - codec + + additionalProperties: false + +examples: + + - | + snd { + compatible = "qcom,sc7180-sndcard"; + model = "sc7180-snd-card"; + + pinctrl-names = "default"; + pinctrl-0 = <&sec_mi2s_active &sec_mi2s_dout_active + &sec_mi2s_ws_active &pri_mi2s_active + &pri_mi2s_dout_active &pri_mi2s_ws_active + &pri_mi2s_din_active &pri_mi2s_mclk_active>; + + audio-routing = + "Headphone Jack", "HPOL", + "Headphone Jack", "HPOR"; + + dai-link-0 { + link-name = "MultiMedia0"; + cpu { + sound-dai = <&lpass_cpu 0>; + }; + + codec { + sound-dai = <&alc5682 0>; + }; + }; + + dai-link-1 { + link-name = "MultiMedia1"; + unidirectional = <0>; + cpu { + sound-dai = <&lpass_cpu 1>; + }; + + codec { + sound-dai = <&max98357a>; + }; + }; + };