nvmem: imx-ocotp: Add support for banked OTP addressing
authorBryan O'Donoghue <pure.logic@nexus-software.ie>
Tue, 24 Oct 2017 09:54:29 +0000 (10:54 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 8 Nov 2017 13:19:05 +0000 (14:19 +0100)
commitffd9115f6548c51d347489e76bfb7d10e728f43d
treefca055d4b4e8d1ccb93c29c6633bc283c698aeef
parente20d2b291ba2f5441fd4aacd746c21e60d48b559
nvmem: imx-ocotp: Add support for banked OTP addressing

The i.MX7S/D takes the bank address in the CTRLn.ADDR field and the data
value in one of the DATAx {0, 1, 2, 3} register fields. The current write
routine is based on writing the CTRLn.ADDR field and writing a single DATA
register only.

Fixes: 0642bac7da42 ("nvmem: imx-ocotp: add write support")

Signed-off-by: Bryan O'Donoghue <pure.logic@nexus-software.ie>
Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/nvmem/imx-ocotp.c