summaryrefslogtreecommitdiff
path: root/board/xes/common/board.c
diff options
context:
space:
mode:
authorWolfgang Denk <wd@denx.de>2010-10-25 08:06:52 +0200
committerWolfgang Denk <wd@denx.de>2010-10-25 08:06:52 +0200
commitc163f4478ca72f51b28b55f74addc8fe029d7b83 (patch)
tree914495b79944d55ff161fd7611d46ee7ab523978 /board/xes/common/board.c
parent9038e0e7029e47ec1700128351281225f711545e (diff)
parent6d79c39958aa0245e59f33860cd1ddd589119968 (diff)
downloadu-boot-imx-c163f4478ca72f51b28b55f74addc8fe029d7b83.zip
u-boot-imx-c163f4478ca72f51b28b55f74addc8fe029d7b83.tar.gz
u-boot-imx-c163f4478ca72f51b28b55f74addc8fe029d7b83.tar.bz2
Merge branch 'master' of ssh://gemini/home/wd/git/u-boot/master
Diffstat (limited to 'board/xes/common/board.c')
-rw-r--r--board/xes/common/board.c64
1 files changed, 64 insertions, 0 deletions
diff --git a/board/xes/common/board.c b/board/xes/common/board.c
new file mode 100644
index 0000000..738f0a6
--- /dev/null
+++ b/board/xes/common/board.c
@@ -0,0 +1,64 @@
+/*
+ * Copyright 2009 Extreme Engineering Solutions, Inc.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ */
+
+#include <common.h>
+#include "fsl_8xxx_misc.h"
+
+int checkboard(void)
+{
+ char name[] = CONFIG_SYS_BOARD_NAME;
+ char *s;
+
+#ifdef CONFIG_SYS_FORM_CUSTOM
+ s = "Custom";
+#elif CONFIG_SYS_FORM_6U_CPCI
+ s = "6U CompactPCI";
+#elif CONFIG_SYS_FORM_ATCA_PMC
+ s = "ATCA w/PMC";
+#elif CONFIG_SYS_FORM_ATCA_AMC
+ s = "ATCA w/AMC";
+#elif CONFIG_SYS_FORM_VME
+ s = "VME";
+#elif CONFIG_SYS_FORM_6U_VPX
+ s = "6U VPX";
+#elif CONFIG_SYS_FORM_PMC
+ s = "PMC";
+#elif CONFIG_SYS_FORM_PCI
+ s = "PCI";
+#elif CONFIG_SYS_FORM_3U_CPCI
+ s = "3U CompactPCI";
+#elif CONFIG_SYS_FORM_AMC
+ s = "AdvancedMC";
+#elif CONFIG_SYS_FORM_XMC
+ s = "XMC";
+#elif CONFIG_SYS_FORM_PMC_XMC
+ s = "PMC/XMC";
+#elif CONFIG_SYS_FORM_PCI_EXPRESS
+ s = "PCI Express";
+#elif CONFIG_SYS_FORM_3U_VPX
+ s = "3U VPX";
+#else
+#error "Form factor not defined"
+#endif
+
+ name[strlen(name) - 1] += get_board_derivative();
+ printf("Board: X-ES %s %s SBC\n", name, s);
+
+ /* Display board specific information */
+ puts(" ");
+ if ((s = getenv("board_rev")))
+ printf("Rev %s, ", s);
+ if ((s = getenv("serial#")))
+ printf("Serial# %s, ", s);
+ if ((s = getenv("board_cfg")))
+ printf("Cfg %s", s);
+ puts("\n");
+
+ return 0;
+}