summaryrefslogtreecommitdiffstats
path: root/package/broadcom-diag/src
diff options
context:
space:
mode:
authorflorian <florian@3c298f89-4303-0410-b956-a3cf2f4a3e73>2007-06-18 08:14:11 +0000
committerflorian <florian@3c298f89-4303-0410-b956-a3cf2f4a3e73>2007-06-18 08:14:11 +0000
commit5cfab6a3ce0221e158cfb3a43af13b4d6ba3a70d (patch)
tree3dd42ebce3db5b16dfa67782d6fdaf72c2eefb75 /package/broadcom-diag/src
parent02ccc93bf2bed62dbf199eee14275456581d7927 (diff)
Add support for the D-Link DIR-130/330
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@7660 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/broadcom-diag/src')
-rw-r--r--package/broadcom-diag/src/diag.c35
1 files changed, 35 insertions, 0 deletions
diff --git a/package/broadcom-diag/src/diag.c b/package/broadcom-diag/src/diag.c
index 401adbfd8..0b074673e 100644
--- a/package/broadcom-diag/src/diag.c
+++ b/package/broadcom-diag/src/diag.c
@@ -104,6 +104,10 @@ enum {
/* SimpleTech */
STI_NAS,
+
+ /* D-Link */
+ DIR130,
+ DIR330,
};
static void __init bcm4780_init(void) {
@@ -533,6 +537,30 @@ static struct platform_t __initdata platforms[] = {
},
.platform_init = bcm4780_init,
},
+ /* D-Link */
+ [DIR130] = {
+ .name = "D-Link DIR-130",
+ .buttons = {
+ { .name = "reset", .gpio = 1 << 3},
+ { .name = "reserved", .gpio = 1 << 7},
+ },
+ .leds = {
+ { .name = "diag", .gpio = 1 << 0},
+ { .name = "blue", .gpio = 1 << 6},
+ },
+ },
+ [DIR330] = {
+ .name = "D-Link DIR-330",
+ .buttons = {
+ { .name = "reset", .gpio = 1 << 3},
+ { .name = "reserved", .gpio = 1 << 7},
+ },
+ .leds = {
+ { .name = "diag", .gpio = 1 << 0},
+ { .name = "usb", .gpio = 1 << 4},
+ { .name = "blue", .gpio = 1 << 6},
+ },
+ },
};
static struct platform_t __init *platform_detect(void)
@@ -575,6 +603,13 @@ static struct platform_t __init *platform_detect(void)
if (!strcmp(boardnum, "10496"))
return &platforms[USR5461];
+
+ /* D-Link */
+ if (!strcmp(getvar("model_name"), "DIR-130"))
+ return &platforms[DIR130];
+ if (!strcmp(getvar("model_name"), "DIR-330"))
+ return &platforms[DIR330];
+
} else { /* PMON based - old stuff */
/* Dell TrueMobile 2300 */