From patchwork Tue Feb 16 17:32:30 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinivas Kandagatla X-Patchwork-Id: 8329981 X-Patchwork-Delegate: agross@codeaurora.org Return-Path: X-Original-To: patchwork-linux-arm-msm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 46FF09F399 for ; Tue, 16 Feb 2016 17:35:34 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 546EF202A1 for ; Tue, 16 Feb 2016 17:35:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4BB8620260 for ; Tue, 16 Feb 2016 17:35:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755556AbcBPRck (ORCPT ); Tue, 16 Feb 2016 12:32:40 -0500 Received: from mail-wm0-f45.google.com ([74.125.82.45]:34417 "EHLO mail-wm0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755433AbcBPRcj (ORCPT ); Tue, 16 Feb 2016 12:32:39 -0500 Received: by mail-wm0-f45.google.com with SMTP id b205so120569287wmb.1 for ; Tue, 16 Feb 2016 09:32:38 -0800 (PST) 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; bh=EtBunSVvGLACPTVDUaSOlmwjKqC8jT2GusDzif1ly1o=; b=ZWy3EO3qPYxHTUOVx1nN4eHJ1s9h6V4pLHgiuF6/WYBT9xZZWGIl1MJj3aY5NK/mku qawCpCE8aHrJxgCnSOZTl5JiQOGurARqAh1C3zoSRz3SLXhHojTqQredOok6hotCcwYg w0Yj5lblS7Ag2M+0EJ7Vzukihg5rcuAF4zojk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=EtBunSVvGLACPTVDUaSOlmwjKqC8jT2GusDzif1ly1o=; b=HkJ2Nrzko4/6AsFtCf4LU6x470Gdxe9bMamFxGr4gxaVnAoU6O74CQ/arITNJ6SkI8 1kz5Pf4mqKrawzFdJhj1NtRPG+CK8zYbbaBbgjbf+oRtTbRFnR3OZmHXQkyZYZJn79qL GnxKFEcBreCUSqi5qr+oNA04TbeUFs/geOb+gF+anolgHcHpa19NkxHRl88LYKPs3HEC 3e/IgEqeTbEUpw1/Kif1Ccx+hwLzl5LUK2DrIxo2ObGV9Hq2S+s6M7hbVqbHTuQ+VKiX kCoLhf8JsepuuajmDUIkfpJ2s4NDhyANA2cilelIu897xTHVRPLAqyNhjlDT3P+EwG9c NOHg== X-Gm-Message-State: AG10YOQf+xXPSWe7AVizpJ6ty5u7yGpg2EfYlDU7nWNYw6G8AQBEtCb1oKdWl4cJPxI4n4ks X-Received: by 10.28.218.145 with SMTP id r139mr22071416wmg.52.1455643957556; Tue, 16 Feb 2016 09:32:37 -0800 (PST) Received: from localhost.localdomain (host-92-17-247-99.as13285.net. [92.17.247.99]) by smtp.gmail.com with ESMTPSA id bg1sm31202134wjc.27.2016.02.16.09.32.36 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 16 Feb 2016 09:32:36 -0800 (PST) From: Srinivas Kandagatla To: alsa-devel@alsa-project.org, Mark Brown Cc: Rob Herring , Mark Rutland , Pawel Moll , Patrick Lai , Liam Girdwood , Jaroslav Kysela , Takashi Iwai , linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, kwestfie@codeaurora.org, Srinivas Kandagatla Subject: [RFC v1 1/9] ASoC: msm8x176: Add Device Tree bindings. Date: Tue, 16 Feb 2016 17:32:30 +0000 Message-Id: <1455643950-1657-1-git-send-email-srinivas.kandagatla@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1455643880-1611-1-git-send-email-srinivas.kandagatla@linaro.org> References: <1455643880-1611-1-git-send-email-srinivas.kandagatla@linaro.org> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patch adds DT bindings required for msm8x16 codec which is integrated in msm8916 and apq8016 SOCs. Codec IP is divided into two parts, first analog which is integrated in pmic pm8916 and secondly digital part which is integrated into application processor. Codec register controls are also split across pmic an lpass. Analog part is controlled via spmi bus to pmic, registers on the Application processor are memory mapped. Signed-off-by: Srinivas Kandagatla --- .../devicetree/bindings/sound/qcom,msm8x16-wcd.txt | 91 ++++++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/qcom,msm8x16-wcd.txt diff --git a/Documentation/devicetree/bindings/sound/qcom,msm8x16-wcd.txt b/Documentation/devicetree/bindings/sound/qcom,msm8x16-wcd.txt new file mode 100644 index 0000000..42d3f66 --- /dev/null +++ b/Documentation/devicetree/bindings/sound/qcom,msm8x16-wcd.txt @@ -0,0 +1,91 @@ +msm8x16 audio CODEC aka Tombak audio CODEC + +Codec IP is divided into two parts, first analog which is integrated in pmic pm8916 +and secondly digital part which is integrated into application processor. Codec register +controls are also split across pmic an lpass. Analog part is controlled via spmi bus to pmic. + +## Bindings for codec core on pmic: + +Required properties + - compatible = "qcom,msm8x16-wcd-codec"; + - reg: represents the slave base address provided to the peripheral. + - interrupt-parent : The parent interrupt controller. + - interrupts: List of interrupts in given SPMI peripheral. + - interrupt-names: Names specified to above list of interrupts in same + order + - vddio-supply: phandle to VDD_CDC_IO regulator device tree node. + - vdd-tx-rx-supply: phandle to VDD_CDC_TX/RX/CX regulator device tree node. + - vdda-cp-supply: phandle of VDD_CP charge pump supply's regulator device tree node. + - vdda-hph-supply: phandle of VDD_HPH supply's regulator device tree node. + - vdd-micbias-supply: phandle of VDD_MICBIAS supply's regulator device tree + node. +- qcom,lpass-codec-core: phandle to syscon node of lpass code core. + +Optional Properties: +- qcom,micbias1-ext-cap: present if micbias1 has external capacitor connected. +- qcom,micbias2-ext-cap: present if micbias2 has external capacitor connected. + +## Bindings codec core on lpass: + +Required properties + - compatible: should be "syscon" follwed by "qcom,msm8x16-lpass-codec" + - reg: represents the lpass codec core register map. + +Example: + +spmi_bus { + ... + msm8x16_wcd_codec@f000{ + compatible = "qcom,msm8x16-wcd-codec"; + reg = <0xf000 0x200>; + reg-names = "pmic-codec-core"; + clocks = <&gcc GCC_CODEC_DIGCODEC_CLK>; + clock-names = "mclk"; + interrupt-parent = <&spmi_bus>; + interrupts = <0x1 0xf0 0x0 IRQ_TYPE_NONE>, + <0x1 0xf0 0x1 IRQ_TYPE_NONE>, + <0x1 0xf0 0x2 IRQ_TYPE_NONE>, + <0x1 0xf0 0x3 IRQ_TYPE_NONE>, + <0x1 0xf0 0x4 IRQ_TYPE_NONE>, + <0x1 0xf0 0x5 IRQ_TYPE_NONE>, + <0x1 0xf0 0x6 IRQ_TYPE_NONE>, + <0x1 0xf0 0x7 IRQ_TYPE_NONE>, + <0x1 0xf1 0x0 IRQ_TYPE_NONE>, + <0x1 0xf1 0x1 IRQ_TYPE_NONE>, + <0x1 0xf1 0x2 IRQ_TYPE_NONE>, + <0x1 0xf1 0x3 IRQ_TYPE_NONE>, + <0x1 0xf1 0x4 IRQ_TYPE_NONE>, + <0x1 0xf1 0x5 IRQ_TYPE_NONE>; + interrupt-names = "spk_cnp_int", + "spk_clip_int", + "spk_ocp_int", + "ins_rem_det1", + "but_rel_det", + "but_press_det", + "ins_rem_det", + "mbhc_int", + "ear_ocp_int", + "hphr_ocp_int", + "hphl_ocp_det", + "ear_cnp_int", + "hphr_cnp_int", + "hphl_cnp_int"; + + vddio-supply = <&pm8916_l5>; + vdd-cp-supply = <&pm8916_s4>; + vdd-hph-supply = <&pm8916_s4>; + vdd-tx-rx-supply = <&pm8916_l5> + vdd-micbias-supply = <&pm8916_l13>; + qcom,lpass-codec-core = <&lpass_codec>; + #sound-dai-cells = <1>; + }; +}; + +soc { + ... + lpass_codec_core: lpass-codec{ + compatible = "syscon", "qcom,msm8x16-lpass-codec"; + reg = <0x0771c000 0x400>; + }; + +};