From: Felix Fietkau Date: Fri, 3 Nov 2006 18:43:51 +0000 (+0000) Subject: fix we800g hardware detection X-Git-Tag: whiterussian_rc6~14 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=fe65a521baca325225684749efe1684e5169ae02;p=openwrt%2Fsvn-archive%2Fopenwrt.git fix we800g hardware detection SVN-Revision: 5423 --- diff --git a/openwrt/target/linux/package/diag/src/diag.c b/openwrt/target/linux/package/diag/src/diag.c index 695f56d6e4..4da257546b 100644 --- a/openwrt/target/linux/package/diag/src/diag.c +++ b/openwrt/target/linux/package/diag/src/diag.c @@ -516,11 +516,12 @@ static struct platform_t __init *platform_detect(void) return &platforms[ASUS_4702]; if ((simple_strtoul(getvar("GemtekPmonVer"), NULL, 0) == 9) && - (simple_strtoul(getvar("et0phyaddr"), NULL, 0) == 30) && - (!strncmp(getvar("ModelId"),"WE800G", 6))) - return &platforms[WR850GV1]; - else - return &platforms[WE800G]; + (simple_strtoul(getvar("et0phyaddr"), NULL, 0) == 30)) { + if (!strncmp(getvar("ModelId"),"WE800G", 6)) + return &platforms[WE800G]; + else + return &platforms[WR850GV1]; + } } if ((buf = (nvram_get("melco_id") ?: nvram_get("buffalo_id")))) {