usb: phy: rcar-gen2-usb: always use 'dev' variable in probe() method
[platform/adaptation/renesas_rcar/renesas_kernel.git] / arch / arm / mach-shmobile / board-armadillo800eva-reference.c
index 03b85fe..36fab42 100644 (file)
 #include <linux/kernel.h>
 #include <linux/gpio.h>
 #include <linux/io.h>
-#include <linux/pinctrl/machine.h>
-#include <mach/common.h>
-#include <mach/r8a7740.h>
+
 #include <asm/mach/arch.h>
 #include <asm/hardware/cache-l2x0.h>
 
+#include "common.h"
+#include "r8a7740.h"
+
 /*
  * CON1                Camera Module
  * CON2                Extension Bus
  * CON22       Serial
  * CON23       LAN
  * CON24       USB3
- * LED1                Camera LED(Yellow)
+ * LED1                Camera LED (Yellow)
  * LED2                Power LED (Green)
- * ED3-LED6    User LED(Yellow)
- * LED7                LAN link LED(Green)
- * LED8                LAN activity LED(Yellow)
+ * LED3-LED6   User LED (Yellow)
+ * LED7                LAN link LED (Green)
+ * LED8                LAN activity LED (Yellow)
  */
 
 /*
  *     usbhsf_power_ctrl()
  */
 
-static const struct pinctrl_map eva_pinctrl_map[] = {
-       /* SCIFA1 */
-       PIN_MAP_MUX_GROUP_DEFAULT("sh-sci.1", "pfc-r8a7740",
-                                 "scifa1_data", "scifa1"),
-};
-
 static void __init eva_clock_init(void)
 {
        struct clk *system      = clk_get(NULL, "system_clk");
@@ -165,35 +160,26 @@ clock_error:
  */
 static void __init eva_init(void)
 {
-
        r8a7740_clock_init(MD_CK0 | MD_CK2);
        eva_clock_init();
 
-       pinctrl_register_mappings(eva_pinctrl_map, ARRAY_SIZE(eva_pinctrl_map));
-       r8a7740_pinmux_init();
-
        r8a7740_meram_workaround();
 
-       /*
-        * Touchscreen
-        * TODO: Move reset GPIO over to .dts when we can reference it
-        */
-       gpio_request_one(166, GPIOF_OUT_INIT_HIGH, NULL); /* TP_RST_B */
-
 #ifdef CONFIG_CACHE_L2X0
        /* Early BRESP enable, Shared attribute override enable, 32K*8way */
        l2x0_init(IOMEM(0xf0002000), 0x40440000, 0x82000fff);
 #endif
 
        r8a7740_add_standard_devices_dt();
+
        r8a7740_pm_init();
 }
 
 #define RESCNT2 IOMEM(0xe6188020)
-static void eva_restart(char mode, const char *cmd)
+static void eva_restart(enum reboot_mode mode, const char *cmd)
 {
        /* Do soft power on reset */
-       writel((1 << 31), RESCNT2);
+       writel(1 << 31, RESCNT2);
 }
 
 static const char *eva_boards_compat_dt[] __initdata = {
@@ -203,10 +189,9 @@ static const char *eva_boards_compat_dt[] __initdata = {
 
 DT_MACHINE_START(ARMADILLO800EVA_DT, "armadillo800eva-reference")
        .map_io         = r8a7740_map_io,
-       .init_early     = r8a7740_init_delay,
+       .init_early     = shmobile_init_delay,
        .init_irq       = r8a7740_init_irq_of,
        .init_machine   = eva_init,
-       .init_time      = shmobile_timer_init,
        .init_late      = shmobile_init_late,
        .dt_compat      = eva_boards_compat_dt,
        .restart        = eva_restart,