summaryrefslogtreecommitdiffstats
path: root/arch/mips/bcm47xx/board.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/mips/bcm47xx/board.c')
-rw-r--r--arch/mips/bcm47xx/board.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/arch/mips/bcm47xx/board.c b/arch/mips/bcm47xx/board.c
index 63979dcec7e8..abfc04ebb5bd 100644
--- a/arch/mips/bcm47xx/board.c
+++ b/arch/mips/bcm47xx/board.c
@@ -181,6 +181,13 @@ struct bcm47xx_board_type_list3 bcm47xx_board_list_board[] __initconst = {
{ {0}, NULL},
};
+/* boardtype, boardrev */
+static const
+struct bcm47xx_board_type_list2 bcm47xx_board_list_board_type_rev[] __initconst = {
+ {{BCM47XX_BOARD_SIEMENS_SE505V2, "Siemens SE505 V2"}, "0x0101", "0x10"},
+ { {0}, NULL},
+};
+
static const
struct bcm47xx_board_type bcm47xx_board_unknown[] __initconst = {
{BCM47XX_BOARD_UNKNOWN, "Unknown Board"},
@@ -274,6 +281,16 @@ static __init const struct bcm47xx_board_type *bcm47xx_board_get_nvram(void)
return &e3->board;
}
}
+
+ if (bcm47xx_nvram_getenv("boardtype", buf1, sizeof(buf1)) >= 0 &&
+ bcm47xx_nvram_getenv("boardrev", buf2, sizeof(buf2)) >= 0 &&
+ bcm47xx_nvram_getenv("boardnum", buf3, sizeof(buf3)) == -ENOENT) {
+ for (e2 = bcm47xx_board_list_board_type_rev; e2->value1; e2++) {
+ if (!strcmp(buf1, e2->value1) &&
+ !strcmp(buf2, e2->value2))
+ return &e2->board;
+ }
+ }
return bcm47xx_board_unknown;
}
OpenPOWER on IntegriCloud