CONFIG_AG71XX=y
CONFIG_AG71XX_AR8216_SUPPORT=y
# CONFIG_AG71XX_DEBUG is not set
+CONFIG_AR71XX_DEV_M25P80=y
CONFIG_AR71XX_MACH_AP81=y
CONFIG_AR71XX_MACH_AP83=y
CONFIG_AR71XX_MACH_AW_NR580=y
# CONFIG_AG71XX_DEBUG is not set
# CONFIG_ALCHEMY_GPIO_INDIRECT is not set
# CONFIG_AR7 is not set
+CONFIG_AR71XX_DEV_M25P80=y
CONFIG_AR71XX_MACH_AP81=y
CONFIG_AR71XX_MACH_AP83=y
CONFIG_AR71XX_MACH_AW_NR580=y
# CONFIG_AG71XX_DEBUG is not set
# CONFIG_ALCHEMY_GPIO_INDIRECT is not set
# CONFIG_AR7 is not set
+CONFIG_AR71XX_DEV_M25P80=y
CONFIG_AR71XX_MACH_AP81=y
CONFIG_AR71XX_MACH_AP83=y
CONFIG_AR71XX_MACH_AW_NR580=y
config AR71XX_MACH_AP81
bool "Atheros AP81 board support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_AP83
config AR71XX_MACH_DIR_825_B1
bool "D-Link DIR-825 rev. B1 board support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_PB42
bool "Atheros PB42 board support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_PB44
config AR71XX_MACH_AW_NR580
bool "AzureWave AW-NR580 board support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_GENERIC
config AR71XX_MACH_WP543
bool "Compex WP543/WPJ543 board support"
select MYLOADER
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_WRT160NL
bool "Linksys WRT160NL board support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_WRT400N
bool "Linksys WRT400N board support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_RB_4XX
config AR71XX_MACH_WNDR3700
bool "NETGEAR WNDR3700 board support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_WNR2000
bool "NETGEAR WNR2000 board support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_MZK_W04NU
bool "Planex MZK-W04NU board support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_MZK_W300NH
bool "Planex MZK-W300NH board support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_TL_WR741ND
bool "TP-LINK TL-WR741ND support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_TL_WR941ND
bool "TP-LINK TL-WR941ND support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_TL_WR1043ND
bool "TP-LINK TL-WR1043ND support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_TEW_632BRP
bool "TRENDnet TEW-632BRP support"
+ select AR71XX_DEV_M25P80
default y
config AR71XX_MACH_UBNT
bool "Ubiquiti AR71xx based boards support"
+ select AR71XX_DEV_M25P80
default y
endmenu
+config AR71XX_DEV_M25P80
+ def_bool n
+
endif
obj-$(CONFIG_EARLY_PRINTK) += early_printk.o
obj-$(CONFIG_PCI) += pci.o
+obj-$(CONFIG_AR71XX_DEV_M25P80) += dev-m25p80.o
+
obj-$(CONFIG_AR71XX_MACH_AP81) += mach-ap81.o
obj-$(CONFIG_AR71XX_MACH_AP83) += mach-ap83.o
obj-$(CONFIG_AR71XX_MACH_AW_NR580) += mach-aw-nr580.o
--- /dev/null
+/*
+ * Copyright (C) 2009 Gabor Juhos <juhosg@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/init.h>
+#include <linux/spi/spi.h>
+#include <linux/spi/flash.h>
+
+#include "devices.h"
+#include "dev-m25p80.h"
+
+static struct spi_board_info ar71xx_spi_info[] = {
+ {
+ .bus_num = 0,
+ .chip_select = 0,
+ .max_speed_hz = 25000000,
+ .modalias = "m25p80",
+ }
+};
+
+void __init ar71xx_add_device_m25p80(struct flash_platform_data *pdata)
+{
+ ar71xx_spi_info[0].platform_data = pdata;
+ ar71xx_add_device_spi(NULL, ar71xx_spi_info,
+ ARRAY_SIZE(ar71xx_spi_info));
+}
--- /dev/null
+/*
+ * Copyright (C) 2009 Gabor Juhos <juhosg@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.
+ */
+
+#ifndef _AR71XX_DEV_M25P80_H
+#define _AR71XX_DEV_M25P80_H
+
+#include <linux/spi/flash.h>
+
+void ar71xx_add_device_m25p80(struct flash_platform_data *pdata) __init;
+
+#endif /* _AR71XX_DEV_M25P80_H */
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <asm/mips_machine.h>
#include <asm/mach-ar71xx/ar71xx.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define AP81_GPIO_LED_STATUS 1
#define AP81_GPIO_LED_AOSS 3
#endif
};
-static struct spi_board_info ap81_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &ap81_flash_data,
- }
-};
-
static struct gpio_led ap81_leds_gpio[] __initdata = {
{
.name = "ap81:green:status",
ar71xx_add_device_usb();
- ar71xx_add_device_spi(NULL, ap81_spi_info,
- ARRAY_SIZE(ap81_spi_info));
+ ar71xx_add_device_m25p80(&ap81_flash_data);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(ap81_leds_gpio),
ap81_leds_gpio);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <asm/mips_machine.h>
#include <asm/mach-ar71xx/pci.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define AW_NR580_GPIO_LED_READY_RED 0
#define AW_NR580_GPIO_LED_WLAN 1
#define AW_NR580_BUTTONS_POLL_INTERVAL 20
-static struct spi_board_info aw_nr580_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- }
-};
-
static struct gpio_led aw_nr580_leds_gpio[] __initdata = {
{
.name = "aw-nr580:red:ready",
ar71xx_pci_init(ARRAY_SIZE(aw_nr580_pci_irqs), aw_nr580_pci_irqs);
- ar71xx_add_device_spi(NULL, aw_nr580_spi_info,
- ARRAY_SIZE(aw_nr580_spi_info));
+ ar71xx_add_device_m25p80(NULL);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(aw_nr580_leds_gpio),
aw_nr580_leds_gpio);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <linux/pci.h>
#include <linux/ath9k_platform.h>
#include <asm/mach-ar71xx/pci.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define DIR825B1_GPIO_LED_BLUE_USB 0
#define DIR825B1_GPIO_LED_ORANGE_POWER 1
#endif
};
-static struct spi_board_info dir825b1_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &dir825b1_flash_data,
- }
-};
-
static struct gpio_led dir825b1_leds_gpio[] __initdata = {
{
.name = "dir825b1:blue:usb",
ar71xx_add_device_eth(0);
ar71xx_add_device_eth(1);
- ar71xx_add_device_spi(NULL, dir825b1_spi_info,
- ARRAY_SIZE(dir825b1_spi_info));
+ ar71xx_add_device_m25p80(&dir825b1_flash_data);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(dir825b1_leds_gpio),
dir825b1_leds_gpio);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <asm/mips_machine.h>
#include <asm/mach-ar71xx/ar71xx.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define MZK_W300NH_GPIO_LED_STATUS 1
#define MZK_W300NH_GPIO_LED_WPS 3
#endif
};
-static struct spi_board_info mzk_w300nh_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &mzk_w300nh_flash_data,
- }
-};
-
static struct gpio_led mzk_w300nh_leds_gpio[] __initdata = {
{
.name = "mzk-w300nh:green:status",
ar71xx_add_device_eth(0);
ar71xx_add_device_eth(1);
- ar71xx_add_device_spi(NULL, mzk_w300nh_spi_info,
- ARRAY_SIZE(mzk_w300nh_spi_info));
+ ar71xx_add_device_m25p80(&mzk_w300nh_flash_data);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(mzk_w300nh_leds_gpio),
mzk_w300nh_leds_gpio);
#include <linux/bitops.h>
#include <linux/input.h>
#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 "devices.h"
+#include "dev-m25p80.h"
#define PB42_BUTTONS_POLL_INTERVAL 20
#define PB42_GPIO_BTN_SW4 8
#define PB42_GPIO_BTN_SW5 3
-static struct spi_board_info pb42_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- }
-};
-
static struct ar71xx_pci_irq pb42_pci_irqs[] __initdata = {
{
.slot = 0,
static void __init pb42_init(void)
{
- ar71xx_add_device_spi(NULL, pb42_spi_info,
- ARRAY_SIZE(pb42_spi_info));
+ ar71xx_add_device_m25p80(NULL);
ar71xx_add_device_mdio(~PB42_MDIO_PHYMASK);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <asm/mips_machine.h>
-
#include <asm/mach-ar71xx/ar71xx.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define TEW_632BRP_GPIO_LED_STATUS 1
#define TEW_632BRP_GPIO_LED_WPS 3
#endif
};
-static struct spi_board_info tew_632brp_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &tew_632brp_flash_data,
- }
-};
-
static struct gpio_led tew_632brp_leds_gpio[] __initdata = {
{
.name = "tew-632brp:green:status",
ar71xx_add_device_eth(0);
ar71xx_add_device_eth(1);
- ar71xx_add_device_spi(NULL, tew_632brp_spi_info,
- ARRAY_SIZE(tew_632brp_spi_info));
+ ar71xx_add_device_m25p80(&tew_632brp_flash_data);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(tew_632brp_leds_gpio),
tew_632brp_leds_gpio);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <asm/mips_machine.h>
#include <asm/mach-ar71xx/ar71xx.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define TL_WR1043ND_GPIO_LED_SYSTEM 2
#define TL_WR1043ND_GPIO_LED_QSS 5
#endif
};
-static struct spi_board_info tl_wr1043nd_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &tl_wr1043nd_flash_data,
- }
-};
-
static struct gpio_led tl_wr1043nd_leds_gpio[] __initdata = {
{
.name = "tl-wr1043nd:green:system",
ar71xx_add_device_usb();
- ar71xx_add_device_spi(NULL, tl_wr1043nd_spi_info,
- ARRAY_SIZE(tl_wr1043nd_spi_info));
+ ar71xx_add_device_m25p80(&tl_wr1043nd_flash_data);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(tl_wr1043nd_leds_gpio),
tl_wr1043nd_leds_gpio);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <linux/ath9k_platform.h>
#include <asm/mach-ar71xx/pci.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define TL_WR741ND_GPIO_LED_QSS 0
#define TL_WR741ND_GPIO_LED_SYSTEM 1
#endif
};
-static struct spi_board_info tl_wr741nd_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &tl_wr741nd_flash_data,
- }
-};
-
static struct gpio_led tl_wr741nd_leds_gpio[] __initdata = {
{
.name = "tl-wr741nd:green:system",
ar71xx_add_device_eth(1);
ar71xx_add_device_eth(0);
- ar71xx_add_device_spi(NULL, tl_wr741nd_spi_info,
- ARRAY_SIZE(tl_wr741nd_spi_info));
+ ar71xx_add_device_m25p80(&tl_wr741nd_flash_data);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(tl_wr741nd_leds_gpio),
tl_wr741nd_leds_gpio);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <asm/mips_machine.h>
#include <asm/mach-ar71xx/ar71xx.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define TL_WR941ND_GPIO_LED_SYSTEM 2
#define TL_WR941ND_GPIO_LED_QSS 5
#endif
};
-static struct spi_board_info tl_wr941nd_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &tl_wr941nd_flash_data,
- }
-};
-
static struct gpio_led tl_wr941nd_leds_gpio[] __initdata = {
{
.name = "tl-wr941nd:green:system",
ar71xx_add_device_eth(0);
ar71xx_add_device_dsa(0, &tl_wr941nd_dsa_data);
- ar71xx_add_device_spi(NULL, tl_wr941nd_spi_info,
- ARRAY_SIZE(tl_wr941nd_spi_info));
+ ar71xx_add_device_m25p80(&tl_wr941nd_flash_data);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(tl_wr941nd_leds_gpio),
tl_wr941nd_leds_gpio);
#include <linux/pci.h>
#include <linux/platform_device.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <linux/ath9k_platform.h>
#include <asm/mach-ar71xx/pci.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define UBNT_RS_GPIO_LED_RF 2
#define UBNT_RS_GPIO_SW4 8
#define UBNT_BUTTONS_POLL_INTERVAL 20
-static struct spi_board_info ubnt_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- }
-};
-
static struct ar71xx_pci_irq ubnt_pci_irqs[] __initdata = {
{
.slot = 0,
static void __init ubnt_generic_setup(void)
{
- ar71xx_add_device_spi(NULL, ubnt_spi_info,
- ARRAY_SIZE(ubnt_spi_info));
+ ar71xx_add_device_m25p80(NULL);
ar71xx_add_device_gpio_buttons(-1, UBNT_BUTTONS_POLL_INTERVAL,
ARRAY_SIZE(ubnt_gpio_buttons),
ar71xx_set_mac_base(mac);
- ar71xx_add_device_spi(NULL, ubnt_spi_info,
- ARRAY_SIZE(ubnt_spi_info));
+ ar71xx_add_device_m25p80(NULL);
ar71xx_add_device_mdio(~0);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <linux/pci.h>
#include <linux/ath9k_platform.h>
#include <asm/mach-ar71xx/pci.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define WNDR3700_GPIO_LED_WPS_ORANGE 0
#define WNDR3700_GPIO_LED_POWER_ORANGE 1
static inline void wndr3700_pci_init(void) { };
#endif /* CONFIG_PCI */
-static struct spi_board_info wndr3700_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &wndr3700_flash_data,
- }
-};
-
static struct gpio_led wndr3700_leds_gpio[] __initdata = {
{
.name = "wndr3700:green:power",
ar71xx_add_device_usb();
- ar71xx_add_device_spi(NULL, wndr3700_spi_info,
- ARRAY_SIZE(wndr3700_spi_info));
+ ar71xx_add_device_m25p80(&wndr3700_flash_data);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(wndr3700_leds_gpio),
wndr3700_leds_gpio);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <asm/mips_machine.h>
#include <asm/mach-ar71xx/ar71xx.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define WNR2000_GPIO_LED_PWR_GREEN 14
#define WNR2000_GPIO_LED_PWR_AMBER 7
#endif
};
-static struct spi_board_info wnr2000_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &wnr2000_flash_data,
- }
-};
-
static struct gpio_led wnr2000_leds_gpio[] __initdata = {
{
.name = "wnr2000:green:power",
ar71xx_add_device_eth(0);
ar71xx_add_device_eth(1);
- ar71xx_add_device_spi(NULL, wnr2000_spi_info,
- ARRAY_SIZE(wnr2000_spi_info));
+ ar71xx_add_device_m25p80(&wnr2000_flash_data);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(wnr2000_leds_gpio),
wnr2000_leds_gpio);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <asm/mips_machine.h>
#include <asm/mach-ar71xx/pci.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define WP543_GPIO_SW6 2
#define WP543_GPIO_LED_1 3
#define WP543_BUTTONS_POLL_INTERVAL 20
-static struct spi_board_info wp543_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- }
-};
-
static struct ar71xx_pci_irq wp543_pci_irqs[] __initdata = {
{
.slot = 0,
static void __init wp543_setup(void)
{
- ar71xx_add_device_spi(NULL, wp543_spi_info, ARRAY_SIZE(wp543_spi_info));
+ ar71xx_add_device_m25p80(NULL);
ar71xx_add_device_mdio(0xfffffff7);
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <asm/mips_machine.h>
#include <asm/mach-ar71xx/ar71xx.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define WRT160NL_GPIO_LED_POWER 14
#define WRT160NL_GPIO_LED_WPS_AMBER 9
#endif
};
-static struct spi_board_info wrt160nl_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &wrt160nl_flash_data,
- }
-};
-
static struct gpio_led wrt160nl_leds_gpio[] __initdata = {
{
.name = "wrt160nl:blue:power",
ar71xx_add_device_eth(0);
ar71xx_add_device_eth(1);
- ar71xx_add_device_spi(NULL, wrt160nl_spi_info,
- ARRAY_SIZE(wrt160nl_spi_info));
+ ar71xx_add_device_m25p80(&wrt160nl_flash_data);
ar71xx_add_device_usb();
ar91xx_add_device_wmac();
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-#include <linux/spi/spi.h>
-#include <linux/spi/flash.h>
#include <linux/input.h>
#include <asm/mips_machine.h>
#include <asm/mach-ar71xx/ar71xx.h>
#include "devices.h"
+#include "dev-m25p80.h"
#define WRT400N_GPIO_LED_ORANGE 5
#define WRT400N_GPIO_LED_GREEN 4
#endif
};
-static struct spi_board_info wrt400n_spi_info[] = {
- {
- .bus_num = 0,
- .chip_select = 0,
- .max_speed_hz = 25000000,
- .modalias = "m25p80",
- .platform_data = &wrt400n_flash_data,
- }
-};
-
static struct gpio_led wrt400n_leds_gpio[] __initdata = {
{
.name = "wrt400n:green:status",
ar71xx_add_device_eth(0);
ar71xx_add_device_eth(1);
- ar71xx_add_device_spi(NULL, wrt400n_spi_info,
- ARRAY_SIZE(wrt400n_spi_info));
+ ar71xx_add_device_m25p80(&wrt400n_flash_data);
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(wrt400n_leds_gpio),
wrt400n_leds_gpio);