From patchwork Mon Mar 9 23:22:06 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Heiko_St=C3=BCbner?= X-Patchwork-Id: 5972451 Return-Path: X-Original-To: patchwork-linux-rockchip@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 1DCE69F2A9 for ; Mon, 9 Mar 2015 23:22:40 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 5CA1C20131 for ; Mon, 9 Mar 2015 23:22:39 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 7816A2012D for ; Mon, 9 Mar 2015 23:22:38 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1YV70P-0001pW-6b; Mon, 09 Mar 2015 23:22:37 +0000 Received: from gloria.sntech.de ([95.129.55.99]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1YV70M-0001Yy-4T; Mon, 09 Mar 2015 23:22:34 +0000 Received: from ip545477c2.speed.planet.nl ([84.84.119.194] helo=phil.localnet) by gloria.sntech.de with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.80) (envelope-from ) id 1YV6zp-0007Sm-Pd; Tue, 10 Mar 2015 00:22:01 +0100 From: Heiko Stuebner To: Philipp Zabel , broonie@kernel.org Subject: [PATCH 1/3] regulator: don't emit errors in {devm_}regulator_bulk_get when defering Date: Tue, 10 Mar 2015 00:22:06 +0100 Message-ID: <9261130.uPvufuEFrr@phil> User-Agent: KMail/4.14.1 (Linux/3.19.0+; KDE/4.14.2; x86_64; ; ) In-Reply-To: <1429128.MSqYm0qZ9p@phil> References: <1429128.MSqYm0qZ9p@phil> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150309_162234_400040_F9D8D218 X-CRM114-Status: UNSURE ( 8.27 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.0 (/) Cc: Fabio Estevam , devicetree@vger.kernel.org, Pawel Moll , Ian Campbell , David Airlie , Kumar Gala , dianders@chromium.org, djkurtz@chromium.org, linux-kernel@vger.kernel.org, linux-rockchip@lists.infradead.org, Rob Herring , dri-devel@lists.freedesktop.org, Yakir Yang , Andy Yan , Mark Rutland , linux-arm-kernel@lists.infradead.org, Mark Yao X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP When {devm_}regulator_get returns -EPROBE_DEFER the driver in question will try probing again at a later time. So don't spam the log with failure messages as this is an expected result of probe ordering. Signed-off-by: Heiko Stuebner --- drivers/regulator/core.c | 5 +++-- drivers/regulator/devres.c | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c index 52af1d7..07ca6cb 100644 --- a/drivers/regulator/core.c +++ b/drivers/regulator/core.c @@ -3163,8 +3163,9 @@ int regulator_bulk_get(struct device *dev, int num_consumers, consumers[i].supply); if (IS_ERR(consumers[i].consumer)) { ret = PTR_ERR(consumers[i].consumer); - dev_err(dev, "Failed to get supply '%s': %d\n", - consumers[i].supply, ret); + if (ret != -EPROBE_DEFER) + dev_err(dev, "Failed to get supply '%s': %d\n", + consumers[i].supply, ret); consumers[i].consumer = NULL; goto err; } diff --git a/drivers/regulator/devres.c b/drivers/regulator/devres.c index 6ec1d40..78e460d 100644 --- a/drivers/regulator/devres.c +++ b/drivers/regulator/devres.c @@ -168,8 +168,9 @@ int devm_regulator_bulk_get(struct device *dev, int num_consumers, consumers[i].supply); if (IS_ERR(consumers[i].consumer)) { ret = PTR_ERR(consumers[i].consumer); - dev_err(dev, "Failed to get supply '%s': %d\n", - consumers[i].supply, ret); + if (ret != -EPROBE_DEFER) + dev_err(dev, "Failed to get supply '%s': %d\n", + consumers[i].supply, ret); consumers[i].consumer = NULL; goto err; }