ar71xx: allow overriding of the lan port names on AP91 based boards
[openwrt/svn-archive/archive.git] / target / linux / ar71xx / files / arch / mips / ar71xx / mach-ap83.c
index fb5d0533c3c648c0c6342471dc10d3e061c1cdaf..72c00163166e733b1ed7c844bb96f92248ffefc9 100644 (file)
 #include <linux/spi/spi_gpio.h>
 #include <linux/spi/vsc7385.h>
 
-#include <asm/mips_machine.h>
 #include <asm/mach-ar71xx/ar71xx.h>
 #include <asm/mach-ar71xx/ar91xx_flash.h>
 
+#include "machtype.h"
 #include "devices.h"
 #include "dev-ar913x-wmac.h"
 #include "dev-gpio-buttons.h"
@@ -120,14 +120,14 @@ static struct gpio_button ap83_gpio_buttons[] __initdata = {
                .desc           = "soft_reset",
                .type           = EV_KEY,
                .code           = BTN_0,
-               .threshold      = 5,
+               .threshold      = 3,
                .gpio           = AP83_GPIO_BTN_RESET,
                .active_low     = 1,
        } , {
                .desc           = "jumpstart",
                .type           = EV_KEY,
                .code           = BTN_1,
-               .threshold      = 5,
+               .threshold      = 3,
                .gpio           = AP83_GPIO_BTN_JUMPSTART,
                .active_low     = 1,
        }
@@ -194,9 +194,9 @@ static struct spi_board_info ap83_spi_info[] = {
 
 static void __init ap83_generic_setup(void)
 {
-       u8 *mac = (u8 *) KSEG1ADDR(0x1fff1000);
+       u8 *eeprom = (u8 *) KSEG1ADDR(0x1fff1000);
 
-       ar71xx_set_mac_base(mac);
+       ar71xx_set_mac_base(eeprom);
 
        ar71xx_add_device_mdio(0xfffffffe);
 
@@ -223,7 +223,7 @@ static void __init ap83_generic_setup(void)
 
        ar71xx_add_device_usb();
 
-       ar913x_add_device_wmac();
+       ar913x_add_device_wmac(eeprom, NULL);
 
        platform_device_register(&ap83_flash_device);
 
@@ -264,4 +264,4 @@ static void __init ap83_setup(void)
        }
 }
 
-MIPS_MACHINE(AR71XX_MACH_AP83, "Atheros AP83", ap83_setup);
+MIPS_MACHINE(AR71XX_MACH_AP83, "AP83", "Atheros AP83", ap83_setup);