summaryrefslogtreecommitdiffstats
path: root/drivers/nvmem
diff options
context:
space:
mode:
authorAxel Lin <axel.lin@ingics.com>2016-02-22 12:23:52 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-03-05 21:20:29 +0100
commitc7e3c5f861f0406aa4bc7ee4af0d789ef4a828db (patch)
tree99a8ceef463336bece4eec1dc1ef09c766e92f0a /drivers/nvmem
parentnvmem: Fix dependencies for !HAS_IOMEM archs (diff)
downloadlinux-c7e3c5f861f0406aa4bc7ee4af0d789ef4a828db.tar.xz
linux-c7e3c5f861f0406aa4bc7ee4af0d789ef4a828db.zip
nvmem: imx-ocotp: Fix return value of imx_ocotp_read
imx_ocotp_read() should return 0 on success. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/nvmem')
-rw-r--r--drivers/nvmem/imx-ocotp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nvmem/imx-ocotp.c b/drivers/nvmem/imx-ocotp.c
index b7971d410b60..d7796eb5421f 100644
--- a/drivers/nvmem/imx-ocotp.c
+++ b/drivers/nvmem/imx-ocotp.c
@@ -51,7 +51,7 @@ static int imx_ocotp_read(void *context, const void *reg, size_t reg_size,
val += 4;
}
- return (i - index) * 4;
+ return 0;
}
static int imx_ocotp_write(void *context, const void *data, size_t count)