]> git.sur5r.net Git - u-boot/commitdiff
arm: zynq: Show information about silicon version
authorMichal Simek <michal.simek@xilinx.com>
Fri, 10 Nov 2017 12:01:10 +0000 (13:01 +0100)
committerMichal Simek <michal.simek@xilinx.com>
Wed, 29 Nov 2017 07:02:40 +0000 (08:02 +0100)
Show information about silicon in bootlog.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
board/xilinx/zynq/board.c

index 871e9dcba07fd92c0fcfbc674cacb21af56d3bb7..e59038106aa6409a76b5e330292def7fe7671805 100644 (file)
@@ -11,6 +11,7 @@
 #include <zynqpl.h>
 #include <asm/arch/hardware.h>
 #include <asm/arch/sys_proto.h>
+#include <asm/arch/ps7_init_gpl.h>
 
 DECLARE_GLOBAL_DATA_PTR;
 
@@ -111,7 +112,15 @@ int board_late_init(void)
 #ifdef CONFIG_DISPLAY_BOARDINFO
 int checkboard(void)
 {
+       u32 version = zynq_get_silicon_version();
+
+       version <<= 1;
+       if (version > (PCW_SILICON_VERSION_3 << 1))
+               version += 1;
+
        puts("Board: Xilinx Zynq\n");
+       printf("Silicon: v%d.%d\n", version >> 1, version & 1);
+
        return 0;
 }
 #endif