From patchwork Wed Apr 17 19:24:43 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jorge Ramirez-Ortiz X-Patchwork-Id: 162419 Delivered-To: patch@linaro.org Received: by 2002:a02:c6d8:0:0:0:0:0 with SMTP id r24csp5882054jan; Wed, 17 Apr 2019 12:24:52 -0700 (PDT) X-Google-Smtp-Source: APXvYqyB4iQdQ0BwWS+SaaS4CPXiUFnqviod3BPAmQIsiCRrVAFSSp64g9vhP9RsFRIwh7yYXvKC X-Received: by 2002:a63:8f4b:: with SMTP id r11mr965483pgn.271.1555529092573; Wed, 17 Apr 2019 12:24:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555529092; cv=none; d=google.com; s=arc-20160816; b=B/dsCrKhG+t/m/HLa0MKd/SESn5kwZyeKMxWtLT1xTuHJoE1J4Si1Ptx/DFycE2xsx sV+l0Pco4OPLREvyeRzzG6tBTMN37o+ga3zz3vrFUo0rrWjMrYMUl1rIJHmoeNlCprNm qHu9SDPqABVhbmZKidKTIfFs2wisFFRCkznTKVv+QS4By4Zr2J/yCxBzJPvF4wSX2+t7 jCxnaMoj0wOBpgpTLgxYVx1S+E6nmVRBcL8xJUBJn0aASYiB4O3sNOPCe/f57mSwWgda FWNIMLuDbRostNwn/cf25YuLC4OC/iKvV/4qjoSGfinN7GRyYgQGNT4neCIuTicckEXF YPHQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=xbkDshoRwG+I0w+DmgS1Lh94U4IFVKrRkWhOXAIbiIg=; b=G1Sw71ZFDU087cua6fyvouOliHIKJQ029BAvexpW+lWhtCi/ndfohHxCUwWuQZR//z hv8UR7X8hYPSzgNulXBAPbmojOnbxe76je+87mSEiCKoXjOo38owZ4XjYuO3z/l5w8Fr XtInl772p7Tph25iNGPQM33/nSfySgtdCnQhV8ZnY7OCWlQv3V24Gn3Tfm4XHGAUq+aJ Mc+/ww/zZHa53h5A7acnINFSkQOKYp8nJxE5axoN6JmvuX99+ve12EQue0+ZiUtq5N// yCBCzlN729JTzoQAtK0JO9rYywPte/IZW5c/BEF6/T6HKlRLOZzYD9w0UGdxib57OaB2 ijNg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=FNfJ5k9a; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 134si52413751pga.249.2019.04.17.12.24.51; Wed, 17 Apr 2019 12:24:52 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=FNfJ5k9a; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732634AbfDQTYs (ORCPT + 15 others); Wed, 17 Apr 2019 15:24:48 -0400 Received: from mail-wr1-f47.google.com ([209.85.221.47]:34358 "EHLO mail-wr1-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730230AbfDQTYs (ORCPT ); Wed, 17 Apr 2019 15:24:48 -0400 Received: by mail-wr1-f47.google.com with SMTP id w16so3461023wrl.1 for ; Wed, 17 Apr 2019 12:24:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=xbkDshoRwG+I0w+DmgS1Lh94U4IFVKrRkWhOXAIbiIg=; b=FNfJ5k9aN8Zj682O9MfPTUexqXnljpSE+IcdsbyHR8l2Bnzxzvg4S8Uo5wSntA01mS G2q1ycJGyJz7dZR5V7jZJtnYFQbFl4KGrsKqew9O3m7FJpxIKfBxQLMLwj80+I+GxCK8 Z3cRfzvNHpsG8qtuH5QkWb0fCFOOm6rxampqAk+GWH7ioBIzn4x4H16z10fV6jLIP8hk 23AAkndgENtkGk3VL4KvGyn4ROjQ5IBnxpaGopwqSQLaXVjbZB2LzPxdC42JyHCnE12o UFF5qnlNr4nXFQQQUqGNQpoUBI+x+fSLLUvkCgsfMPXC+DRiY//E2uxCVBySEu7a+Y/y nKrg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=xbkDshoRwG+I0w+DmgS1Lh94U4IFVKrRkWhOXAIbiIg=; b=r4mW/NjbQ9XxsiCl0oknOrMVnwyEBm4jCiOc4v8wa/RwHLJh77QdvirZkN+G1s5HoG 6JnRjN5R3aeWvo+mSJMDRLr8ejkUa0sp4AvWKSkamNOTrK7dhcGv27hS6d20vEJIPLTj r2S6ZHAJoRal3hTUY8eb7sJ6607YPrg4gE0gV1bgvM73Ve7SsLtrJeqTIdn6cnGEmwpq 4dDuERK/XqW9cLiFxChlK3rKmdHRammcF/z/a+qIqF/IaHYnXZBrQsaJMtb4pAN2fYGs y7MFnfaudmcJ7wItug9jzPjjqHsZdeInaODhoiblWl9aK4oGNH4STWZhM+AAkPq45O+0 pgfQ== X-Gm-Message-State: APjAAAXhLC4zyujVO4WknWhFxwy2sTAnQQqRHyrCbKnSEKfJRUJhyC0O gFoRNFcoLiURnXNf/N+Vy1hiBw== X-Received: by 2002:adf:f390:: with SMTP id m16mr4529765wro.25.1555529086982; Wed, 17 Apr 2019 12:24:46 -0700 (PDT) Received: from localhost.localdomain (200.red-83-34-200.dynamicip.rima-tde.net. [83.34.200.200]) by smtp.gmail.com with ESMTPSA id y9sm95076745wrn.18.2019.04.17.12.24.45 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 17 Apr 2019 12:24:46 -0700 (PDT) From: Jorge Ramirez-Ortiz To: jorge.ramirez-ortiz@linaro.org, lgirdwood@gmail.com, broonie@kernel.org Cc: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, khasim.mohammed@linaro.org Subject: [PATCH v2] regulator: core: do not report EPROBE_DEFER as error but as debug Date: Wed, 17 Apr 2019 21:24:43 +0200 Message-Id: <20190417192443.6501-1-jorge.ramirez-ortiz@linaro.org> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Temporary failures to get a regulator (EPROBE_DEFER) should be logged as debug information instead of errors. Signed-off-by: Jorge Ramirez-Ortiz --- drivers/regulator/core.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) -- 2.21.0 diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c index 186a37675b50..a2725269a94a 100644 --- a/drivers/regulator/core.c +++ b/drivers/regulator/core.c @@ -4342,8 +4342,6 @@ 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); consumers[i].consumer = NULL; goto err; } @@ -4352,6 +4350,13 @@ int regulator_bulk_get(struct device *dev, int num_consumers, return 0; err: + if (ret != -EPROBE_DEFER) + dev_err(dev, "Failed to get supply '%s': %d\n", + consumers[i].supply, ret); + else + dev_dbg(dev, "Failed to get supply '%s', deferring\n", + consumers[i].supply); + while (--i >= 0) regulator_put(consumers[i].consumer);