summaryrefslogtreecommitdiffstats
path: root/drivers/nvmem/Kconfig
diff options
context:
space:
mode:
authorAndrey Smirnov <andrew.smirnov@gmail.com>2018-05-28 21:47:29 -0700
committerSascha Hauer <s.hauer@pengutronix.de>2018-05-31 17:26:49 +0200
commit137e8e3c1748a6ad39201b22316182bd01adb5d5 (patch)
treec0145ef2a89d86b4b12217a5edce886e6462a51b /drivers/nvmem/Kconfig
parentb387db124ec972f2271c50d2eaf29a4d652b29c7 (diff)
downloadbarebox-137e8e3c1748a6ad39201b22316182bd01adb5d5.tar.gz
barebox-137e8e3c1748a6ad39201b22316182bd01adb5d5.tar.xz
i.MX: ocotp: Move OCOTP driver to drivers/nvmem
Move OCOTP driver to drivers/nvmem to be consistent with Linux kerenel. Cc: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Tested-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/nvmem/Kconfig')
-rw-r--r--drivers/nvmem/Kconfig21
1 files changed, 21 insertions, 0 deletions
diff --git a/drivers/nvmem/Kconfig b/drivers/nvmem/Kconfig
index d801cc25af..53086d1aac 100644
--- a/drivers/nvmem/Kconfig
+++ b/drivers/nvmem/Kconfig
@@ -15,4 +15,25 @@ config NVMEM_SNVS_LPGPR
help
If you say yes here you get NVMEM support for the Freescale SNVS
Low Power Generic Purpose Register (LPGPR).
+
+config IMX_OCOTP
+ tristate "i.MX6 On Chip OTP controller"
+ depends on ARCH_IMX6 || ARCH_VF610
+ depends on OFDEVICE
+ help
+ This adds support for the i.MX6 On-Chip OTP controller. Currently the
+ only supported functionality is reading the MAC address and assigning
+ it to an ethernet device.
+
+config IMX_OCOTP_WRITE
+ bool
+ prompt "Enable write support of i.MX6 CPUs OTP fuses"
+ depends on IMX_OCOTP
+ help
+ This adds write support to IMX6 On-Chip OTP registers. Example of set
+ MAC to 12:34:56:78:9A:BC (2 words with address 0x22 (OCOTP_MAC0) and
+ address 0x23 (OCOTP_MAC1)). To calculate the file offset multiply
+ the value of the address by 4.
+ mw -l -d /dev/imx-ocotp 0x8C 0x00001234
+ mw -l -d /dev/imx-ocotp 0x88 0x56789ABC
endif