Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp29491968rwd; Wed, 5 Jul 2023 12:40:16 -0700 (PDT) X-Google-Smtp-Source: APBJJlE02cn9osWQy+fNJGoIoHQIqz9dxffFdWSjnu3O3jl3UNhJtTiCinEmVFp9kLd44P2DznNq X-Received: by 2002:a17:902:c94d:b0:1b7:f98d:5570 with SMTP id i13-20020a170902c94d00b001b7f98d5570mr13266363pla.56.1688586016340; Wed, 05 Jul 2023 12:40:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688586016; cv=none; d=google.com; s=arc-20160816; b=I+erQwQHRilX6ZuW4DP7N3gDc0DSJtUpdeg1FAYOoBEnbrhBj7+TTbFVJiRkFLpHoo vYlqtBdvoodzrN3I8E/t4MU5Rpv8gWQIoW9IWZ8C+iSHctxN/CWt9z9YaDZG2bOePCjk j8Ow69STiL/odZqiGjCaR9Fps1sO37lzVN/aaGsJKfQwR6K0dMfEa8a31GVrBJ9cMvxa 8TAvm+HGB8Z9IcJB27jtdMBOz6QBhfUHPaonle1dHXlGX2y2jXv5XSCGJCUP44jqhfaS NfcbKff2q4VT80AItoNUog09AeG/pBUaL9YlLg3+8kApF+V93usrUe1gi5slJ5kxmonC duVg== 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:to:from; bh=dwMzYE2He4immy06bKLKQcEG7R9QEjZEQ8H5giGhVsM=; fh=k7VoT2L8jBkp/srhzriYpHmGaQcD33boGmUYQ969TJw=; b=gJ++81mV7Kvwo1mKpvMyWqH7uitZBZa2rjXXNhTuIbXE2rYaz38CiZcWNaEIPF9N7A UPAlxJFc3ub9H9sZ/kPPfo7a/bv4x62UX3QXXCc/vEZwjlPo1REhbjJNeAQAkPKMiKpL lzvgezAOjqubPBaRkT3QUJyD+AofQGQCsHMIY2i+VFFDQO37b1kM09C0sms1qAsiWITT WPnXeJL07cdXqX+0FF86a39PmkOlcFGJibCglZMgkZBRAg7LzAkFqxa+xtMy271IYjcg XfL1bGfncgSLqSdgUswH6M+sp/BPPd+9xN+enkBSLDHAa/wj/YiPHsTxHvWeXQoGOuve rGOg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k15-20020a170902c40f00b001b20e2ba8e1si5823852plk.23.2023.07.05.12.40.01; Wed, 05 Jul 2023 12:40:16 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233493AbjGETFE (ORCPT + 99 others); Wed, 5 Jul 2023 15:05:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42974 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233635AbjGETED (ORCPT ); Wed, 5 Jul 2023 15:04:03 -0400 Received: from mail.andi.de1.cc (mail.andi.de1.cc [IPv6:2a02:c205:3004:2154::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8182C1FEC; Wed, 5 Jul 2023 12:03:40 -0700 (PDT) Received: from p200300ccff0adc001a3da2fffebfd33a.dip0.t-ipconnect.de ([2003:cc:ff0a:dc00:1a3d:a2ff:febf:d33a] helo=aktux) by mail.andi.de1.cc with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qH7mi-0017Xs-Te; Wed, 05 Jul 2023 21:03:28 +0200 Received: from andi by aktux with local (Exim 4.96) (envelope-from ) id 1qH7mi-001UQp-1o; Wed, 05 Jul 2023 21:03:28 +0200 From: Andreas Kemnade To: bcousson@baylibre.com, tony@atomide.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz, tiwai@suse.com, peter.ujfalusi@gmail.com, jarkko.nikula@bitmer.com, dmitry.torokhov@gmail.com, andreas@kemnade.info, linux-omap@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org Subject: [PATCH 2/3] ASoC: tlv320aic3x: use BCLK instead of MCLK if not in master mode Date: Wed, 5 Jul 2023 21:03:23 +0200 Message-Id: <20230705190324.355282-3-andreas@kemnade.info> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230705190324.355282-1-andreas@kemnade.info> References: <20230705190324.355282-1-andreas@kemnade.info> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Required to have audio output on Epson Moverio BT-200. Audio chip there is marked with AC31051. Audio output is silent there without that clock register set. Signed-off-by: Andreas Kemnade --- sound/soc/codecs/tlv320aic3x.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sound/soc/codecs/tlv320aic3x.c b/sound/soc/codecs/tlv320aic3x.c index 56e795a00e22f..87929e210b55e 100644 --- a/sound/soc/codecs/tlv320aic3x.c +++ b/sound/soc/codecs/tlv320aic3x.c @@ -1234,6 +1234,10 @@ static int aic3x_set_dai_sysclk(struct snd_soc_dai *codec_dai, struct snd_soc_component *component = codec_dai->component; struct aic3x_priv *aic3x = snd_soc_component_get_drvdata(component); + /* probably no mclk if not master, so rely on bitclk */ + if (!aic3x->master) + clk_id = 2; + /* set clock on MCLK or GPIO2 or BCLK */ snd_soc_component_update_bits(component, AIC3X_CLKGEN_CTRL_REG, PLLCLK_IN_MASK, clk_id << PLLCLK_IN_SHIFT); -- 2.39.2