---- /dev/null
-+++ b/arch/arm/mach-gemini/board-nas4220b.c
-@@ -0,0 +1,160 @@
-+/*
-+ * Support for Raidsonic NAS-4220-B
-+ *
-+ * Copyright (C) 2009 Janos Laube <janos.dev@gmail.com>
-+ *
-+ * based on rut1xx.c
-+ * Copyright (C) 2008 Paulius Zaleckas <paulius.zaleckas@teltonika.lt>
-+ *
-+ * This program is free software; you can redistribute it and/or modify
-+ * it under the terms of the GNU General Public License as published by
-+ * the Free Software Foundation; either version 2 of the License, or
-+ * (at your option) any later version.
-+ */
-+
-+#include <linux/kernel.h>
-+#include <linux/init.h>
-+#include <linux/platform_device.h>
-+#include <linux/leds.h>
-+#include <linux/input.h>
-+#include <linux/gpio_keys.h>
-+#include <linux/mdio-gpio.h>
-+#include <linux/io.h>
-+
-+#include <asm/setup.h>
-+#include <asm/mach-types.h>
-+#include <asm/mach/arch.h>
-+#include <asm/mach/time.h>
-+
-+#include <mach/gmac.h>
-+#include <mach/hardware.h>
-+#include <mach/global_reg.h>
-+
-+#include "common.h"
-+
-+static struct sys_timer ib4220b_timer = {
-+ .init = gemini_timer_init,
-+};
-+
-+static struct gpio_led ib4220b_leds[] = {
-+ {
-+ .name = "nas4220b:orange:hdd",
-+ .default_trigger = "ide-disk",
-+ .gpio = 60,
-+ },
-+ {
-+ .name = "nas4220b:green:os",
-+ .default_trigger = "heartbeat",
-+ .gpio = 62,
-+ },
-+};
-+
-+static struct gpio_led_platform_data ib4220b_leds_data = {
-+ .num_leds = ARRAY_SIZE(ib4220b_leds),
-+ .leds = ib4220b_leds,
-+};
-+
-+static struct platform_device ib4220b_led_device = {
-+ .name = "leds-gpio",
-+ .id = -1,
-+ .dev = {
-+ .platform_data = &ib4220b_leds_data,
-+ },
-+};
-+
-+static struct gpio_keys_button ib4220b_keys[] = {
-+ {
-+ .code = KEY_SETUP,
-+ .gpio = 61,
-+ .active_low = 1,
-+ .desc = "Backup Button",
-+ .type = EV_KEY,
-+ },
-+ {
-+ .code = KEY_RESTART,
-+ .gpio = 63,
-+ .active_low = 1,
-+ .desc = "Softreset Button",
-+ .type = EV_KEY,
-+ },
-+};
-+
-+static struct gpio_keys_platform_data ib4220b_keys_data = {
-+ .buttons = ib4220b_keys,
-+ .nbuttons = ARRAY_SIZE(ib4220b_keys),
-+};
-+
-+static struct platform_device ib4220b_key_device = {
-+ .name = "gpio-keys",
-+ .id = -1,
-+ .dev = {
-+ .platform_data = &ib4220b_keys_data,
-+ },
-+};
-+
-+static struct mdio_gpio_platform_data ib4220b_mdio = {
-+ .mdc = 22,
-+ .mdio = 21,
-+ .phy_mask = ~(1 << 1),
-+};
-+
-+static struct platform_device ib4220b_phy_device = {
-+ .name = "mdio-gpio",
-+ .id = 0,
-+ .dev = {
-+ .platform_data = &ib4220b_mdio,
-+ },
-+};
-+
-+static struct gemini_gmac_platform_data ib4220b_gmac_data = {
-+ .bus_id[0] = "0:01",
-+ .interface[0] = PHY_INTERFACE_MODE_RGMII,
-+};
-+
-+static void __init gmac_ib4220b_init(void)
-+{
-+ unsigned int val;
-+
-+ val = __raw_readl(IO_ADDRESS(GEMINI_GLOBAL_BASE) +
-+ GLOBAL_IO_DRIVING_CTRL);
-+ val |= (0x3 << GMAC0_PADS_SHIFT) | (0x3 << GMAC1_PADS_SHIFT);
-+ __raw_writel(val, IO_ADDRESS(GEMINI_GLOBAL_BASE) +
-+ GLOBAL_IO_DRIVING_CTRL);
-+
-+ val = (0x0 << GMAC0_RXDV_SKEW_SHIFT) | (0xf << GMAC0_RXC_SKEW_SHIFT) |
-+ (0x7 << GMAC0_TXEN_SKEW_SHIFT) | (0xa << GMAC0_TXC_SKEW_SHIFT) |
-+ (0x0 << GMAC1_RXDV_SKEW_SHIFT) | (0xf << GMAC1_RXC_SKEW_SHIFT) |
-+ (0x7 << GMAC1_TXEN_SKEW_SHIFT) | (0xa << GMAC1_TXC_SKEW_SHIFT);
-+ __raw_writel(val, IO_ADDRESS(GEMINI_GLOBAL_BASE) +
-+ GLOBAL_GMAC_CTRL_SKEW_CTRL);
-+
-+ val = __raw_readl(IO_ADDRESS(GEMINI_GLOBAL_BASE) +
-+ GLOBAL_ARBITRATION1_CTRL);
-+ val |= (0x20 << BURST_LENGTH_SHIFT);
-+ __raw_writel(val, IO_ADDRESS(GEMINI_GLOBAL_BASE) +
-+ GLOBAL_ARBITRATION1_CTRL);
-+}
-+
-+static void __init ib4220b_init(void)
-+{
-+ gemini_gpio_init();
-+ gmac_ib4220b_init();
-+ platform_register_uart();
-+ platform_register_usb(0);
-+ platform_register_usb(1);
-+ platform_register_pflash(SZ_16M, NULL, 0);
-+ platform_device_register(&ib4220b_led_device);
-+ platform_device_register(&ib4220b_key_device);
-+ platform_device_register(&ib4220b_phy_device);
-+ platform_register_ethernet(&ib4220b_gmac_data);
-+}
-+
-+MACHINE_START(NAS4220B, "Raidsonic NAS IB-4220-B")
-+ .phys_io = 0x7fffc000,
-+ .io_pg_offst = ((0xffffc000) >> 18) & 0xfffc,
-+ .boot_params = 0x100,
-+ .map_io = gemini_map_io,
-+ .init_irq = gemini_init_irq,
-+ .timer = &ib4220b_timer,
-+ .init_machine = ib4220b_init,
-+MACHINE_END