From patchwork Fri Oct 18 00:18:39 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinivas Kandagatla X-Patchwork-Id: 176745 Delivered-To: patch@linaro.org Received: by 2002:a92:7e96:0:0:0:0:0 with SMTP id q22csp98467ill; Thu, 17 Oct 2019 17:20:04 -0700 (PDT) X-Google-Smtp-Source: APXvYqxmBcHDCEfZEJD7ptmK64+aCrE1uGNtKH3Ugf80pL+Tg29/gQlGCPM0DOic2X1U6a1AxevC X-Received: by 2002:a17:907:41e1:: with SMTP id nb1mr6106117ejb.323.1571358004653; Thu, 17 Oct 2019 17:20:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571358004; cv=none; d=google.com; s=arc-20160816; b=Ey1iMAbNVpec4ZaI4rXKInIW0VfzGH+g7cEYPcduw+cMCXtbspntJ7jcRZqWE6ghta rzVKj0QSf5CuZIto/XKicbSUYEw6EFtbFr6Tf0sQym1z8ciF2uLMUlyj3VfAd3F291V2 JKNxdTmtwxhFfPbykGSEsW6ZvTDznNthBmWkBsvei924vzC89svzp3bohT40yTbLokW3 olB/n/rBClxatiQRCKAJTqRioy/qjXlxllQaGP+f1Stuv5z5NA+0+wQxJXVdnFamAk37 8JGxlsGI7lxczUnr+bv+5qGVhbKWH/wNvhLY1Ja2cU4sa7ofH86ot2kOMYrjPi97PzJP DpLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=n4me+CazbBGjq6Vioao9/Gq1F8FYE0afxuUK4F7+V3U=; b=WPWoF376B8bOxlAA7DR1jmZ0pQ/ulv+NyAisPzHjsRTgNpmlc9DLAG74qZMD/5oADE sSMHWZL6HyqPmsdFGJpu5gb+w9i+5eWuiO6A7sXLaJT1P7pPiX0p0gdwNyY9WdVlRba4 2Rh/eswIRyi4pLgQCORR+cJnsvmtuzAUQXFVupsmcidB98A7r9KtRi17xXp5t9+4ZQ2F MX2605gKICw9CqpGu9aZy9mIa+M7GZP7eMylyypZz6uqnIoHonE0NuuR2hc0lynBYq/z AYMDPqfCJZC0D7HN2ZgymiKqimteFbVYfc4qYTyfH6BAyaprVUemJarxjI2wVMfNIQDl Fp1g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=oCiIsJX6; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-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. [209.132.180.67]) by mx.google.com with ESMTP id p15si2827523eda.294.2019.10.17.17.20.04; Thu, 17 Oct 2019 17:20:04 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=oCiIsJX6; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-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 S2503842AbfJRAUC (ORCPT + 8 others); Thu, 17 Oct 2019 20:20:02 -0400 Received: from mail-wm1-f46.google.com ([209.85.128.46]:33302 "EHLO mail-wm1-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2503825AbfJRAT7 (ORCPT ); Thu, 17 Oct 2019 20:19:59 -0400 Received: by mail-wm1-f46.google.com with SMTP id r17so8124645wme.0 for ; Thu, 17 Oct 2019 17:19:58 -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=n4me+CazbBGjq6Vioao9/Gq1F8FYE0afxuUK4F7+V3U=; b=oCiIsJX6F+gH7PaC1dF1wSvdbr3nvuj/rpASrcfUBXDPa9TLVMRNynYfDh1s9gpLC+ MaXA2dVh2of8i+tP8nNdU/uDgyq2kMPAJolA10VHH+a+6JvIzkzTQmK4wSjglc8Yhzq7 pz2gDZ/udH1P7WEFFQyV9EPp0zeIe57FdALWZ2IjTqYFUzXkD3k+62elQAkQCUw8L21i QDJh//t0JwTcz4/+vgvq6iKNNu3hyYOQn+Lli+O6vbvIf0e61v5ZQRIjVhYWi5QFMxc7 xtfEKSjK9w0VEDfWRcUILT0rBr4D3w1HJ+lIc2wM6l1EhTqhU+TPsEEcvWLoATzQ0nec H08g== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=n4me+CazbBGjq6Vioao9/Gq1F8FYE0afxuUK4F7+V3U=; b=my0A0R6r6vY9rU8bqyizoF3fvIKBvpNwGAG2lRPZv/9TIFsMxX8G5zLQecLfXj0I8k H91te15oq0qz/Z79IFAX8Ug7FxFu4o3Z1hut+rTlTPDvTek57QoORKblBoIuXtMcBkQM Ir98Q3Hntp0oFju2QB0Qj3ef19Sn2yPHf5qUvFtH5cFFHh8eTpp9/Irz5/VLkG+SjYDN +jRCj93oIh/iagEJXQORP6zoCJzv8+/gynIH/33XsIN67mmgId6Yw4qs4/ebY2YEhFXX HNfIWvxvhK2MLn4R3KjleO+5MqqEnaf466FEq2/Uc6sLH/Y8icHL8NMOVw3QLLPPTDzN CQQg== X-Gm-Message-State: APjAAAUK5dMUFS3GDvrMx+7BNlVGFTUsAAFsmB8sQag+rNjvtVjM2/6g QAHgpKxoQkoXRNaq+YXJoT6l/g== X-Received: by 2002:a1c:740a:: with SMTP id p10mr5178592wmc.130.1571357997300; Thu, 17 Oct 2019 17:19:57 -0700 (PDT) Received: from srini-hackbox.lan (cpc89974-aztw32-2-0-cust43.18-1.cable.virginm.net. [86.30.250.44]) by smtp.gmail.com with ESMTPSA id z189sm4851248wmc.25.2019.10.17.17.19.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 17 Oct 2019 17:19:56 -0700 (PDT) From: Srinivas Kandagatla To: robh@kernel.org, broonie@kernel.org, linus.walleij@linaro.org, lee.jones@linaro.org Cc: vinod.koul@linaro.org, alsa-devel@alsa-project.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, spapothi@codeaurora.org, bgoswami@codeaurora.org, linux-gpio@vger.kernel.org, Srinivas Kandagatla Subject: [PATCH v2 01/11] ASoC: dt-bindings: add dt bindings for WCD9340/WCD9341 audio codec Date: Fri, 18 Oct 2019 01:18:39 +0100 Message-Id: <20191018001849.27205-2-srinivas.kandagatla@linaro.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20191018001849.27205-1-srinivas.kandagatla@linaro.org> References: <20191018001849.27205-1-srinivas.kandagatla@linaro.org> MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org This patch adds bindings for wcd9340/wcd9341 audio codec which can support both SLIMbus and I2S/I2C interface. Signed-off-by: Srinivas Kandagatla --- .../bindings/sound/qcom,wcd934x.yaml | 169 ++++++++++++++++++ 1 file changed, 169 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/qcom,wcd934x.yaml -- 2.21.0 diff --git a/Documentation/devicetree/bindings/sound/qcom,wcd934x.yaml b/Documentation/devicetree/bindings/sound/qcom,wcd934x.yaml new file mode 100644 index 000000000000..299d6b96c339 --- /dev/null +++ b/Documentation/devicetree/bindings/sound/qcom,wcd934x.yaml @@ -0,0 +1,169 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/sound/qcom,wcd934x.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Bindings for Qualcomm WCD9340/WCD9341 Audio Codec + +maintainers: + - Srinivas Kandagatla + +description: | + Qualcomm WCD9340/WCD9341 Codec is a standalone Hi-Fi audio codec IC. + It has in-built Soundwire controller, pin controller, interrupt mux and + supports both I2S/I2C and SLIMbus audio interfaces. + +properties: + compatible: + const: slim217,250 + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + reset-gpios: + description: GPIO spec for reset line to use + maxItems: 1 + + slim-ifc-dev: + description: SLIMBus Interface device phandle + maxItems: 1 + + clocks: + maxItems: 1 + + clock-names: + const: extclk + + vdd-buck-supply: + description: A reference to the 1.8V buck supply + + vdd-buck-sido-supply: + description: A reference to the 1.8V SIDO buck supply + + vdd-rx-supply: + description: A reference to the 1.8V rx supply + + vdd-tx-supply: + description: A reference to the 1.8V tx supply + + vdd-vbat-supply: + description: A reference to the vbat supply + + vdd-io-supply: + description: A reference to the 1.8V I/O supply + + vdd-micbias-supply: + description: A reference to the micbias supply + + qcom,micbias1-millivolt: + description: Voltage betwee 1800mv-2850mv for micbias1 output + allOf: + - $ref: /schemas/types.yaml#/definitions/uint32 + + qcom,micbias2-millivolt: + description: Voltage betwee 1800mv-2850mv for micbias2 output + allOf: + - $ref: /schemas/types.yaml#/definitions/uint32 + + qcom,micbias3-millivolt: + description: Voltage betwee 1800mv-2850mv for micbias3 output + allOf: + - $ref: /schemas/types.yaml#/definitions/uint32 + + qcom,micbias4-millivolt: + description: Voltage betwee 1800mv-2850mv for micbias4 output + allOf: + - $ref: /schemas/types.yaml#/definitions/uint32 + + clock-output-names: + const: mclk + + clock-frequency: + description: Clock frequency of output clk in Hz + + interrupt-controller: true + + '#interrupt-cells': + const: 1 + + '#clock-cells': + const: 0 + + '#sound-dai-cells': + const: 1 + + "#address-cells": + const: 1 + + "#size-cells": + const: 1 + +patternProperties: + "^.*@[0-9a-f]+$": + type: object + description: | + WCD934x subnode for each slave devices. Bindings of each subnodes + depends on the specific driver providing the functionality and + documented in there respective bindings. + + properties: + reg: + maxItems: 1 + + required: + - reg + +required: + - compatible + - reg + - reset-gpios + - slim-ifc-dev + - interrupts + - interrupt-controller + - clock-frequency + - clock-output-names + - qcom,micbias1-millivolt + - qcom,micbias2-millivolt + - qcom,micbias3-millivolt + - qcom,micbias4-millivolt + - "#interrupt-cells" + - "#clock-cells" + - "#sound-dai-cells" + - "#address-cells" + - "#size-cells" + +examples: + - | + codec@1,0{ + compatible = "slim217,250"; + reg = <1 0>; + reset-gpios = <&tlmm 64 0>; + slim-ifc-dev = <&wcd9340_ifd>; + #sound-dai-cells = <1>; + interrupt-parent = <&tlmm>; + interrupts = <54 4>; + interrupt-controller; + #interrupt-cells = <1>; + #clock-cells = <0>; + clock-frequency = <9600000>; + clock-output-names = "mclk"; + qcom,micbias1-millivolt = <1800>; + qcom,micbias2-millivolt = <1800>; + qcom,micbias3-millivolt = <1800>; + qcom,micbias4-millivolt = <1800>; + clock-names = "extclk"; + clocks = <&rpmhcc 2>; + + #address-cells = <1>; + #size-cells = <1>; + + wcdpinctrl@42 { + reg = <0x42 0x2>; + }; + }; + +...