From patchwork Tue Jul 7 13:57:48 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Brown X-Patchwork-Id: 6733331 Return-Path: X-Original-To: patchwork-alsa-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 32E3BC05AC for ; Tue, 7 Jul 2015 14:12:46 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 61FE7206DD for ; Tue, 7 Jul 2015 14:12:45 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id 1710320626 for ; Tue, 7 Jul 2015 14:12:44 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 07D57265DE0; Tue, 7 Jul 2015 16:12:43 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from alsa0.perex.cz (localhost [IPv6:::1]) by alsa0.perex.cz (Postfix) with ESMTP id C7EA2265A20; Tue, 7 Jul 2015 16:03:03 +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 827382659EA; Tue, 7 Jul 2015 16:02:59 +0200 (CEST) Received: from mezzanine.sirena.org.uk (mezzanine.sirena.org.uk [106.187.55.193]) by alsa0.perex.cz (Postfix) with ESMTP id 0280A265716 for ; Tue, 7 Jul 2015 15:58:07 +0200 (CEST) Received: from 234.27.125.91.dyn.plus.net ([91.125.27.234] helo=finisterre) by mezzanine.sirena.org.uk with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from ) id 1ZCTNn-0001O6-N0; Tue, 07 Jul 2015 13:58:00 +0000 Received: from broonie by finisterre with local (Exim 4.86_RC4) (envelope-from ) id 1ZCTNc-0005Wc-Ry; Tue, 07 Jul 2015 14:57:51 +0100 From: Mark Brown To: Axel Lin , Haojian Zhuang , Mark Brown In-Reply-To: <1435547723.6397.1.camel@ingics.com> Message-Id: Date: Tue, 07 Jul 2015 14:57:48 +0100 X-SA-Exim-Connect-IP: 91.125.27.234 X-SA-Exim-Mail-From: broonie@sirena.org.uk X-SA-Exim-Version: 4.2.1 (built Mon, 26 Dec 2011 16:24:06 +0000) X-SA-Exim-Scanned: Yes (on mezzanine.sirena.org.uk) Cc: alsa-devel@alsa-project.org Subject: [alsa-devel] Applied "ASoC: 88pm860x: Don't change pm860x->dir setting if pm860x_set_dai_sysclk fails" 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 X-Virus-Scanned: ClamAV using ClamSMTP The patch ASoC: 88pm860x: Don't change pm860x->dir setting if pm860x_set_dai_sysclk fails has been applied to the asoc tree at git://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 93ec3a1ad5b86aef8ca90d2b149ded0f6bb689f5 Mon Sep 17 00:00:00 2001 From: Axel Lin Date: Mon, 29 Jun 2015 11:15:23 +0800 Subject: [PATCH] ASoC: 88pm860x: Don't change pm860x->dir setting if pm860x_set_dai_sysclk fails 88pm860x does not support slave mode, so it returns -EINVAL for PM860X_CLK_DIR_IN. Current code changes pm860x->dir setting before return error, so it has impact on the logic of pm860x_pcm_set_dai_fmt. This patch adds comment for the reason to return -EINVAL for PM860X_CLK_DIR_IN, and avoid changing pm860x->dir setting if pm860x_set_dai_sysclk fails. Signed-off-by: Axel Lin Acked-by: Haojian Zhuang Signed-off-by: Mark Brown --- sound/soc/codecs/88pm860x-codec.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/sound/soc/codecs/88pm860x-codec.c b/sound/soc/codecs/88pm860x-codec.c index 38b3dad..4d91a6a 100644 --- a/sound/soc/codecs/88pm860x-codec.c +++ b/sound/soc/codecs/88pm860x-codec.c @@ -1028,10 +1028,8 @@ static int pm860x_set_dai_sysclk(struct snd_soc_dai *codec_dai, if (dir == PM860X_CLK_DIR_OUT) pm860x->dir = PM860X_CLK_DIR_OUT; - else { - pm860x->dir = PM860X_CLK_DIR_IN; + else /* Slave mode is not supported */ return -EINVAL; - } return 0; }