summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJerome Brunet <jbrunet@baylibre.com>2018-11-30 11:53:21 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-12-06 15:45:45 +0100
commit8649dbe58d359c46c8779ac43c4651ad5157ac47 (patch)
treec6a92c18d7a951fcd9ba1104f6b24fd6efa6ddf3
parent16688453661b6d5159be558a1f8c1f54463a420f (diff)
downloadblackbird-op-linux-8649dbe58d359c46c8779ac43c4651ad5157ac47.tar.gz
blackbird-op-linux-8649dbe58d359c46c8779ac43c4651ad5157ac47.zip
nvmem: meson-efuse: add error message on user_max failure.
Add an explicit error message when SM_EFUSE_USER_MAX command fails Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/nvmem/meson-efuse.c4
1 files changed, 3 insertions, 1 deletions
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)
OpenPOWER on IntegriCloud