Merge branch 'linux-next' of git://git.infradead.org/ubifs-2.6
[sfrench/cifs-2.6.git] / arch / arm / mach-omap2 / board-apollon.c
index 170c9681d0939c805b7c6c9cee0ebfeb4891a171..bf1e5d32c2a3415d4efcbf972dd0fb45b5917195 100644 (file)
 #include <linux/err.h>
 #include <linux/clk.h>
 
-#include <asm/arch/hardware.h>
+#include <mach/hardware.h>
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
 #include <asm/mach/flash.h>
 
-#include <asm/arch/gpio.h>
-#include <asm/arch/led.h>
-#include <asm/arch/mux.h>
-#include <asm/arch/usb.h>
-#include <asm/arch/board.h>
-#include <asm/arch/common.h>
-#include <asm/arch/gpmc.h>
-#include <asm/arch/control.h>
+#include <mach/gpio.h>
+#include <mach/led.h>
+#include <mach/mux.h>
+#include <mach/usb.h>
+#include <mach/board.h>
+#include <mach/common.h>
+#include <mach/gpmc.h>
+#include <mach/control.h>
 
 /* LED & Switch macros */
 #define LED0_GPIO13            13
@@ -236,13 +236,13 @@ static inline void __init apollon_init_smc91x(void)
        udelay(100);
 
        omap_cfg_reg(W4__24XX_GPIO74);
-       if (omap_request_gpio(APOLLON_ETHR_GPIO_IRQ) < 0) {
+       if (gpio_request(APOLLON_ETHR_GPIO_IRQ, "SMC91x irq") < 0) {
                printk(KERN_ERR "Failed to request GPIO%d for smc91x IRQ\n",
                        APOLLON_ETHR_GPIO_IRQ);
                gpmc_cs_free(APOLLON_ETH_CS);
                goto out;
        }
-       omap_set_gpio_direction(APOLLON_ETHR_GPIO_IRQ, 1);
+       gpio_direction_input(APOLLON_ETHR_GPIO_IRQ);
 
 out:
        clk_disable(gpmc_fck);
@@ -261,16 +261,6 @@ static struct omap_uart_config apollon_uart_config __initdata = {
        .enabled_uarts = (1 << 0) | (0 << 1) | (0 << 2),
 };
 
-static struct omap_mmc_config apollon_mmc_config __initdata = {
-       .mmc [0] = {
-               .enabled        = 1,
-               .wire4          = 1,
-               .wp_pin         = -1,
-               .power_pin      = -1,
-               .switch_pin     = -1,
-       },
-};
-
 static struct omap_usb_config apollon_usb_config __initdata = {
        .register_dev   = 1,
        .hmc_mode       = 0x14, /* 0:dev 1:host1 2:disable */
@@ -284,7 +274,6 @@ static struct omap_lcd_config apollon_lcd_config __initdata = {
 
 static struct omap_board_config_kernel apollon_config[] = {
        { OMAP_TAG_UART,        &apollon_uart_config },
-       { OMAP_TAG_MMC,         &apollon_mmc_config },
        { OMAP_TAG_USB,         &apollon_usb_config },
        { OMAP_TAG_LCD,         &apollon_lcd_config },
 };
@@ -327,15 +316,15 @@ static void __init apollon_sw_init(void)
        /* Enter SW - Y11 */
        omap_cfg_reg(Y11_242X_GPIO16);
        omap_request_gpio(SW_ENTER_GPIO16);
-       omap_set_gpio_direction(SW_ENTER_GPIO16, 1);
+       gpio_direction_input(SW_ENTER_GPIO16);
        /* Up SW - AA12 */
        omap_cfg_reg(AA12_242X_GPIO17);
        omap_request_gpio(SW_UP_GPIO17);
-       omap_set_gpio_direction(SW_UP_GPIO17, 1);
+       gpio_direction_input(SW_UP_GPIO17);
        /* Down SW - AA8 */
        omap_cfg_reg(AA8_242X_GPIO58);
        omap_request_gpio(SW_DOWN_GPIO58);
-       omap_set_gpio_direction(SW_DOWN_GPIO58, 1);
+       gpio_direction_input(SW_DOWN_GPIO58);
 
        set_irq_type(OMAP_GPIO_IRQ(SW_ENTER_GPIO16), IRQ_TYPE_EDGE_RISING);
        if (request_irq(OMAP_GPIO_IRQ(SW_ENTER_GPIO16), &apollon_sw_interrupt,
@@ -359,9 +348,8 @@ static void __init apollon_usb_init(void)
        /* USB device */
        /* DEVICE_SUSPEND */
        omap_cfg_reg(P21_242X_GPIO12);
-       omap_request_gpio(12);
-       omap_set_gpio_direction(12, 0);         /* OUT */
-       omap_set_gpio_dataout(12, 0);
+       gpio_request(12, "USB suspend");
+       gpio_direction_output(12, 0);
 }
 
 static void __init omap_apollon_init(void)