LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Jerome Brunet <jbrunet@baylibre.com>
To: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>,
Kevin Hilman <khilman@baylibre.com>,
Carlo Caione <carlo@caione.org>
Cc: Jerome Brunet <jbrunet@baylibre.com>,
linux-amlogic@lists.infradead.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: [PATCH 1/4] nvmem: meson-efuse: add error message on user_max failure.
Date: Tue, 30 Oct 2018 11:22:28 +0100 [thread overview]
Message-ID: <20181030102231.4851-2-jbrunet@baylibre.com> (raw)
In-Reply-To: <20181030102231.4851-1-jbrunet@baylibre.com>
Add an explicit error message when SM_EFUSE_USER_MAX command fails
Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
---
drivers/nvmem/meson-efuse.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/nvmem/meson-efuse.c b/drivers/nvmem/meson-efuse.c
index d769840d1e18..40b9df1d030d 100644
--- a/drivers/nvmem/meson-efuse.c
+++ b/drivers/nvmem/meson-efuse.c
@@ -48,8 +48,10 @@ static int meson_efuse_probe(struct platform_device *pdev)
struct nvmem_config *econfig;
unsigned int size;
- if (meson_sm_call(SM_EFUSE_USER_MAX, &size, 0, 0, 0, 0, 0) < 0)
+ if (meson_sm_call(SM_EFUSE_USER_MAX, &size, 0, 0, 0, 0, 0) < 0) {
+ dev_err(dev, "failed to get max user");
return -EINVAL;
+ }
econfig = devm_kzalloc(dev, sizeof(*econfig), GFP_KERNEL);
if (!econfig)
--
2.17.2
next prev parent reply other threads:[~2018-10-30 10:22 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-30 10:22 [PATCH 0/4] nvmem: meson: efuse updates Jerome Brunet
2018-10-30 10:22 ` Jerome Brunet [this message]
2018-11-12 13:08 ` [PATCH 1/4] nvmem: meson-efuse: add error message on user_max failure Srinivas Kandagatla
2018-10-30 10:22 ` [PATCH 2/4] nvmem: meson-efuse: bindings: add peripheral clock Jerome Brunet
2018-11-13 9:05 ` Srinivas Kandagatla
2018-10-30 10:22 ` [PATCH 3/4] arm64: dts: meson-gx: add efuse pclk Jerome Brunet
2018-10-30 10:22 ` [PATCH 4/4] nvmem: meson-efuse: add peripheral clock Jerome Brunet
2018-11-13 9:06 ` Srinivas Kandagatla
2018-11-12 13:08 ` [PATCH 0/4] nvmem: meson: efuse updates Srinivas Kandagatla
2018-11-12 13:28 ` jbrunet
2018-11-12 13:34 ` Srinivas Kandagatla
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20181030102231.4851-2-jbrunet@baylibre.com \
--to=jbrunet@baylibre.com \
--cc=carlo@caione.org \
--cc=devicetree@vger.kernel.org \
--cc=khilman@baylibre.com \
--cc=linux-amlogic@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=srinivas.kandagatla@linaro.org \
--subject='Re: [PATCH 1/4] nvmem: meson-efuse: add error message on user_max failure.' \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).