From patchwork Wed Oct 6 16:47:12 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinivas Kandagatla X-Patchwork-Id: 515374 Delivered-To: patch@linaro.org Received: by 2002:ac0:b5cc:0:0:0:0:0 with SMTP id x12csp593839ime; Wed, 6 Oct 2021 09:49:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzA0KKHLTES0tek6pUYWHZ1vUlq02wYi/NIHS2/JXt4z0ib6xdVUuo1jaiksUeYndyZyH0p X-Received: by 2002:a17:907:a061:: with SMTP id ia1mr31726702ejc.372.1633538959830; Wed, 06 Oct 2021 09:49:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1633538959; cv=none; d=google.com; s=arc-20160816; b=H0fiTAGAUWDLyzu/15Co4gUs67VOKFF41StJZwaqjaAv+be3Wc/ndeOzRiZL3RWL6g RoWakfwi0D0HatWt5xiIzOfQiS/KilZ3He8es/kuC5sLZ/2DyILKRZ6qg9RlNpqnJ4N5 uKT6DA4TNsUag6Awv8gZexN0erCMuRCoIG1I3V40a02qWxlmK9vDmNTx64bCr+sik+yC xsFUxvPHTrKvemXhYMF8tiqAFPR97KCz0JsQeYJCZqNOi6f5kdFCso6EjV3xmLKwPhh4 3G86r2/nZB2tdLqmegWLbLsNdf/20Vm1YFMBOAQJLLX0XB1ldUUuIXWMLrAay8lk/Xha zi7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=ouCcvRhvwfDjDdqR2Ag/OHVwx6Zmnh+mSBZ9TgkL1Gw=; b=cROiah384fiu5KJWZVLeMdcKHit6ZH+zuP4UNMhaqCxIGr3A3+C35D4Z9S4580nh8B M90oqXyWlEv+CbqwPvTrmR7Lv6cUPFyHUuTbTp/g0wV8o2VU2HMdHombHqkebAvNztrG J3YKNKJllZG2miDzAc4FJdXRPXTfsON9xa3RN5Nx/iTHDe7pdhmqxiUCxt2+Qn7qD1p3 ziKOyELdtbxCZEYtBM0ehzBeLKLaL/yklaDbiWzvn09tqQ8/8N7CZBprPlA4UrO7EWJ+ SJx5OAL3O9N82XdLmw863+Z+HAZZptN7Q5VFFAgFYp1UveI4zBNHsLD/01wIeLegUuZI VM8w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=pz4OtzCz; spf=pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b13si8368363ede.572.2021.10.06.09.49.19; Wed, 06 Oct 2021 09:49:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=pz4OtzCz; spf=pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232082AbhJFQvJ (ORCPT + 17 others); Wed, 6 Oct 2021 12:51:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42174 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235305AbhJFQtP (ORCPT ); Wed, 6 Oct 2021 12:49:15 -0400 Received: from mail-wr1-x432.google.com (mail-wr1-x432.google.com [IPv6:2a00:1450:4864:20::432]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7CA49C061755 for ; Wed, 6 Oct 2021 09:47:23 -0700 (PDT) Received: by mail-wr1-x432.google.com with SMTP id o20so10711326wro.3 for ; Wed, 06 Oct 2021 09:47:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ouCcvRhvwfDjDdqR2Ag/OHVwx6Zmnh+mSBZ9TgkL1Gw=; b=pz4OtzCzz13mMNwHvEydOd2llMX0EY3kvJvOhhTgZERSPZsaIlDcx+SC5eO2rCrA0a rKuw0mlXHMEAcPbv/zlu5Zi9EmoQg9s3alk7qflr+bysbthM6tPWZfDq3YqUezmv8urx ROIxXtw+Zn+rrlqLv86ohQkU5qn5Cb8JWnHL9jguUlniesxRV185tQS+LLoN//fIHTK6 Siq6niuuVnBmW7Hk7pufhXJoY+IZ1gSgDVQ3AMFRcjqUzzwYpsw6BYGekVldFTRlDxJb 8cBgk3f6vv5NXOu5D6dioGldSVs0WYwDEG7SFVoWojxuC+Co7Tdn+B2H0PRtuLrt7L25 GlWA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ouCcvRhvwfDjDdqR2Ag/OHVwx6Zmnh+mSBZ9TgkL1Gw=; b=t1ZslyoKezhqH1dRoUNz7CXendVyj2rKdtwsW194TD9FGVhewJgEjmIWXbLJ086TVZ MRXgNwaUVdvLv7T3LNrWHdEcmz66bc6vRp0Q6NT7S0X4vPdOSrw8c5RCk/JaK97DOMaq VLSh+T4EXvUNzf3JtDPuZpJ9njD01GTkKXdkTxH7YXJdR0ITRO962eH9b+NNQODVpkf9 cU6TjpsBO7RaEHppHgHyiNE/nt5rY3onB9qEhfK6v+yu/T7JZ6PFxiawHVpVo7rb5G/D B8LP4mqMQ6FedCul1Aqi9g7Fbl2mgwrZqwS01YkZgD4qCWN9Ng+GjfL12Dbda+LC/+0n STuA== X-Gm-Message-State: AOAM5322d96Iz6NtkVxkzwqCuyD+RTpvT8W5GsTj9S8XFbhoUGi1JUxr uT+HV1kVn4Vf1gR9GjDb0+QDXQ== X-Received: by 2002:a05:6000:188d:: with SMTP id a13mr25071311wri.243.1633538842094; Wed, 06 Oct 2021 09:47:22 -0700 (PDT) Received: from srini-hackbox.lan (cpc86377-aztw32-2-0-cust226.18-1.cable.virginm.net. [92.233.226.227]) by smtp.gmail.com with ESMTPSA id l21sm6785165wmg.18.2021.10.06.09.47.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Oct 2021 09:47:21 -0700 (PDT) From: Srinivas Kandagatla To: bjorn.andersson@linaro.org Cc: agross@kernel.org, robh+dt@kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, Srinivas Kandagatla Subject: [PATCH 4/4] arm64: dts: qcom: sm8250-mtp: add sound card support Date: Wed, 6 Oct 2021 17:47:12 +0100 Message-Id: <20211006164712.16078-5-srinivas.kandagatla@linaro.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20211006164712.16078-1-srinivas.kandagatla@linaro.org> References: <20211006164712.16078-1-srinivas.kandagatla@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org This patch adds sound card support for MTP using WCD938x headset playback, capture, WSA8810 Speaker Playback and DMICs via VA macro. Signed-off-by: Srinivas Kandagatla --- arch/arm64/boot/dts/qcom/sm8250-mtp.dts | 104 ++++++++++++++++++++++++ 1 file changed, 104 insertions(+) -- 2.21.0 diff --git a/arch/arm64/boot/dts/qcom/sm8250-mtp.dts b/arch/arm64/boot/dts/qcom/sm8250-mtp.dts index 9b27053ca3af..1df64a744607 100644 --- a/arch/arm64/boot/dts/qcom/sm8250-mtp.dts +++ b/arch/arm64/boot/dts/qcom/sm8250-mtp.dts @@ -648,6 +648,110 @@ }; }; +&sound { + compatible = "qcom,sm8250-sndcard"; + model = "SM8250-MTP-WCD9380-WSA8810-VA-DMIC"; + audio-routing = + "SpkrLeft IN", "WSA_SPK1 OUT", + "SpkrRight IN", "WSA_SPK2 OUT", + "IN1_HPHL", "HPHL_OUT", + "IN2_HPHR", "HPHR_OUT", + "AMIC1", "MIC BIAS1", + "AMIC2", "MIC BIAS2", + "AMIC3", "MIC BIAS3", + "AMIC4", "MIC BIAS3", + "AMIC5", "MIC BIAS4", + "TX SWR_ADC0", "ADC1_OUTPUT", + "TX SWR_ADC1", "ADC2_OUTPUT", + "TX SWR_ADC2", "ADC3_OUTPUT", + "TX SWR_ADC3", "ADC4_OUTPUT", + "TX SWR_DMIC0", "DMIC1_OUTPUT", + "TX SWR_DMIC1", "DMIC2_OUTPUT", + "TX SWR_DMIC2", "DMIC3_OUTPUT", + "TX SWR_DMIC3", "DMIC4_OUTPUT", + "TX SWR_DMIC4", "DMIC5_OUTPUT", + "TX SWR_DMIC5", "DMIC6_OUTPUT", + "TX SWR_DMIC6", "DMIC7_OUTPUT", + "TX SWR_DMIC7", "DMIC8_OUTPUT"; + + mm1-dai-link { + link-name = "MultiMedia1"; + cpu { + sound-dai = <&q6asmdai MSM_FRONTEND_DAI_MULTIMEDIA1>; + }; + }; + + mm2-dai-link { + link-name = "MultiMedia2"; + cpu { + sound-dai = <&q6asmdai MSM_FRONTEND_DAI_MULTIMEDIA2>; + }; + }; + + mm3-dai-link { + link-name = "MultiMedia3"; + cpu { + sound-dai = <&q6asmdai MSM_FRONTEND_DAI_MULTIMEDIA3>; + }; + }; + + wcd-playback-dai-link { + link-name = "WCD Playback"; + cpu { + sound-dai = <&q6afedai RX_CODEC_DMA_RX_0>; + }; + codec { + sound-dai = <&wcd938x 0>, <&swr1 0>, <&rxmacro 0>; + }; + platform { + sound-dai = <&q6routing>; + }; + }; + + wcd-capture-dai-link { + link-name = "WCD Capture"; + cpu { + sound-dai = <&q6afedai TX_CODEC_DMA_TX_3>; + }; + + codec { + sound-dai = <&wcd938x 1>, <&swr2 0>, <&txmacro 0>; + }; + platform { + sound-dai = <&q6routing>; + }; + }; + + wsa-dai-link { + link-name = "WSA Playback"; + cpu { + sound-dai = <&q6afedai WSA_CODEC_DMA_RX_0>; + }; + + codec { + sound-dai = <&left_spkr>, <&right_spkr>, <&swr0 0>, <&wsamacro 0>; + }; + platform { + sound-dai = <&q6routing>; + }; + }; + + va-dai-link { + link-name = "VA Capture"; + cpu { + sound-dai = <&q6afedai VA_CODEC_DMA_TX_0>; + }; + + platform { + sound-dai = <&q6routing>; + }; + + codec { + sound-dai = <&vamacro 0>; + }; + }; +}; + &swr0 { left_spkr: wsa8810-right@0,3{ compatible = "sdw10217211000";