Skip to content

Commit

Permalink
nvmem: meson-efuse: add error message on user_max failure.
Browse files Browse the repository at this point in the history
Add an explicit error message when SM_EFUSE_USER_MAX command fails

Signed-off-by: Jerome Brunet <[email protected]>
Signed-off-by: Srinivas Kandagatla <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
  • Loading branch information
jbrun3t authored and gregkh committed Dec 6, 2018
1 parent 1668845 commit 8649dbe
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion drivers/nvmem/meson-efuse.c
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down

0 comments on commit 8649dbe

Please sign in to comment.