1 --- a/arch/arm/mach-kirkwood/Makefile
2 +++ b/arch/arm/mach-kirkwood/Makefile
3 @@ -8,6 +8,7 @@ obj-$(CONFIG_MACH_SHEEVAPLUG) += sheeva
4 obj-$(CONFIG_MACH_ESATA_SHEEVAPLUG) += sheevaplug-setup.o
5 obj-$(CONFIG_MACH_GURUPLUG) += guruplug-setup.o
6 obj-$(CONFIG_MACH_DOCKSTAR) += dockstar-setup.o
7 +obj-$(CONFIG_MACH_ICONNECT) += iconnect-setup.o
8 obj-$(CONFIG_MACH_TS219) += ts219-setup.o tsx1x-common.o
9 obj-$(CONFIG_MACH_TS41X) += ts41x-setup.o tsx1x-common.o
10 obj-$(CONFIG_MACH_OPENRD) += openrd-setup.o
11 --- a/arch/arm/mach-kirkwood/Kconfig
12 +++ b/arch/arm/mach-kirkwood/Kconfig
13 @@ -130,6 +130,12 @@ config MACH_T5325
14 Say 'Y' here if you want your kernel to support the
18 + bool "Iomega iConnect Wireless"
20 + Say 'Y' here if you want your kernel to support the
21 + Iomega iConnect Wireless.
27 +++ b/arch/arm/mach-kirkwood/iconnect-setup.c
30 + * arch/arm/mach-kirkwood/iconnect-setup.c
32 + * Iomega iConnect Wireless
34 + * This file is licensed under the terms of the GNU General Public
35 + * License version 2. This program is licensed "as is" without any
36 + * warranty of any kind, whether express or implied.
39 +#include <linux/kernel.h>
40 +#include <linux/init.h>
41 +#include <linux/platform_device.h>
42 +#include <linux/irq.h>
43 +#include <linux/mtd/partitions.h>
44 +#include <linux/mv643xx_eth.h>
45 +#include <linux/ethtool.h>
46 +#include <linux/gpio.h>
47 +#include <linux/gpio_keys.h>
48 +#include <linux/input.h>
49 +#include <linux/leds.h>
50 +#include <asm/mach-types.h>
51 +#include <asm/mach/arch.h>
52 +#include <mach/kirkwood.h>
56 +static struct mtd_partition iconnect_nand_parts[] = {
63 + .offset = MTDPART_OFS_NXTBLK,
64 + .size = SZ_1M + SZ_2M
67 + .offset = MTDPART_OFS_NXTBLK,
71 + .offset = MTDPART_OFS_NXTBLK,
72 + .size = MTDPART_SIZ_FULL
76 +static struct mv643xx_eth_platform_data iconnect_ge00_data = {
77 + .phy_addr = MV643XX_ETH_PHY_ADDR(11),
80 +static struct gpio_led iconnect_led_pins[] = {
82 + .name = "iconnect:blue:power",
83 + .default_trigger = "default-on",
87 + .name = "iconnect:red:power",
91 + .name = "iconnect:blue:usb1",
95 + .name = "iconnect:blue:usb2",
99 + .name = "iconnect:blue:usb3",
103 + .name = "iconnect:blue:usb4",
107 + .name = "iconnect:blue:otb",
112 +static struct gpio_led_platform_data iconnect_led_data = {
113 + .leds = iconnect_led_pins,
114 + .num_leds = ARRAY_SIZE(iconnect_led_pins),
117 +static struct platform_device iconnect_leds = {
118 + .name = "leds-gpio",
121 + .platform_data = &iconnect_led_data,
125 +#define ICONNECT_GPIO_KEY_RESET 12
126 +#define ICONNECT_GPIO_KEY_OTB 35
128 +#define ICONNECT_SW_RESET 0x00
129 +#define ICONNECT_SW_OTB 0x01
131 +static struct gpio_keys_button iconnect_buttons[] = {
134 + .code = ICONNECT_SW_RESET,
135 + .gpio = ICONNECT_GPIO_KEY_RESET,
136 + .desc = "Reset Button",
138 + .debounce_interval = 100,
142 + .code = ICONNECT_SW_OTB,
143 + .gpio = ICONNECT_GPIO_KEY_OTB,
144 + .desc = "OTB Button",
146 + .debounce_interval = 100,
150 +static struct gpio_keys_platform_data iconnect_button_data = {
151 + .buttons = iconnect_buttons,
152 + .nbuttons = ARRAY_SIZE(iconnect_buttons),
155 +static struct platform_device iconnect_button_device = {
156 + .name = "gpio-keys",
158 + .num_resources = 0,
160 + .platform_data = &iconnect_button_data,
164 +static unsigned int iconnect_mpp_config[] __initdata = {
165 + MPP12_GPIO, /*Input for reset button*/
166 + MPP35_GPIO, /*Input for OTB button*/
177 +static void __init iconnect_init(void)
182 + * Basic setup. Needs to be called early.
185 + kirkwood_mpp_conf(iconnect_mpp_config);
187 + kirkwood_nand_init(ARRAY_AND_SIZE(iconnect_nand_parts), 25);
188 + kirkwood_ehci_init();
190 + kirkwood_ge00_init(&iconnect_ge00_data);
191 + kirkwood_pcie_id(&dev, &rev);
193 + kirkwood_uart0_init();
194 + kirkwood_i2c_init();
196 + platform_device_register(&iconnect_leds);
197 + platform_device_register(&iconnect_button_device);
200 +static int __init iconnect_pci_init(void)
202 + if (machine_is_iconnect())
203 + kirkwood_pcie_init(KW_PCIE0);
207 +subsys_initcall(iconnect_pci_init);
210 +MACHINE_START(ICONNECT, "Iomega iConnect Wireless")
211 + .atag_offset = 0x100,
212 + .init_machine = iconnect_init,
213 + .map_io = kirkwood_map_io,
214 + .init_early = kirkwood_init_early,
215 + .init_irq = kirkwood_init_irq,
216 + .timer = &kirkwood_timer,
217 + .restart = kirkwood_restart,