]> git.sur5r.net Git - u-boot/blobdiff - board/kosagi/novena/novena.c
env: Rename getenv/_f() to env_get()
[u-boot] / board / kosagi / novena / novena.c
index 69f5be3b9c167370e6f83e94424b4e84984c6b3a..f0ace03009e79d9b8d550d242dc1d16739f0c0c8 100644 (file)
@@ -7,7 +7,7 @@
  */
 
 #include <common.h>
-#include <asm/errno.h>
+#include <linux/errno.h>
 #include <asm/gpio.h>
 #include <asm/io.h>
 #include <asm/arch/clock.h>
 #include <asm/arch/iomux.h>
 #include <asm/arch/mxc_hdmi.h>
 #include <asm/arch/sys_proto.h>
-#include <asm/imx-common/boot_mode.h>
-#include <asm/imx-common/iomux-v3.h>
-#include <asm/imx-common/mxc_i2c.h>
-#include <asm/imx-common/sata.h>
-#include <asm/imx-common/video.h>
+#include <asm/mach-imx/boot_mode.h>
+#include <asm/mach-imx/iomux-v3.h>
+#include <asm/mach-imx/mxc_i2c.h>
+#include <asm/mach-imx/sata.h>
+#include <asm/mach-imx/video.h>
 #include <fsl_esdhc.h>
 #include <i2c.h>
 #include <input.h>
@@ -77,7 +77,7 @@ int drv_keyboard_init(void)
        int error;
        struct stdio_dev dev = {
                .name   = "button",
-               .flags  = DEV_FLAGS_INPUT | DEV_FLAGS_SYSTEM,
+               .flags  = DEV_FLAGS_INPUT,
                .start  = novena_gpio_button_init,
                .getc   = novena_gpio_button_getc,
                .tstc   = novena_gpio_button_tstc,
@@ -88,6 +88,7 @@ int drv_keyboard_init(void)
                debug("%s: Cannot set up input\n", __func__);
                return -1;
        }
+       input_add_tables(&button_input, false);
        button_input.read_keys = novena_gpio_button_read_keys;
 
        error = input_stdio_register(&dev);
@@ -166,7 +167,7 @@ int board_init(void)
        /* address of boot parameters */
        gd->bd->bi_boot_params = PHYS_SDRAM + 0x100;
 
-#ifdef CONFIG_CMD_SATA
+#ifdef CONFIG_SATA
        setup_sata();
 #endif
 
@@ -215,7 +216,7 @@ int power_init_board(void)
        /* Set SWBST to 5.0V and enable (for USB) */
        pmic_reg_read(p, PFUZE100_SWBSTCON1, &reg);
        reg &= ~(SWBST_MODE_MASK | SWBST_VOL_MASK);
-       reg |= (SWBST_5_00V | SWBST_MODE_AUTO);
+       reg |= (SWBST_5_00V | (SWBST_MODE_AUTO << SWBST_MODE_SHIFT));
        pmic_reg_write(p, PFUZE100_SWBSTCON1, reg);
 
        return 0;
@@ -239,7 +240,7 @@ int misc_init_r(void)
        int ret;
 
        /* If 'ethaddr' is already set, do nothing. */
-       if (getenv("ethaddr"))
+       if (env_get("ethaddr"))
                return 0;
 
        /* EEPROM is at bus 2. */
@@ -263,7 +264,7 @@ int misc_init_r(void)
        }
 
        /* Set ethernet address from EEPROM. */
-       eth_setenv_enetaddr("ethaddr", data.mac);
+       eth_env_set_enetaddr("ethaddr", data.mac);
 
        return ret;
 }