From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.1 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 75C37C3A5A2 for ; Sun, 22 Sep 2019 19:21:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4204220673 for ; Sun, 22 Sep 2019 19:21:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1569180062; bh=01/b3bViCNm6jZBCBwJsYl/9WvWajsU4eHQQh4EqkJs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=Bp9VVZtHA6fJ8hnnmli7qGAc2cDc2APWdOgTEA31S5bVYRr2oiJ0LSH/SxoYYV1k6 aXbp3peGRbbqHAV1dWQpjExSzsUxzBtyQZ1zY3IpzNme/LYe1J8MQqqZo9AvxR6EJI +QoqBfZgp9pgQLnx1tkf/kimDdzKTy4mgmn5sW64= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727105AbfIVTVB (ORCPT ); Sun, 22 Sep 2019 15:21:01 -0400 Received: from mail.kernel.org ([198.145.29.99]:54870 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2404384AbfIVSyX (ORCPT ); Sun, 22 Sep 2019 14:54:23 -0400 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 30CE021D56; Sun, 22 Sep 2019 18:54:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1569178462; bh=01/b3bViCNm6jZBCBwJsYl/9WvWajsU4eHQQh4EqkJs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=geeeA0c86kSIheTJQAJE/7kRTf5wpsEjdyP1J502IaPYRQHiYCwwnrZiw7i9hc6cN Y+I28N8AueRz0AJZsUoN/FSRV+5IyLRnPD3cakL1UO+yBcp48DMjeiNZTgTMt5bDWZ 3mF2dU0GXYIeBCh+Xb/zzpK9z+Z08HmZrbIiA/N8= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Lucas Stach , "Andrew F . Davis" , Mark Brown , Sasha Levin Subject: [PATCH AUTOSEL 4.19 003/128] ASoC: tlv320aic31xx: suppress error message for EPROBE_DEFER Date: Sun, 22 Sep 2019 14:52:13 -0400 Message-Id: <20190922185418.2158-3-sashal@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190922185418.2158-1-sashal@kernel.org> References: <20190922185418.2158-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Lucas Stach [ Upstream commit b7e814deae33eb30f8f8c6528e8e69b107978d88 ] Both the supplies and reset GPIO might need a probe deferral for the resource to be available. Don't print a error message in that case, as it is a normal operating condition. Signed-off-by: Lucas Stach Acked-by: Andrew F. Davis Link: https://lore.kernel.org/r/20190719143637.2018-1-l.stach@pengutronix.de Signed-off-by: Mark Brown Signed-off-by: Sasha Levin --- sound/soc/codecs/tlv320aic31xx.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sound/soc/codecs/tlv320aic31xx.c b/sound/soc/codecs/tlv320aic31xx.c index bf92d36b8f8ab..3c75dcf917417 100644 --- a/sound/soc/codecs/tlv320aic31xx.c +++ b/sound/soc/codecs/tlv320aic31xx.c @@ -1441,7 +1441,8 @@ static int aic31xx_i2c_probe(struct i2c_client *i2c, aic31xx->gpio_reset = devm_gpiod_get_optional(aic31xx->dev, "reset", GPIOD_OUT_LOW); if (IS_ERR(aic31xx->gpio_reset)) { - dev_err(aic31xx->dev, "not able to acquire gpio\n"); + if (PTR_ERR(aic31xx->gpio_reset) != -EPROBE_DEFER) + dev_err(aic31xx->dev, "not able to acquire gpio\n"); return PTR_ERR(aic31xx->gpio_reset); } @@ -1452,7 +1453,9 @@ static int aic31xx_i2c_probe(struct i2c_client *i2c, ARRAY_SIZE(aic31xx->supplies), aic31xx->supplies); if (ret) { - dev_err(aic31xx->dev, "Failed to request supplies: %d\n", ret); + if (ret != -EPROBE_DEFER) + dev_err(aic31xx->dev, + "Failed to request supplies: %d\n", ret); return ret; } -- 2.20.1