diff options
author | Andrey Smirnov <andrew.smirnov@gmail.com> | 2019-12-02 06:56:03 -0800 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2019-12-04 08:23:14 +0100 |
commit | fd2c41fe29e37df94eccf740c46ee531329ffe9a (patch) | |
tree | 1675a03c7db2ac04af5f3a301f90e98b39ecd66a /arch/arm/mach-imx/vf610.c | |
parent | 9344bf77582c21c7ee086bccd4c00971b95282b8 (diff) | |
download | barebox-fd2c41fe29e37df94eccf740c46ee531329ffe9a.tar.gz barebox-fd2c41fe29e37df94eccf740c46ee531329ffe9a.tar.xz |
ARM: VFxxx: Display UID information on boot
Cc: Chris Healy <cphealy@gmail.com>
Cc: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-imx/vf610.c')
-rw-r--r-- | arch/arm/mach-imx/vf610.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/arm/mach-imx/vf610.c b/arch/arm/mach-imx/vf610.c index b548cbcb5f..2fbd6393ea 100644 --- a/arch/arm/mach-imx/vf610.c +++ b/arch/arm/mach-imx/vf610.c @@ -19,6 +19,7 @@ #include <mach/revision.h> #include <mach/vf610.h> #include <mach/reset-reason.h> +#include <mach/ocotp.h> static const struct imx_reset_reason vf610_reset_reasons[] = { { VF610_SRC_SRSR_POR_RST, RESET_POR, 0 }, @@ -30,6 +31,11 @@ static const struct imx_reset_reason vf610_reset_reasons[] = { { /* sentinel */ } }; +u64 vf610_uid(void) +{ + return imx_ocotp_read_uid(IOMEM(VF610_OCOTP_BASE_ADDR)); +} + int vf610_init(void) { const char *cputypestr; @@ -57,5 +63,7 @@ int vf610_init(void) imx_set_silicon_revision(cputypestr, vf610_cpu_revision()); imx_set_reset_reason(src + IMX_SRC_SRSR, vf610_reset_reasons); + pr_info("%s unique ID: %llx\n", cputypestr, vf610_uid()); + return 0; } |