From patchwork Fri Nov 8 18:49:19 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 178948 Delivered-To: patch@linaro.org Received: by 2002:a92:38d5:0:0:0:0:0 with SMTP id g82csp3148746ilf; Fri, 8 Nov 2019 11:13:34 -0800 (PST) X-Google-Smtp-Source: APXvYqzKa6MiaJbiQ9rmseFpBGquHObsIERE0zdV7l9hWpoNIj+TzNqGcOFfsti+gXnNyjIo9rP8 X-Received: by 2002:a50:baa9:: with SMTP id x38mr11465421ede.106.1573240414741; Fri, 08 Nov 2019 11:13:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573240414; cv=none; d=google.com; s=arc-20160816; b=vNbIRyVHEhXbBrPcsYq2c/r+E3SO8qn7gGjAhRylboUiBkZ1gwcXVF1NFYJIndbXNf r+kmvkV2YQyiNAvpGJ71QGM5mZOWKLffAIxPUHJwW8H5I1bC4GT9G5nVVQfFeNNOZkMO 4kjbPxCpxLbuIZXkktYm+sv7u0w2bRwLhtSjRCCxi1bUc1m45oaqHOuIVNj0VeT0ejjG KFA6oI97FjHUwidazpcT4xHd7fv/JD54q69wD6ZoWVaxaPLUzXOVpa4wv+R8j314U+aV LxfiO6avp2eJwhRj0MzbZxSlmF94hv9CDagtUFCuccPgzzf4gm3DGREBJJzkrrpp/Pqb cbXg== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=UpZm/01jzmx0ONGp8tr22OQNfnfNwKwJhQK5i+IUKi4=; b=MboUTOlURr3nDtSNNfDQXYss6bY2XAT1wKx054WBJiE/g/+jMOWxiT2zc0cAVa9Zwy Z/LVS0eyy7aFpcoC4rCpOV5YXW9oUm0DRNbMAlrXs8ntLpVvW7HofqzpgXk3Y9pnIKF3 R0KvFF0llHDEUo7ciDYDVmXJKvKpBNrMVpplAjfNE09A5gnAB8Iook78fuRpW3Iem7BW LTocilOUAG+kEVKEhNRyC64v1M6uP2/iakEDmFBp6dxRN9VdI6NBSBF2wkO4cPCCypOD RJhUWqQ93eTE/s2gbDiowXX3c7cEmXLbXbH4WvR0BidjBtlP98rymdW8XZlwp+HxOg1s 8jRQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=HVZV1Y27; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b15si4352691eju.362.2019.11.08.11.13.34; Fri, 08 Nov 2019 11:13:34 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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=@kernel.org header.s=default header.b=HVZV1Y27; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390651AbfKHTN2 (ORCPT + 26 others); Fri, 8 Nov 2019 14:13:28 -0500 Received: from mail.kernel.org ([198.145.29.99]:38348 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2391464AbfKHTHf (ORCPT ); Fri, 8 Nov 2019 14:07:35 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 74216206A3; Fri, 8 Nov 2019 19:07:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1573240055; bh=/idMyIy3EstznScmSyy4e32Pa8RU7vF8zAOKGKWH8Qw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=HVZV1Y275l4bvTYNsMDjplCQpz8kJhuP4bt+6TR/JM/sKJudJFLSjl2BWvb89Gnem QBWJEuHYB/NnkH2EkJdvDDyjnUqKKSF0Dulj6RFaHGVH6YRFMz92Uyws+fyfjj2hTv C67eWsOgkyiCcJQRNvAh8bdAZ7Bla0KcfLaCbzlo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Stephan Gerhold , Srinivas Kandagatla , Mark Brown , Sasha Levin Subject: [PATCH 5.3 031/140] ASoC: msm8916-wcd-digital: add missing MIX2 path for RX1/2 Date: Fri, 8 Nov 2019 19:49:19 +0100 Message-Id: <20191108174906.056525827@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191108174900.189064908@linuxfoundation.org> References: <20191108174900.189064908@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Srinivas Kandagatla [ Upstream commit bcab05880f9306e94531b0009c627421db110a74 ] This patch adds missing MIX2 path on RX1/2 which take IIR1 and IIR2 as inputs. Without this patch sound card fails to intialize with below warning: ASoC: no sink widget found for RX1 MIX2 INP1 ASoC: Failed to add route IIR1 -> IIR1 -> RX1 MIX2 INP1 ASoC: no sink widget found for RX2 MIX2 INP1 ASoC: Failed to add route IIR1 -> IIR1 -> RX2 MIX2 INP1 ASoC: no sink widget found for RX1 MIX2 INP1 ASoC: Failed to add route IIR2 -> IIR2 -> RX1 MIX2 INP1 ASoC: no sink widget found for RX2 MIX2 INP1 ASoC: Failed to add route IIR2 -> IIR2 -> RX2 MIX2 INP1 Reported-by: Stephan Gerhold Signed-off-by: Srinivas Kandagatla Tested-by: Stephan Gerhold Link: https://lore.kernel.org/r/20191009111944.28069-1-srinivas.kandagatla@linaro.org Signed-off-by: Mark Brown Signed-off-by: Sasha Levin --- sound/soc/codecs/msm8916-wcd-digital.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) -- 2.20.1 diff --git a/sound/soc/codecs/msm8916-wcd-digital.c b/sound/soc/codecs/msm8916-wcd-digital.c index 1db7e43ec203e..5963d170df432 100644 --- a/sound/soc/codecs/msm8916-wcd-digital.c +++ b/sound/soc/codecs/msm8916-wcd-digital.c @@ -243,6 +243,10 @@ static const char *const rx_mix1_text[] = { "ZERO", "IIR1", "IIR2", "RX1", "RX2", "RX3" }; +static const char * const rx_mix2_text[] = { + "ZERO", "IIR1", "IIR2" +}; + static const char *const dec_mux_text[] = { "ZERO", "ADC1", "ADC2", "ADC3", "DMIC1", "DMIC2" }; @@ -270,6 +274,16 @@ static const struct soc_enum rx3_mix1_inp_enum[] = { SOC_ENUM_SINGLE(LPASS_CDC_CONN_RX3_B2_CTL, 0, 6, rx_mix1_text), }; +/* RX1 MIX2 */ +static const struct soc_enum rx_mix2_inp1_chain_enum = + SOC_ENUM_SINGLE(LPASS_CDC_CONN_RX1_B3_CTL, + 0, 3, rx_mix2_text); + +/* RX2 MIX2 */ +static const struct soc_enum rx2_mix2_inp1_chain_enum = + SOC_ENUM_SINGLE(LPASS_CDC_CONN_RX2_B3_CTL, + 0, 3, rx_mix2_text); + /* DEC */ static const struct soc_enum dec1_mux_enum = SOC_ENUM_SINGLE( LPASS_CDC_CONN_TX_B1_CTL, 0, 6, dec_mux_text); @@ -309,6 +323,10 @@ static const struct snd_kcontrol_new rx3_mix1_inp2_mux = SOC_DAPM_ENUM( "RX3 MIX1 INP2 Mux", rx3_mix1_inp_enum[1]); static const struct snd_kcontrol_new rx3_mix1_inp3_mux = SOC_DAPM_ENUM( "RX3 MIX1 INP3 Mux", rx3_mix1_inp_enum[2]); +static const struct snd_kcontrol_new rx1_mix2_inp1_mux = SOC_DAPM_ENUM( + "RX1 MIX2 INP1 Mux", rx_mix2_inp1_chain_enum); +static const struct snd_kcontrol_new rx2_mix2_inp1_mux = SOC_DAPM_ENUM( + "RX2 MIX2 INP1 Mux", rx2_mix2_inp1_chain_enum); /* Digital Gain control -38.4 dB to +38.4 dB in 0.3 dB steps */ static const DECLARE_TLV_DB_SCALE(digital_gain, -3840, 30, 0); @@ -740,6 +758,10 @@ static const struct snd_soc_dapm_widget msm8916_wcd_digital_dapm_widgets[] = { &rx3_mix1_inp2_mux), SND_SOC_DAPM_MUX("RX3 MIX1 INP3", SND_SOC_NOPM, 0, 0, &rx3_mix1_inp3_mux), + SND_SOC_DAPM_MUX("RX1 MIX2 INP1", SND_SOC_NOPM, 0, 0, + &rx1_mix2_inp1_mux), + SND_SOC_DAPM_MUX("RX2 MIX2 INP1", SND_SOC_NOPM, 0, 0, + &rx2_mix2_inp1_mux), SND_SOC_DAPM_MUX("CIC1 MUX", SND_SOC_NOPM, 0, 0, &cic1_mux), SND_SOC_DAPM_MUX("CIC2 MUX", SND_SOC_NOPM, 0, 0, &cic2_mux),