From patchwork Tue Sep 4 10:24:47 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinivas Kandagatla X-Patchwork-Id: 10587049 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id DEE781669 for ; Tue, 4 Sep 2018 10:45:11 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D8A40286DA for ; Tue, 4 Sep 2018 10:45:11 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CC3682874C; Tue, 4 Sep 2018 10:45:11 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 020D5286DA for ; Tue, 4 Sep 2018 10:45:10 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 95140267901; Tue, 4 Sep 2018 12:27:36 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 2B07A2678DB; Tue, 4 Sep 2018 12:27:33 +0200 (CEST) Received: from mail-wr1-f68.google.com (mail-wr1-f68.google.com [209.85.221.68]) by alsa0.perex.cz (Postfix) with ESMTP id 993E2266E0E for ; Tue, 4 Sep 2018 12:27:30 +0200 (CEST) Received: by mail-wr1-f68.google.com with SMTP id v90-v6so3415606wrc.0 for ; Tue, 04 Sep 2018 03:27:30 -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; bh=Xxn1Md6Q1rw7FvsQmkfDysf/kPe7UQxUJS0wM0f+YJQ=; b=ZoPWop6DQzbJKdkLgnXfo6BB04jRWnvzAyTlmzqBdJv79IDYARsL0YRS3Iu/DyAVPV QR95TV4YIoKnLUi9N1CRT2aQnPrmfzGnaBlXHd4OFNa5XcRaWh/zTItXh42DqKhtOvZ4 nUNgJ4rjATk0/cTcHViIg/3XvZIcBIxtokY5s= 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; bh=Xxn1Md6Q1rw7FvsQmkfDysf/kPe7UQxUJS0wM0f+YJQ=; b=KwpCzAd4aW1HFrGjoZDoeCM6Qkc0EAXzlPzbDF7bUqGg9PiaFyChD5p68Ve2TEgfrJ VbtbjTlbyte3KMY+05kSrnuOw0bbeczvdkmlIuT3sUZ/XMmoAVzD34noPuPLyocwTHY+ gYD/M2GrWUbPi3U1kc9H5Q3Or4zmePWAJE7IzYA4Ag9Fh9L8mjrgdBZLNLoffdcQPQ38 swvgR+2Re7949tG3Udqvqlvmy+j5Axe74rmW3hGTYujXNKvO/Od7e50xqqyMCovq2+LA mrXlaxY3BD9XMgb0/w6dcRiguZ6CAI25k3PkpAKsQGLTN1yGmPHtgrtPjpS3271z+qh3 mysw== X-Gm-Message-State: APzg51CpCOv93jTw975vaFMVzqB8SpO0WZ7L3YnWQ0NOrRQWupJjgbTn ag4gUlfJ+yRsBbuaFITXRrnDbQ== X-Google-Smtp-Source: ANB0VdY9PDB5curnWy1uKQghbyz3bq0jF8OMNdYcuKDjUOEm7pgFF900CYP3GE3E3QFhR5OlXRV4lQ== X-Received: by 2002:adf:9d81:: with SMTP id p1-v6mr21336084wre.12.1536056849836; Tue, 04 Sep 2018 03:27:29 -0700 (PDT) Received: from localhost.localdomain (cpc90716-aztw32-2-0-cust92.18-1.cable.virginm.net. [86.26.100.93]) by smtp.gmail.com with ESMTPSA id g129-v6sm16903325wmf.42.2018.09.04.03.27.28 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 04 Sep 2018 03:27:29 -0700 (PDT) From: Srinivas Kandagatla To: lee.jones@linaro.org, robh+dt@kernel.org, broonie@kernel.org Date: Tue, 4 Sep 2018 11:24:47 +0100 Message-Id: <20180904102500.30318-1-srinivas.kandagatla@linaro.org> X-Mailer: git-send-email 2.18.0 Cc: mark.rutland@arm.com, devicetree@vger.kernel.org, alsa-devel@alsa-project.org, bgoswami@codeaurora.org, lgirdwood@gmail.com, linux-kernel@vger.kernel.org, vkoul@kernel.org, Srinivas Kandagatla Subject: [alsa-devel] [PATCH v3 00/13] ASoC: Add support to WCD9335 Audio Codec X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 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: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP Thankyou for reviewing v2 patchset, here is v3 addressing comments from v2. Qualcomm WCD9335 Codec is a standalone Hi-Fi audio codec IC. It is integrated in multiple Qualcomm SoCs like: MSM8996, MSM8976, and MSM8956 chipsets. WCD9335 had multiple functional blocks, like: Soundwire controller, interrupt mux, pin controller, Audio codec, MBHC, MAD(Mic activity Detection), Ultrasonic proximity and pen detection, Battery-voltage monitoring and Codec processing engine. Currently this patchset has been only tested with SLIMbus interface due to hardware avaiablity, but it can be easily made to work with both SLIMbus and I2C/I2S. This patchset adds very basic playback and capture support witout much fancy features. New features will be added once the basic support is in. This patchset is tested on top of linux-next on DB820c for both playback , capture paths and MBHC. Some parts of the code has been inherited from Qualcomm andriod kernel, so credits to various authors. WCD9335 can be interfaced via I2S/I2C or SLIMbus. Here is my test branch incase someone want to try this out: https://git.linaro.org/people/srinivas.kandagatla/linux.git/log/?h=wcd9335 Thanks, Srini Changes since v2 (https://lwn.net/Articles/761107/) - Updated dt bindings according to Robs Comments. - Added MBHC support with new bindings - Moved mfd irq in to single file as suggested by Lee Jones. - Addressed various minor comments on mfd driver by Lee Jones. - Rebased on top of 4.19-rc1 - renamed clsh as clsh-v2 as its v2 block Srinivas Kandagatla (13): ASoC: dt-bindings: update wcd9335 bindings. mfd: wcd9335: add support to wcd9335 core mfd: wcd9335: add wcd irq support ASoC: wcd9335: add support to wcd9335 codec ASoC: wcd9335: add CLASS-H Controller support ASoC: wcd9335: add basic controls ASoC: wcd9335: add playback dapm widgets ASoC: wcd9335: add capture dapm widgets ASoC: wcd9335: add audio routings ASoC: dt-bindings: Add WCD9335 MBHC specific properties ASoC: wcd9335: add mbhc support ASoC: apq8096: add slim support ASoC: apq8096: add headset JACK support .../bindings/sound/qcom,wcd9335.txt | 30 +- drivers/mfd/Kconfig | 14 + drivers/mfd/Makefile | 4 + drivers/mfd/wcd9335-core.c | 369 ++ include/linux/mfd/wcd9335/registers.h | 627 ++ include/linux/mfd/wcd9335/wcd9335.h | 65 + sound/soc/codecs/Kconfig | 5 + sound/soc/codecs/Makefile | 2 + sound/soc/codecs/wcd-clsh-v2.c | 577 ++ sound/soc/codecs/wcd-clsh-v2.h | 49 + sound/soc/codecs/wcd9335.c | 5234 +++++++++++++++++ sound/soc/qcom/apq8096.c | 122 +- 12 files changed, 7092 insertions(+), 6 deletions(-) create mode 100644 drivers/mfd/wcd9335-core.c create mode 100644 include/linux/mfd/wcd9335/registers.h create mode 100644 include/linux/mfd/wcd9335/wcd9335.h create mode 100644 sound/soc/codecs/wcd-clsh-v2.c create mode 100644 sound/soc/codecs/wcd-clsh-v2.h create mode 100644 sound/soc/codecs/wcd9335.c