From patchwork Wed Dec 13 15:45:08 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Brown X-Patchwork-Id: 121794 Delivered-To: patch@linaro.org Received: by 10.140.22.227 with SMTP id 90csp5633382qgn; Wed, 13 Dec 2017 07:45:40 -0800 (PST) X-Google-Smtp-Source: ACJfBos4IbGFVBtLloNnLJBmhclNNPjH2aq3gDhhIjNNnzUES8kJBUTO1Egx25MRBj4VCs9P6XS9 X-Received: by 10.223.165.89 with SMTP id j25mr2875729wrb.206.1513179940295; Wed, 13 Dec 2017 07:45:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1513179940; cv=none; d=google.com; s=arc-20160816; b=ZT35u9hq7gykz8ZLDWPnLw8g4qcF0st5QsnE2JH9m2Psbk9XQA4P583y6uEXJKZ95i Ft1NxuRGGYB1rY69oNPoqx/4SPwnRqmIqa9gjPZhKvuiNTjDkOqc0oCOPjwpD5Vj7//m bx0Wip8zQAKNi2bdH+kPjtFRbgIEsfQ1w/OtSpxWEzjlzDIRySw77PlunfcSYE4FV9TK 1R9619z9WOV63RT9bgxPkJwXoVKMC8dqQHQJzzH01oRLIdf5kRKm51COhgWmxuUcwYvQ k2+UaphyHTEUKIgljGNeGPXB+Fvjxc7QcSui9wbb28Vf3+bmESnu5kBBRXuSfPIL8Dsp pbZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:date:message-id:in-reply-to:to:from :dkim-signature:delivered-to:arc-authentication-results; bh=53QseFnOKhjVkWBEQxz3Ow03aHR6P8wGagUcoE1dpus=; b=sLKlrgehBpSKcpsQHyZFk7TVjRNuZY0di4a6tTvWawJ10mivzBay75clBdO6HhbQ1G FwPmh7a92ISXXaK4f81TX+yVgM7ozP2/C8oBrZ8rQxL6gOaacWo2n7B3xMD8FzQqiFv5 z5Qt1+9UVwyFJVP7JVLw788nWKwdkYhfBKjagi5mheaXvN2io6iCWOBcD0YBG0GtIc32 LozdnCbYH4mWEhPexf7rlEKQQ3iH1FDkvNMeDyDATr6O1q/CfdXlyp49V6Qkr6bRE7wI ldaTbDnYNscdYBSpooAqt+mWs9IeOB5FING0BrZkoknGL3AHaMr44IYtJxR5NUE980ZB 6yhw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=A6vJf12E; spf=pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) smtp.mailfrom=alsa-devel-bounces@alsa-project.org Return-Path: Received: from alsa0.perex.cz (alsa0.perex.cz. [77.48.224.243]) by mx.google.com with ESMTP id y23si1655891wry.319.2017.12.13.07.45.40; Wed, 13 Dec 2017 07:45:40 -0800 (PST) Received-SPF: pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) client-ip=77.48.224.243; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=A6vJf12E; spf=pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 6BEDA267932; Wed, 13 Dec 2017 16:45:25 +0100 (CET) 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 EC2A2267935; Wed, 13 Dec 2017 16:45:23 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail1.perex.cz X-Spam-Level: X-Spam-Status: No, score=0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, SPF_PASS, T_RP_MATCHES_RCVD autolearn=disabled version=3.4.0 Received: from heliosphere.sirena.org.uk (heliosphere.sirena.org.uk [172.104.155.198]) by alsa0.perex.cz (Postfix) with ESMTP id C0CE6266AE4 for ; Wed, 13 Dec 2017 16:45:10 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sirena.org.uk; s=20170815-heliosphere; h=Date:Message-Id:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References: List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner: List-Archive; bh=c3D9HEZoO1mSmoAal5lge3FTFGx2hvDZDjc0VXnvkBU=; b=A6vJf12ES45w 8VO1oxkYgm8Os6qaGLR9Vf3tVcX1c8dePCbSdNrpQuK/foHswbdY9HtdSKCXbI38SfsH1MlyVu0f8 Ufn8QhU49M3B64gxViTDMdt4XaaOMb4quwxxSUoweBcw/hxKA1gzxO1MiMD8vxIr5Sv8M/F/sEkRe 7CsbY=; Received: from debutante.sirena.org.uk ([2001:470:1f1d:6b5::3] helo=debutante) by heliosphere.sirena.org.uk with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1eP9DY-0001UA-HM; Wed, 13 Dec 2017 15:45:08 +0000 Received: from broonie by debutante with local (Exim 4.90_RC3) (envelope-from ) id 1eP9DY-0002IA-3T; Wed, 13 Dec 2017 15:45:08 +0000 From: Mark Brown To: Andrew F. Davis In-Reply-To: <20171212224311.24045-7-afd@ti.com> Message-Id: Date: Wed, 13 Dec 2017 15:45:08 +0000 Cc: "Andrew F ., Davis" , alsa-devel@alsa-project.org, Mark Brown , Liam Girdwood , linux-kernel@vger.kernel.org Subject: [alsa-devel] Applied "ASoC: tlv320aic32x4: Use snd_soc_update_bits() in aic32x4_mute()" to the asoc tree 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 The patch ASoC: tlv320aic32x4: Use snd_soc_update_bits() in aic32x4_mute() has been applied to the asoc tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark >From b7ddd9cab7d1c800db83e442e881d8cb3f755633 Mon Sep 17 00:00:00 2001 From: "Andrew F. Davis" Date: Tue, 12 Dec 2017 16:43:08 -0600 Subject: [PATCH] ASoC: tlv320aic32x4: Use snd_soc_update_bits() in aic32x4_mute() Simplify mute function by using snd_soc_update_bits() over read/modify/write style code. Signed-off-by: Andrew F. Davis Signed-off-by: Mark Brown --- sound/soc/codecs/tlv320aic32x4.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) -- 2.15.1 _______________________________________________ Alsa-devel mailing list Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel diff --git a/sound/soc/codecs/tlv320aic32x4.c b/sound/soc/codecs/tlv320aic32x4.c index e528a8495346..5deabe36ae94 100644 --- a/sound/soc/codecs/tlv320aic32x4.c +++ b/sound/soc/codecs/tlv320aic32x4.c @@ -773,13 +773,10 @@ static int aic32x4_hw_params(struct snd_pcm_substream *substream, static int aic32x4_mute(struct snd_soc_dai *dai, int mute) { struct snd_soc_codec *codec = dai->codec; - u8 dac_reg; - dac_reg = snd_soc_read(codec, AIC32X4_DACMUTE) & ~AIC32X4_MUTEON; - if (mute) - snd_soc_write(codec, AIC32X4_DACMUTE, dac_reg | AIC32X4_MUTEON); - else - snd_soc_write(codec, AIC32X4_DACMUTE, dac_reg); + snd_soc_update_bits(codec, AIC32X4_DACMUTE, + AIC32X4_MUTEON, mute ? AIC32X4_MUTEON : 0); + return 0; }