aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2008-12-15 19:18:52 +0000
committerGabor Juhos <juhosg@openwrt.org>2008-12-15 19:18:52 +0000
commit4a51052d7b5b2e38aa649778749e8dee7acc0b03 (patch)
tree73259db4d500115d8e9a18cbd57181bc78b23ab4 /target/linux
parentd49e66360ca32775082cd01203caadaf54f399a3 (diff)
downloadupstream-4a51052d7b5b2e38aa649778749e8dee7acc0b03.tar.gz
upstream-4a51052d7b5b2e38aa649778749e8dee7acc0b03.tar.bz2
upstream-4a51052d7b5b2e38aa649778749e8dee7acc0b03.zip
prepare for RouterStation support
SVN-Revision: 13657
Diffstat (limited to 'target/linux')
-rw-r--r--target/linux/ar71xx/config-2.6.261
-rw-r--r--target/linux/ar71xx/config-2.6.271
-rw-r--r--target/linux/ar71xx/config-2.6.281
-rw-r--r--target/linux/ar71xx/files-2.6.28/arch/mips/include/asm/mach-ar71xx/ar71xx.h1
-rw-r--r--target/linux/ar71xx/files/arch/mips/ar71xx/Kconfig4
-rw-r--r--target/linux/ar71xx/files/arch/mips/ar71xx/Makefile1
-rw-r--r--target/linux/ar71xx/files/arch/mips/ar71xx/mach-routerstation.c37
-rw-r--r--target/linux/ar71xx/files/include/asm-mips/mach-ar71xx/ar71xx.h1
8 files changed, 47 insertions, 0 deletions
diff --git a/target/linux/ar71xx/config-2.6.26 b/target/linux/ar71xx/config-2.6.26
index f15de1dc47..f2e2f170f0 100644
--- a/target/linux/ar71xx/config-2.6.26
+++ b/target/linux/ar71xx/config-2.6.26
@@ -8,6 +8,7 @@ CONFIG_AR71XX_MACH_AP83=y
CONFIG_AR71XX_MACH_AW_NR580=y
CONFIG_AR71XX_MACH_GENERIC=y
CONFIG_AR71XX_MACH_RB_4XX=y
+CONFIG_AR71XX_MACH_ROUTERSTATION=y
CONFIG_AR71XX_MACH_TEW_632BRP=y
CONFIG_AR71XX_MACH_WP543=y
CONFIG_AR71XX_WDT=y
diff --git a/target/linux/ar71xx/config-2.6.27 b/target/linux/ar71xx/config-2.6.27
index 03c73b06d6..b542deb4b0 100644
--- a/target/linux/ar71xx/config-2.6.27
+++ b/target/linux/ar71xx/config-2.6.27
@@ -8,6 +8,7 @@ CONFIG_AR71XX_MACH_AP83=y
CONFIG_AR71XX_MACH_AW_NR580=y
CONFIG_AR71XX_MACH_GENERIC=y
CONFIG_AR71XX_MACH_RB_4XX=y
+CONFIG_AR71XX_MACH_ROUTERSTATION=y
CONFIG_AR71XX_MACH_TEW_632BRP=y
CONFIG_AR71XX_MACH_WP543=y
CONFIG_AR71XX_WDT=y
diff --git a/target/linux/ar71xx/config-2.6.28 b/target/linux/ar71xx/config-2.6.28
index b6133a9a17..c17fe15e76 100644
--- a/target/linux/ar71xx/config-2.6.28
+++ b/target/linux/ar71xx/config-2.6.28
@@ -8,6 +8,7 @@ CONFIG_AR71XX_MACH_AP83=y
CONFIG_AR71XX_MACH_AW_NR580=y
CONFIG_AR71XX_MACH_GENERIC=y
CONFIG_AR71XX_MACH_RB_4XX=y
+CONFIG_AR71XX_MACH_ROUTERSTATION=y
CONFIG_AR71XX_MACH_TEW_632BRP=y
CONFIG_AR71XX_MACH_WP543=y
CONFIG_AR71XX_WDT=y
diff --git a/target/linux/ar71xx/files-2.6.28/arch/mips/include/asm/mach-ar71xx/ar71xx.h b/target/linux/ar71xx/files-2.6.28/arch/mips/include/asm/mach-ar71xx/ar71xx.h
index 42db7cc242..87af166d5e 100644
--- a/target/linux/ar71xx/files-2.6.28/arch/mips/include/asm/mach-ar71xx/ar71xx.h
+++ b/target/linux/ar71xx/files-2.6.28/arch/mips/include/asm/mach-ar71xx/ar71xx.h
@@ -114,6 +114,7 @@ extern unsigned long ar71xx_mach_type;
#define AR71XX_MACH_AW_NR580 6 /* AzureWave AW-NR580 */
#define AR71XX_MACH_AP83 7 /* Atheros AP83 */
#define AR71XX_MACH_TEW_632BRP 8 /* TRENDnet TEW-632BRP */
+#define AR71XX_MACH_ROUTERSTATION 9 /* Ubiquiti RouterStation */
/*
* PLL block
diff --git a/target/linux/ar71xx/files/arch/mips/ar71xx/Kconfig b/target/linux/ar71xx/files/arch/mips/ar71xx/Kconfig
index 7e9b75c5db..d16fdb8240 100644
--- a/target/linux/ar71xx/files/arch/mips/ar71xx/Kconfig
+++ b/target/linux/ar71xx/files/arch/mips/ar71xx/Kconfig
@@ -31,6 +31,10 @@ config AR71XX_MACH_TEW_632BRP
bool "TRENDnet TEW-632BRP support"
default y
+config AR71XX_MACH_ROUTERSTATION
+ bool "Ubiquiti RouterStation support"
+ default y
+
endmenu
endif
diff --git a/target/linux/ar71xx/files/arch/mips/ar71xx/Makefile b/target/linux/ar71xx/files/arch/mips/ar71xx/Makefile
index 37a1ebfb4a..f53dc9daf1 100644
--- a/target/linux/ar71xx/files/arch/mips/ar71xx/Makefile
+++ b/target/linux/ar71xx/files/arch/mips/ar71xx/Makefile
@@ -14,5 +14,6 @@ obj-$(CONFIG_AR71XX_MACH_AP83) += mach-ap83.o
obj-$(CONFIG_AR71XX_MACH_AW_NR580) += mach-aw-nr580.o
obj-$(CONFIG_AR71XX_MACH_GENERIC) += mach-generic.o
obj-$(CONFIG_AR71XX_MACH_RB_4XX) += mach-rb-4xx.o
+obj-$(CONFIG_AR71XX_MACH_ROUTERSTATION) += mach-routerstation.o
obj-$(CONFIG_AR71XX_MACH_TEW_632BRP) += mach-tew-632brp.o
obj-$(CONFIG_AR71XX_MACH_WP543) += mach-wp543.o
diff --git a/target/linux/ar71xx/files/arch/mips/ar71xx/mach-routerstation.c b/target/linux/ar71xx/files/arch/mips/ar71xx/mach-routerstation.c
new file mode 100644
index 0000000000..a8de7117f5
--- /dev/null
+++ b/target/linux/ar71xx/files/arch/mips/ar71xx/mach-routerstation.c
@@ -0,0 +1,37 @@
+/*
+ * Ubiquiti RouterStation support
+ *
+ * Copyright (C) 2008 Gabor Juhos <juhosg@openwrt.org>
+ * Copyright (C) 2008 Imre Kaloz <kaloz@openwrt.org>
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 as published
+ * by the Free Software Foundation.
+ */
+
+#include <linux/platform_device.h>
+#include <linux/spi/spi.h>
+#include <linux/spi/flash.h>
+
+#include <asm/mips_machine.h>
+#include <asm/mach-ar71xx/ar71xx.h>
+#include <asm/mach-ar71xx/pci.h>
+#include <asm/mach-ar71xx/platform.h>
+
+static struct spi_board_info routerstation_spi_info[] = {
+ {
+ .bus_num = 0,
+ .chip_select = 0,
+ .max_speed_hz = 25000000,
+ .modalias = "m25p80",
+ }
+};
+
+static void __init routerstation_setup(void)
+{
+ ar71xx_add_device_spi(NULL, routerstation_spi_info,
+ ARRAY_SIZE(routerstation_spi_info));
+}
+
+MIPS_MACHINE(AR71XX_MACH_ROUTERSTATION, "Ubiquiti RouterStation",
+ routerstation_setup);
diff --git a/target/linux/ar71xx/files/include/asm-mips/mach-ar71xx/ar71xx.h b/target/linux/ar71xx/files/include/asm-mips/mach-ar71xx/ar71xx.h
index 42db7cc242..87af166d5e 100644
--- a/target/linux/ar71xx/files/include/asm-mips/mach-ar71xx/ar71xx.h
+++ b/target/linux/ar71xx/files/include/asm-mips/mach-ar71xx/ar71xx.h
@@ -114,6 +114,7 @@ extern unsigned long ar71xx_mach_type;
#define AR71XX_MACH_AW_NR580 6 /* AzureWave AW-NR580 */
#define AR71XX_MACH_AP83 7 /* Atheros AP83 */
#define AR71XX_MACH_TEW_632BRP 8 /* TRENDnet TEW-632BRP */
+#define AR71XX_MACH_ROUTERSTATION 9 /* Ubiquiti RouterStation */
/*
* PLL block