From 7428f55c94ac51214038a3882630ddb89520e42e Mon Sep 17 00:00:00 2001 From: Peng Fan Date: Tue, 27 Jan 2015 10:14:03 +0800 Subject: pmic:pfuze implement pmic_mode_init This patch is to implement pmic_mode_init function, and add prototype in header file. This function is to set switching mode for pmic buck regulators to improve system efficiency. Mode: OFF: The regulator is switched off and the output voltage is discharged. PFM: In this mode, the regulator is always in PFM mode, which is useful at light loads for optimized efficiency. PWM: In this mode, the regulator is always in PWM mode operation regardless of load conditions. APS: In this mode, the regulator moves automatically between pulse skipping mode and PWM mode depending on load conditions. Signed-off-by: Peng Fan Acked-by: Przemyslaw Marczak --- board/freescale/common/pfuze.c | 38 ++++++++++++++++++++++++++++++++++++++ board/freescale/common/pfuze.h | 1 + 2 files changed, 39 insertions(+) (limited to 'board') diff --git a/board/freescale/common/pfuze.c b/board/freescale/common/pfuze.c index 2cd17944298..4980bf7b008 100644 --- a/board/freescale/common/pfuze.c +++ b/board/freescale/common/pfuze.c @@ -5,9 +5,47 @@ */ #include +#include #include #include +int pfuze_mode_init(struct pmic *p, u32 mode) +{ + unsigned char offset, i, switch_num; + u32 id, ret; + + pmic_reg_read(p, PFUZE100_DEVICEID, &id); + id = id & 0xf; + + if (id == 0) { + switch_num = 6; + offset = PFUZE100_SW1CMODE; + } else if (id == 1) { + switch_num = 4; + offset = PFUZE100_SW2MODE; + } else { + printf("Not supported, id=%d\n", id); + return -EINVAL; + } + + ret = pmic_reg_write(p, PFUZE100_SW1ABMODE, mode); + if (ret < 0) { + printf("Set SW1AB mode error!\n"); + return ret; + } + + for (i = 0; i < switch_num - 1; i++) { + ret = pmic_reg_write(p, offset + i * SWITCH_SIZE, mode); + if (ret < 0) { + printf("Set switch 0x%x mode error!\n", + offset + i * SWITCH_SIZE); + return ret; + } + } + + return ret; +} + struct pmic *pfuze_common_init(unsigned char i2cbus) { struct pmic *p; diff --git a/board/freescale/common/pfuze.h b/board/freescale/common/pfuze.h index 7a4126cca01..53cfc992258 100644 --- a/board/freescale/common/pfuze.h +++ b/board/freescale/common/pfuze.h @@ -8,5 +8,6 @@ #define __PFUZE_BOARD_HELPER__ struct pmic *pfuze_common_init(unsigned char i2cbus); +int pfuze_mode_init(struct pmic *p, u32 mode); #endif -- cgit v1.2.3 From 258c98f8d36ef35d7cb7604847ba73e64d702c2a Mon Sep 17 00:00:00 2001 From: Peng Fan Date: Tue, 27 Jan 2015 10:14:04 +0800 Subject: imx:mx6 set normal APS and standby PFM mode To normal mode, use APS switching mode. To standy mode, use PFM switching mode. Signed-off-by: Peng Fan Acked-by: Przemyslaw Marczak --- board/freescale/mx6qsabreauto/mx6qsabreauto.c | 6 ++++++ board/freescale/mx6sabresd/mx6sabresd.c | 6 +++++- board/freescale/mx6sxsabresd/mx6sxsabresd.c | 6 +++++- 3 files changed, 16 insertions(+), 2 deletions(-) (limited to 'board') diff --git a/board/freescale/mx6qsabreauto/mx6qsabreauto.c b/board/freescale/mx6qsabreauto/mx6qsabreauto.c index a90360f2df9..b76e4eb528a 100644 --- a/board/freescale/mx6qsabreauto/mx6qsabreauto.c +++ b/board/freescale/mx6qsabreauto/mx6qsabreauto.c @@ -29,6 +29,7 @@ #include #include #include +#include #include "../common/pfuze.h" DECLARE_GLOBAL_DATA_PTR; @@ -494,11 +495,16 @@ int board_spi_cs_gpio(unsigned bus, unsigned cs) int power_init_board(void) { struct pmic *p; + unsigned int ret; p = pfuze_common_init(I2C_PMIC); if (!p) return -ENODEV; + ret = pfuze_mode_init(p, APS_PFM); + if (ret < 0) + return ret; + return 0; } diff --git a/board/freescale/mx6sabresd/mx6sabresd.c b/board/freescale/mx6sabresd/mx6sabresd.c index 2f7198d3bfd..bb2dd9624ba 100644 --- a/board/freescale/mx6sabresd/mx6sabresd.c +++ b/board/freescale/mx6sabresd/mx6sabresd.c @@ -631,12 +631,16 @@ int board_init(void) int power_init_board(void) { struct pmic *p; - unsigned int reg; + unsigned int reg, ret; p = pfuze_common_init(I2C_PMIC); if (!p) return -ENODEV; + ret = pfuze_mode_init(p, APS_PFM); + if (ret < 0) + return ret; + /* Increase VGEN3 from 2.5 to 2.8V */ pmic_reg_read(p, PFUZE100_VGEN3VOL, ®); reg &= ~LDO_VOL_MASK; diff --git a/board/freescale/mx6sxsabresd/mx6sxsabresd.c b/board/freescale/mx6sxsabresd/mx6sxsabresd.c index a2c9aae32cd..2ff960e3bb7 100644 --- a/board/freescale/mx6sxsabresd/mx6sxsabresd.c +++ b/board/freescale/mx6sxsabresd/mx6sxsabresd.c @@ -199,12 +199,16 @@ static struct i2c_pads_info i2c_pad_info1 = { int power_init_board(void) { struct pmic *p; - unsigned int reg; + unsigned int reg, ret; p = pfuze_common_init(I2C_PMIC); if (!p) return -ENODEV; + ret = pfuze_mode_init(p, APS_PFM); + if (ret < 0) + return ret; + /* Enable power of VGEN5 3V3, needed for SD3 */ pmic_reg_read(p, PFUZE100_VGEN5VOL, ®); reg &= ~LDO_VOL_MASK; -- cgit v1.2.3 From d9f43c8f5c1d7ed27c99a06be85a4bb64b2c73fb Mon Sep 17 00:00:00 2001 From: Eric Nelson Date: Sun, 15 Feb 2015 14:37:22 -0700 Subject: nitrogen6x: set environment variable reset_cause Signed-off-by: Eric Nelson Acked-by: Stefano Babic --- board/boundary/nitrogen6x/nitrogen6x.c | 1 + 1 file changed, 1 insertion(+) (limited to 'board') diff --git a/board/boundary/nitrogen6x/nitrogen6x.c b/board/boundary/nitrogen6x/nitrogen6x.c index e8ea256be0c..d46b8db232c 100644 --- a/board/boundary/nitrogen6x/nitrogen6x.c +++ b/board/boundary/nitrogen6x/nitrogen6x.c @@ -1018,5 +1018,6 @@ int misc_init_r(void) #ifdef CONFIG_CMD_BMODE add_board_boot_modes(board_boot_modes); #endif + setenv_hex("reset_cause", get_imx_reset_cause()); return 0; } -- cgit v1.2.3 From 5df3d19b1925ea63075664878fad84eeef28ea3e Mon Sep 17 00:00:00 2001 From: Soeren Moch Date: Fri, 23 Jan 2015 19:03:37 +0100 Subject: board: tbs2910: Gate clock when switching async clock muxes According to the i.MX6Q Reference Manual, clocks must be gated when switching input clocks of async clock muxes. So use clock gates. Avoid ldb_di0_ipu clock, because there is no clock gate for this signal. There have never been any complaints about problems with the old code, but the new approach is in line with the recommendations in the manual. Signed-off-by: Soeren Moch --- board/tbs/tbs2910/tbs2910.c | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) (limited to 'board') diff --git a/board/tbs/tbs2910/tbs2910.c b/board/tbs/tbs2910/tbs2910.c index dfa430e4ab6..42b166d47e3 100644 --- a/board/tbs/tbs2910/tbs2910.c +++ b/board/tbs/tbs2910/tbs2910.c @@ -326,21 +326,25 @@ static void setup_display(void) reg &= ~BM_ANADIG_PLL_VIDEO_BYPASS; writel(reg, &ccm->analog_pll_video); - /* select video pll for ldb_di0_clk */ - reg = readl(&ccm->cs2cdr); - reg &= ~(MXC_CCM_CS2CDR_LDB_DI0_CLK_SEL_MASK); - writel(reg, &ccm->cs2cdr); + /* gate ipu1_di0_clk */ + reg = readl(&ccm->CCGR3); + reg &= ~MXC_CCM_CCGR3_LDB_DI0_MASK; + writel(reg, &ccm->CCGR3); - /* select ldb_di0_clk / 7 for ldb_di0_ipu_clk */ - reg = readl(&ccm->cscmr2); - reg |= MXC_CCM_CSCMR2_LDB_DI0_IPU_DIV; - writel(reg, &ccm->cscmr2); - - /* select ldb_di0_ipu_clk for ipu1_di0_clk -> 65MHz pixclock */ + /* select video_pll clock / 7 for ipu1_di0_clk -> 65MHz pixclock */ reg = readl(&ccm->chsccdr); - reg |= (CHSCCDR_CLK_SEL_LDB_DI0 - << MXC_CCM_CHSCCDR_IPU1_DI0_CLK_SEL_OFFSET); + reg &= ~(MXC_CCM_CHSCCDR_IPU1_DI0_PRE_CLK_SEL_MASK | + MXC_CCM_CHSCCDR_IPU1_DI0_PODF_MASK | + MXC_CCM_CHSCCDR_IPU1_DI0_CLK_SEL_MASK); + reg |= (2 << MXC_CCM_CHSCCDR_IPU1_DI0_PRE_CLK_SEL_OFFSET) | + (6 << MXC_CCM_CHSCCDR_IPU1_DI0_PODF_OFFSET) | + (0 << MXC_CCM_CHSCCDR_IPU1_DI0_CLK_SEL_OFFSET); writel(reg, &ccm->chsccdr); + + /* enable ipu1_di0_clk */ + reg = readl(&ccm->CCGR3); + reg |= MXC_CCM_CCGR3_LDB_DI0_MASK; + writel(reg, &ccm->CCGR3); } #endif /* CONFIG_VIDEO_IPUV3 */ -- cgit v1.2.3 From af38bf6b38eab53343afda2ad124682b27d82e64 Mon Sep 17 00:00:00 2001 From: Peng Fan Date: Thu, 12 Feb 2015 09:36:29 +0800 Subject: imx:mx6slevk implement power init board Implement power_init_board and related I2C interface configuration. After adding this, uboot can successfully detect and configure pmic. " U-Boot 2015.01-00281-ge29eddf (Feb 12 2015 - 09:24:01) CPU: Freescale i.MX6SL rev1.0 at 396 MHz Reset cause: POR Board: MX6SLEVK I2C: ready DRAM: 1 GiB PMIC: PFUZE100 ID=0x10 MMC: FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2 " Signed-off-by: Peng Fan --- board/freescale/mx6slevk/mx6slevk.c | 42 +++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) (limited to 'board') diff --git a/board/freescale/mx6slevk/mx6slevk.c b/board/freescale/mx6slevk/mx6slevk.c index 838ea6c0f0d..c65f72bb158 100644 --- a/board/freescale/mx6slevk/mx6slevk.c +++ b/board/freescale/mx6slevk/mx6slevk.c @@ -13,13 +13,18 @@ #include #include #include +#include #include #include #include #include #include +#include #include #include +#include +#include +#include "../common/pfuze.h" #include #include @@ -40,6 +45,11 @@ DECLARE_GLOBAL_DATA_PTR; #define SPI_PAD_CTRL (PAD_CTL_HYS | PAD_CTL_SPEED_MED | \ PAD_CTL_DSE_40ohm | PAD_CTL_SRE_FAST) +#define I2C_PAD_CTRL (PAD_CTL_PKE | PAD_CTL_PUE | \ + PAD_CTL_PUS_100K_UP | PAD_CTL_SPEED_MED | \ + PAD_CTL_DSE_40ohm | PAD_CTL_HYS | \ + PAD_CTL_ODE | PAD_CTL_SRE_FAST) + #define ETH_PHY_RESET IMX_GPIO_NR(4, 21) int dram_init(void) @@ -221,6 +231,34 @@ int board_mmc_init(bd_t *bis) return 0; } +#ifdef CONFIG_SYS_I2C_MXC +#define PC MUX_PAD_CTRL(I2C_PAD_CTRL) +/* I2C1 for PMIC */ +struct i2c_pads_info i2c_pad_info1 = { + .sda = { + .i2c_mode = MX6_PAD_I2C1_SDA__I2C1_SDA | PC, + .gpio_mode = MX6_PAD_I2C1_SDA__GPIO_3_13 | PC, + .gp = IMX_GPIO_NR(3, 13), + }, + .scl = { + .i2c_mode = MX6_PAD_I2C1_SCL__I2C1_SCL | PC, + .gpio_mode = MX6_PAD_I2C1_SCL__GPIO_3_12 | PC, + .gp = IMX_GPIO_NR(3, 12), + }, +}; + +int power_init_board(void) +{ + struct pmic *p; + + p = pfuze_common_init(I2C_PMIC); + if (!p) + return -ENODEV; + + return pfuze_mode_init(p, APS_PFM); +} +#endif + #ifdef CONFIG_FEC_MXC int board_eth_init(bd_t *bis) { @@ -297,6 +335,10 @@ int board_init(void) /* address of boot parameters */ gd->bd->bi_boot_params = PHYS_SDRAM + 0x100; +#ifdef CONFIG_SYS_I2C_MXC + setup_i2c(0, CONFIG_SYS_I2C_SPEED, 0x7f, &i2c_pad_info1); +#endif + #ifdef CONFIG_FEC_MXC setup_fec(); #endif -- cgit v1.2.3 From 4579dc37c3cce36d9521c26c6e82881393ec769e Mon Sep 17 00:00:00 2001 From: Otavio Salvador Date: Tue, 17 Feb 2015 10:42:46 -0200 Subject: warp: Add initial WaRP Board support The WaRP Board is a Wearable Reference Plaform. The board features: - Freescale i.MX6 SoloLite processor with 512MB of RAM - Freescale FXOS8700CQ 6-axis Xtrinsic sensor - Freescale Kinetis KL16 MCU - Freescale Xtrinsic MMA955xL intelligent motion sensing platform The board implements a hybrid architecture to address the evolving needs of the wearables market. The platform consists of a main board and an example daughtercard with the ability to add additional daughtercards for different usage models. For more information about the project, visit: http://www.warpboard.org/ Signed-off-by: Otavio Salvador Reviewed-by: Marek Vasut Acked-by: Stefano Babic --- board/warp/Kconfig | 12 ++++++ board/warp/MAINTAINERS | 6 +++ board/warp/Makefile | 8 ++++ board/warp/warp.c | 113 +++++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 139 insertions(+) create mode 100644 board/warp/Kconfig create mode 100644 board/warp/MAINTAINERS create mode 100644 board/warp/Makefile create mode 100644 board/warp/warp.c (limited to 'board') diff --git a/board/warp/Kconfig b/board/warp/Kconfig new file mode 100644 index 00000000000..7b569ccb649 --- /dev/null +++ b/board/warp/Kconfig @@ -0,0 +1,12 @@ +if TARGET_WARP + +config SYS_BOARD + default "warp" + +config SYS_SOC + default "mx6" + +config SYS_CONFIG_NAME + default "warp" + +endif diff --git a/board/warp/MAINTAINERS b/board/warp/MAINTAINERS new file mode 100644 index 00000000000..ee2114d0823 --- /dev/null +++ b/board/warp/MAINTAINERS @@ -0,0 +1,6 @@ +WaRP BOARD +M: Otavio Salvador +S: Maintained +F: board/warp/ +F: include/configs/warp.h +F: configs/warp_defconfig diff --git a/board/warp/Makefile b/board/warp/Makefile new file mode 100644 index 00000000000..c555f87397d --- /dev/null +++ b/board/warp/Makefile @@ -0,0 +1,8 @@ +# Copyright (C) 2014 O.S. Systems Software LTDA. +# Copyright (C) 2014 Kynetics LLC. +# Copyright (C) 2014 Revolution Robotics, Inc. +# +# SPDX-License-Identifier: GPL-2.0+ +# + +obj-y := warp.o diff --git a/board/warp/warp.c b/board/warp/warp.c new file mode 100644 index 00000000000..3b275c2ce16 --- /dev/null +++ b/board/warp/warp.c @@ -0,0 +1,113 @@ +/* + * Copyright (C) 2014, 2015 O.S. Systems Software LTDA. + * Copyright (C) 2014 Kynetics LLC. + * Copyright (C) 2014 Revolution Robotics, Inc. + * + * Author: Otavio Salvador + * + * SPDX-License-Identifier: GPL-2.0+ + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +DECLARE_GLOBAL_DATA_PTR; + +#define UART_PAD_CTRL (PAD_CTL_PUS_100K_UP | \ + PAD_CTL_SPEED_MED | PAD_CTL_DSE_40ohm | \ + PAD_CTL_SRE_FAST | PAD_CTL_HYS | \ + PAD_CTL_LVE) + +#define USDHC_PAD_CTRL (PAD_CTL_PUS_22K_UP | \ + PAD_CTL_SPEED_LOW | PAD_CTL_DSE_80ohm | \ + PAD_CTL_SRE_FAST | PAD_CTL_HYS | \ + PAD_CTL_LVE) + +int dram_init(void) +{ + gd->ram_size = get_ram_size((void *)PHYS_SDRAM, PHYS_SDRAM_SIZE); + + return 0; +} + +static void setup_iomux_uart(void) +{ + static iomux_v3_cfg_t const uart1_pads[] = { + MX6_PAD_UART1_TXD__UART1_TXD | MUX_PAD_CTRL(UART_PAD_CTRL), + MX6_PAD_UART1_RXD__UART1_RXD | MUX_PAD_CTRL(UART_PAD_CTRL), + }; + + imx_iomux_v3_setup_multiple_pads(uart1_pads, ARRAY_SIZE(uart1_pads)); +} + +static struct fsl_esdhc_cfg usdhc_cfg[1] = { + {USDHC2_BASE_ADDR}, +}; + +int board_mmc_getcd(struct mmc *mmc) +{ + return 1; /* Assume boot SD always present */ +} + +int board_mmc_init(bd_t *bis) +{ + static iomux_v3_cfg_t const usdhc2_pads[] = { + MX6_PAD_SD2_CLK__USDHC2_CLK | MUX_PAD_CTRL(USDHC_PAD_CTRL), + MX6_PAD_SD2_CMD__USDHC2_CMD | MUX_PAD_CTRL(USDHC_PAD_CTRL), + MX6_PAD_SD2_RST__USDHC2_RST | MUX_PAD_CTRL(USDHC_PAD_CTRL), + MX6_PAD_SD2_DAT0__USDHC2_DAT0 | MUX_PAD_CTRL(USDHC_PAD_CTRL), + MX6_PAD_SD2_DAT1__USDHC2_DAT1 | MUX_PAD_CTRL(USDHC_PAD_CTRL), + MX6_PAD_SD2_DAT2__USDHC2_DAT2 | MUX_PAD_CTRL(USDHC_PAD_CTRL), + MX6_PAD_SD2_DAT3__USDHC2_DAT3 | MUX_PAD_CTRL(USDHC_PAD_CTRL), + MX6_PAD_SD2_DAT4__USDHC2_DAT4 | MUX_PAD_CTRL(USDHC_PAD_CTRL), + MX6_PAD_SD2_DAT5__USDHC2_DAT5 | MUX_PAD_CTRL(USDHC_PAD_CTRL), + MX6_PAD_SD2_DAT6__USDHC2_DAT6 | MUX_PAD_CTRL(USDHC_PAD_CTRL), + MX6_PAD_SD2_DAT7__USDHC2_DAT7 | MUX_PAD_CTRL(USDHC_PAD_CTRL), + }; + + imx_iomux_v3_setup_multiple_pads(usdhc2_pads, ARRAY_SIZE(usdhc2_pads)); + + usdhc_cfg[0].sdhc_clk = mxc_get_clock(MXC_ESDHC2_CLK); + return fsl_esdhc_initialize(bis, &usdhc_cfg[0]); +} + +int board_early_init_f(void) +{ + setup_iomux_uart(); + return 0; +} + +int board_init(void) +{ + /* address of boot parameters */ + gd->bd->bi_boot_params = PHYS_SDRAM + 0x100; + + return 0; +} + +int board_late_init(void) +{ +#ifdef CONFIG_HW_WATCHDOG + hw_watchdog_init(); +#endif + + return 0; +} + +int checkboard(void) +{ + puts("Board: WaRP Board\n"); + + return 0; +} -- cgit v1.2.3 From 86a390d30526ac96ae161fb389c7f151a136208f Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Sat, 21 Feb 2015 17:22:50 -0200 Subject: mx25pdk: Turn on the LCD supply Currently there is no support for MC34704 PMIC in the mainline kernel. Turn on the LCD supply via bootloader for the time being, so that we could use the LCD in the kernel. Signed-off-by: Fabio Estevam --- board/freescale/mx25pdk/mx25pdk.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'board') diff --git a/board/freescale/mx25pdk/mx25pdk.c b/board/freescale/mx25pdk/mx25pdk.c index 71a395c226c..01dac72e85e 100644 --- a/board/freescale/mx25pdk/mx25pdk.c +++ b/board/freescale/mx25pdk/mx25pdk.c @@ -146,8 +146,8 @@ int board_late_init(void) if (!p) return -ENODEV; - /* Turn on Ethernet PHY supply */ - pmic_reg_write(p, MC34704_GENERAL2_REG, ONOFFE); + /* Turn on Ethernet PHY and LCD supplies */ + pmic_reg_write(p, MC34704_GENERAL2_REG, ONOFFE | ONOFFA); return 0; } -- cgit v1.2.3 From 16edd347f0e4e0c77c9a667855e3293b58bb3fda Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Sat, 28 Feb 2015 14:25:46 -0300 Subject: mx6slevk: Provide a proper pad configuration for OTG1_ID pin Pass the same pad configuration as done in the kernel so that OTG1_ID pin can properly work in device mode. Signed-off-by: Fabio Estevam --- board/freescale/mx6slevk/mx6slevk.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'board') diff --git a/board/freescale/mx6slevk/mx6slevk.c b/board/freescale/mx6slevk/mx6slevk.c index c65f72bb158..7c18c90bce9 100644 --- a/board/freescale/mx6slevk/mx6slevk.c +++ b/board/freescale/mx6slevk/mx6slevk.c @@ -50,6 +50,11 @@ DECLARE_GLOBAL_DATA_PTR; PAD_CTL_DSE_40ohm | PAD_CTL_HYS | \ PAD_CTL_ODE | PAD_CTL_SRE_FAST) +#define OTGID_PAD_CTRL (PAD_CTL_PKE | PAD_CTL_PUE | \ + PAD_CTL_PUS_47K_UP | PAD_CTL_SPEED_LOW |\ + PAD_CTL_DSE_80ohm | PAD_CTL_HYS | \ + PAD_CTL_SRE_FAST) + #define ETH_PHY_RESET IMX_GPIO_NR(4, 21) int dram_init(void) @@ -285,7 +290,7 @@ static int setup_fec(void) static iomux_v3_cfg_t const usb_otg_pads[] = { /* OTG1 */ MX6_PAD_KEY_COL4__USB_USBOTG1_PWR | MUX_PAD_CTRL(NO_PAD_CTRL), - MX6_PAD_EPDC_PWRCOM__ANATOP_USBOTG1_ID | MUX_PAD_CTRL(NO_PAD_CTRL), + MX6_PAD_EPDC_PWRCOM__ANATOP_USBOTG1_ID | MUX_PAD_CTRL(OTGID_PAD_CTRL), /* OTG2 */ MX6_PAD_KEY_COL5__USB_USBOTG2_PWR | MUX_PAD_CTRL(NO_PAD_CTRL) }; -- cgit v1.2.3 From 09ac7b5961396ffb8644e180180b33008e0b6b35 Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Sat, 28 Feb 2015 15:16:42 -0300 Subject: warp: Add USB Mass Storage support With UMS support we are able to flash the eMMC from U-boot, which is very convenient. Add UMS support to make the eMMC flashing process easier. Signed-off-by: Fabio Estevam Acked-by: Otavio Salvador --- board/warp/warp.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'board') diff --git a/board/warp/warp.c b/board/warp/warp.c index 3b275c2ce16..21ac5e7d741 100644 --- a/board/warp/warp.c +++ b/board/warp/warp.c @@ -21,6 +21,7 @@ #include #include #include +#include DECLARE_GLOBAL_DATA_PTR; @@ -82,6 +83,11 @@ int board_mmc_init(bd_t *bis) return fsl_esdhc_initialize(bis, &usdhc_cfg[0]); } +int board_usb_phy_mode(int port) +{ + return USB_INIT_DEVICE; +} + int board_early_init_f(void) { setup_iomux_uart(); -- cgit v1.2.3 From 32df39c741788e8637cffe6633d73594b26d70fb Mon Sep 17 00:00:00 2001 From: Stefano Babic Date: Mon, 2 Mar 2015 10:12:13 +0100 Subject: mx5: fix get_reset_cause commit d9f43c8f5c1d7ed27c99a06be85a4bb64b2c73fb sets get_reset_cause() as static, but this conflicts with mx5 where its prototype is in sys_proto.h. Drop it from sys_proto.h and drop print_cpuinfo from mx53_loco, factorizing the call for this board. Signed-off-by: Stefano Babic CC: Jason Liu --- board/freescale/mx53loco/mx53loco.c | 16 ---------------- 1 file changed, 16 deletions(-) (limited to 'board') diff --git a/board/freescale/mx53loco/mx53loco.c b/board/freescale/mx53loco/mx53loco.c index efcf4b390d3..9ece6ecd8ba 100644 --- a/board/freescale/mx53loco/mx53loco.c +++ b/board/freescale/mx53loco/mx53loco.c @@ -366,22 +366,6 @@ int board_early_init_f(void) return 0; } -#if defined(CONFIG_DISPLAY_CPUINFO) -int print_cpuinfo(void) -{ - u32 cpurev; - - cpurev = get_cpu_rev(); - printf("CPU: Freescale i.MX%x family rev%d.%d at %d MHz\n", - (cpurev & 0xFF000) >> 12, - (cpurev & 0x000F0) >> 4, - (cpurev & 0x0000F) >> 0, - mxc_get_clock(MXC_ARM_CLK) / 1000000); - printf("Reset cause: %s\n", get_reset_cause()); - return 0; -} -#endif - /* * Do not overwrite the console * Use always serial for U-Boot console -- cgit v1.2.3