summaryrefslogtreecommitdiff
path: root/board/freescale/ls1088a
diff options
context:
space:
mode:
authorPramod Kumar <pramod.kumar_1@nxp.com>2018-10-12 14:04:27 +0000
committerYork Sun <york.sun@nxp.com>2018-12-06 14:37:19 -0800
commit5b595df338ed1a8ef9ead46c811ba00b29f1185e (patch)
tree0d8340b245f98e0de029a52f92c476b8d0024b55 /board/freescale/ls1088a
parentf668c52033548ad1d6430ebd29cdda713819415f (diff)
armv8: ls1088ardb_pb: Add support for board detection
ls1088ardb-pb and ls1088ardb both boards are ls1088a based soc, board type detection is dynamic at boot time Signed-off-by: Pramod Kumar <pramod.kumar_1@nxp.com> Reviewed-by: York Sun <york.sun@nxp.com>
Diffstat (limited to 'board/freescale/ls1088a')
-rw-r--r--board/freescale/ls1088a/ls1088a.c27
1 files changed, 25 insertions, 2 deletions
diff --git a/board/freescale/ls1088a/ls1088a.c b/board/freescale/ls1088a/ls1088a.c
index 517a8ceed9..1e2ad98c6e 100644
--- a/board/freescale/ls1088a/ls1088a.c
+++ b/board/freescale/ls1088a/ls1088a.c
@@ -1,6 +1,6 @@
// SPDX-License-Identifier: GPL-2.0+
/*
- * Copyright 2017 NXP
+ * Copyright 2017-2018 NXP
*/
#include <common.h>
#include <i2c.h>
@@ -67,6 +67,24 @@ int init_func_vid(void)
}
#endif
+int is_pb_board(void)
+{
+ u8 board_id;
+
+ board_id = QIXIS_READ(id);
+ if (board_id == LS1088ARDB_PB_BOARD)
+ return 1;
+ else
+ return 0;
+}
+
+int fixup_ls1088ardb_pb_banner(void *fdt)
+{
+ fdt_setprop_string(fdt, 0, "model", "LS1088ARDB-PB Board");
+
+ return 0;
+}
+
#if !defined(CONFIG_SPL_BUILD)
int checkboard(void)
{
@@ -79,7 +97,10 @@ int checkboard(void)
#ifdef CONFIG_TARGET_LS1088AQDS
printf("Board: LS1088A-QDS, ");
#else
- printf("Board: LS1088A-RDB, ");
+ if (is_pb_board())
+ printf("Board: LS1088ARDB-PB, ");
+ else
+ printf("Board: LS1088A-RDB, ");
#endif
sw = QIXIS_READ(arch);
@@ -585,6 +606,8 @@ int ft_board_setup(void *blob, bd_t *bd)
if (err)
return err;
#endif
+ if (is_pb_board())
+ fixup_ls1088ardb_pb_banner(blob);
return 0;
}