Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp5093118ybv; Tue, 11 Feb 2020 09:03:29 -0800 (PST) X-Google-Smtp-Source: APXvYqwPwT6TlqLrlxasw5Q9XTUelUE0ym8Lg/hgmrv01wUycQJbmqrER69wTIVh9xMbeds5HKSz X-Received: by 2002:aca:4f4c:: with SMTP id d73mr3563881oib.107.1581440609830; Tue, 11 Feb 2020 09:03:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581440609; cv=none; d=google.com; s=arc-20160816; b=M/n/vI1E091VVS7p/zjzoD3ezgIHY90bKoqfpZZKwUC8FB8xQU70aBNZuDWikrHEXG 64/Ot4tQzpNOP6V6HRMLCwIJyHnYqmoK9FSlS0pkrYURuATmnIEvWnR5A7ksK9zKMzuH Fjmln0gDdxrhIJxRkcaJ6nAlAJHidtMT46ZHgL5nYgUrgZK8C3ij+GzF4dpuQv6rI2fO peY102Yuras+EfQZEvqoKeGco8jCeDinTyDUnBivMqoxPLL7/bfwfuKdj5q50mmpEUpF KQCwquxwAJK71IWSiBSNeqTSbUG36FKbLcybtjPuOPjxNpUXY2kuz0101tJ1T8Yl7sQS dfMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:in-reply-to:subject:cc:to:from :date; bh=SCyZE45rdps0yZq2pcoQm7IuLJ0iREWaRwlcKWPgLn4=; b=pRkkXwo9x6oz/6zK3xM2qIZ3zASM/EN8xzHPXXyY3xJlHVV4obdH+PzLR3viCuNjhh l6TIWrfbWedCA/Ru820ygKriKgDoJgNU4yYYaOkm0Kw8WESgg7dP92Y2MM1VDVGDxVWU zcr1yRlw1WIIZgKTIfvzN1Mgk2K5ChZ53o9IFa0JShenXhI3HnA9Yjtac8raC2kCtFZQ wWAUVGt8nIViIM9feYn4y+CXDuZlfXuaRqQa1KbQZcAfZ4xpv9TiEHagPcB4SqX0pM+S WH4wNRv1vqQ3SUVsK1UO8AlUb2D1Ko15VepQ1vXCuBc0hq/4+Lk96nadQhqu1hh8584E dcBQ== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i23si2105580oto.206.2020.02.11.09.03.02; Tue, 11 Feb 2020 09:03:29 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730542AbgBKPtl (ORCPT + 99 others); Tue, 11 Feb 2020 10:49:41 -0500 Received: from foss.arm.com ([217.140.110.172]:48614 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730534AbgBKPtj (ORCPT ); Tue, 11 Feb 2020 10:49:39 -0500 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id BE7B730E; Tue, 11 Feb 2020 07:49:38 -0800 (PST) Received: from localhost (unknown [10.37.6.21]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 448953F68E; Tue, 11 Feb 2020 07:49:38 -0800 (PST) Date: Tue, 11 Feb 2020 15:49:36 +0000 From: Mark Brown To: Olivier Moysan Cc: alexandre.torgue@st.com, alsa-devel@alsa-project.org, broonie@kernel.org, Etienne Carriere , lgirdwood@gmail.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, Mark Brown , mcoquelin.stm32@gmail.com, olivier.moysan@st.com, perex@perex.cz, tiwai@suse.com Subject: Applied "ASoC: stm32: i2s: manage error when getting reset controller" to the asoc tree In-Reply-To: <20200203100814.22944-4-olivier.moysan@st.com> Message-Id: X-Patchwork-Hint: ignore Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The patch ASoC: stm32: i2s: manage error when getting reset controller has been applied to the asoc tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.7 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 158ecc65c05314cd02fcf67fa54ebef537358e5c Mon Sep 17 00:00:00 2001 From: Olivier Moysan Date: Mon, 3 Feb 2020 11:08:11 +0100 Subject: [PATCH] ASoC: stm32: i2s: manage error when getting reset controller Return an error when the i2s driver fails to get a reset controller. Also add an error trace, except on probe defer status. Signed-off-by: Etienne Carriere Signed-off-by: Olivier Moysan Link: https://lore.kernel.org/r/20200203100814.22944-4-olivier.moysan@st.com Signed-off-by: Mark Brown --- sound/soc/stm/stm32_i2s.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/sound/soc/stm/stm32_i2s.c b/sound/soc/stm/stm32_i2s.c index 3e7226a53e53..cdcc00d9a67e 100644 --- a/sound/soc/stm/stm32_i2s.c +++ b/sound/soc/stm/stm32_i2s.c @@ -866,12 +866,16 @@ static int stm32_i2s_parse_dt(struct platform_device *pdev, } /* Reset */ - rst = devm_reset_control_get_exclusive(&pdev->dev, NULL); - if (!IS_ERR(rst)) { - reset_control_assert(rst); - udelay(2); - reset_control_deassert(rst); + rst = devm_reset_control_get_optional_exclusive(&pdev->dev, NULL); + if (IS_ERR(rst)) { + if (PTR_ERR(rst) != -EPROBE_DEFER) + dev_err(&pdev->dev, "Reset controller error %ld\n", + PTR_ERR(rst)); + return PTR_ERR(rst); } + reset_control_assert(rst); + udelay(2); + reset_control_deassert(rst); return 0; } -- 2.20.1