diff options
author | John Crispin <john@openwrt.org> | 2008-07-05 23:22:21 +0000 |
---|---|---|
committer | John Crispin <john@openwrt.org> | 2008-07-05 23:22:21 +0000 |
commit | ae1abb1f5808a03acb99dde1565a2ea58f8a5ca9 (patch) | |
tree | 229326e0dd896846a90929816b13da90d22fdb8b /target/linux/ifxmips/files | |
parent | 3e2c38b0fba0839aa7e82d209693282ef976e196 (diff) | |
download | mtk-20170518-ae1abb1f5808a03acb99dde1565a2ea58f8a5ca9.zip mtk-20170518-ae1abb1f5808a03acb99dde1565a2ea58f8a5ca9.tar.gz mtk-20170518-ae1abb1f5808a03acb99dde1565a2ea58f8a5ca9.tar.bz2 |
use boards mac on boards with brn loader, on ifxmips
SVN-Revision: 11674
Diffstat (limited to 'target/linux/ifxmips/files')
-rw-r--r-- | target/linux/ifxmips/files/arch/mips/ifxmips/board.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/target/linux/ifxmips/files/arch/mips/ifxmips/board.c b/target/linux/ifxmips/files/arch/mips/ifxmips/board.c index e4ef454..f0c2f70 100644 --- a/target/linux/ifxmips/files/arch/mips/ifxmips/board.c +++ b/target/linux/ifxmips/files/arch/mips/ifxmips/board.c @@ -259,12 +259,17 @@ static struct ifxmips_board boards[] = int ifxmips_find_brn_block(void){ - unsigned char temp[0]; + unsigned char temp[8]; memcpy_fromio(temp, (void*)KSEG1ADDR(IFXMIPS_FLASH_START + 0x800000 - 0x10000), 8); if(memcmp(temp, "BRN-BOOT", 8) == 0) + { + if(!cmdline_mac) + memcpy_fromio(ifxmips_mii_mac, (void*)KSEG1ADDR(IFXMIPS_FLASH_START + 0x800000 - 0x10000 + 0x16), 6); + cmdline_mac = 1; return 1; - else + } else { return 0; + } } int |