diff options
author | Tom Rini <trini@konsulko.com> | 2017-09-01 10:40:59 -0400 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2017-09-01 10:40:59 -0400 |
commit | 6aee2ab68c362ace5a59f89a63abed82e0bf19e5 (patch) | |
tree | 0b76045a178e9c0ed61e141bd8dfb3e34e4e86a9 /arch | |
parent | 4109d702934c361b2ae2a5ad34f4dfee708cc214 (diff) | |
parent | 63af4b0ad0666e0797306593813b6272e1995bde (diff) | |
download | u-boot-6aee2ab68c362ace5a59f89a63abed82e0bf19e5.zip u-boot-6aee2ab68c362ace5a59f89a63abed82e0bf19e5.tar.gz u-boot-6aee2ab68c362ace5a59f89a63abed82e0bf19e5.tar.bz2 |
Merge git://git.denx.de/u-boot-imx
Signed-off-by: Tom Rini <trini@konsulko.com>
Conflicts:
configs/imx6qdl_icore_mmc_defconfig
configs/imx6qdl_icore_rqs_defconfig
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/include/asm/arch-mx35/mmc_host_def.h | 18 | ||||
-rw-r--r-- | arch/arm/include/asm/arch-mx5/iomux-mx51.h | 7 | ||||
-rw-r--r-- | arch/arm/include/asm/arch-mxs/iomux-mx23.h | 7 | ||||
-rw-r--r-- | arch/arm/include/asm/arch-mxs/iomux-mx28.h | 7 | ||||
-rw-r--r-- | arch/arm/include/asm/mach-imx/sys_proto.h | 9 | ||||
-rw-r--r-- | arch/arm/mach-imx/mx6/soc.c | 19 | ||||
-rw-r--r-- | arch/arm/mach-imx/mx7/psci-mx7.c | 7 | ||||
-rw-r--r-- | arch/arm/mach-imx/mx7/psci.S | 7 | ||||
-rw-r--r-- | arch/arm/mach-imx/spl.c | 20 | ||||
-rw-r--r-- | arch/arm/mach-imx/timer.c | 3 |
10 files changed, 63 insertions, 41 deletions
diff --git a/arch/arm/include/asm/arch-mx35/mmc_host_def.h b/arch/arm/include/asm/arch-mx35/mmc_host_def.h index 775b955..0775511 100644 --- a/arch/arm/include/asm/arch-mx35/mmc_host_def.h +++ b/arch/arm/include/asm/arch-mx35/mmc_host_def.h @@ -3,23 +3,7 @@ * Texas Instruments, <www.ti.com> * Syed Mohammed Khasim <khasim@ti.com> * - * See file CREDITS for list of people who contributed to this - * project. - * - * 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's version 2 of - * the License. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, - * MA 02111-1307 USA + * SPDX-License-Identifier: GPL-2.0 */ #ifndef MMC_HOST_DEF_H diff --git a/arch/arm/include/asm/arch-mx5/iomux-mx51.h b/arch/arm/include/asm/arch-mx5/iomux-mx51.h index 5c636ac..522512e 100644 --- a/arch/arm/include/asm/arch-mx5/iomux-mx51.h +++ b/arch/arm/include/asm/arch-mx5/iomux-mx51.h @@ -3,12 +3,7 @@ * Copyright (C) 2010 Freescale Semiconductor, Inc. * Copyright (C) 2009-2012 Genesi USA, Inc. * - * The code contained herein is licensed under the GNU General Public - * License. You may obtain a copy of the GNU General Public License - * Version 2 or later at the following locations: - * - * http://www.opensource.org/licenses/gpl-license.html - * http://www.gnu.org/copyleft/gpl.html + * SPDX-License-Identifier: GPL-2.0+ */ /* diff --git a/arch/arm/include/asm/arch-mxs/iomux-mx23.h b/arch/arm/include/asm/arch-mxs/iomux-mx23.h index 7cb5e71..690929c 100644 --- a/arch/arm/include/asm/arch-mxs/iomux-mx23.h +++ b/arch/arm/include/asm/arch-mxs/iomux-mx23.h @@ -2,12 +2,7 @@ * Copyright (C) 2009-2010 Amit Kucheria <amit.kucheria@canonical.com> * Copyright (C) 2010 Freescale Semiconductor, Inc. * - * The code contained herein is licensed under the GNU General Public - * License. You may obtain a copy of the GNU General Public License - * Version 2 or later at the following locations: - * - * http://www.opensource.org/licenses/gpl-license.html - * http://www.gnu.org/copyleft/gpl.html + * SPDX-License-Identifier: GPL-2.0+ */ #ifndef __MACH_IOMUX_MX23_H__ diff --git a/arch/arm/include/asm/arch-mxs/iomux-mx28.h b/arch/arm/include/asm/arch-mxs/iomux-mx28.h index b42820d..39ea74b 100644 --- a/arch/arm/include/asm/arch-mxs/iomux-mx28.h +++ b/arch/arm/include/asm/arch-mxs/iomux-mx28.h @@ -2,12 +2,7 @@ * Copyright (C) 2009-2010 Amit Kucheria <amit.kucheria@canonical.com> * Copyright (C) 2010 Freescale Semiconductor, Inc. * - * The code contained herein is licensed under the GNU General Public - * License. You may obtain a copy of the GNU General Public License - * Version 2 or later at the following locations: - * - * http://www.opensource.org/licenses/gpl-license.html - * http://www.gnu.org/copyleft/gpl.html + * SPDX-License-Identifier: GPL-2.0+ */ #ifndef __MACH_IOMUX_MX28_H__ diff --git a/arch/arm/include/asm/mach-imx/sys_proto.h b/arch/arm/include/asm/mach-imx/sys_proto.h index 046df62..970c4ca 100644 --- a/arch/arm/include/asm/mach-imx/sys_proto.h +++ b/arch/arm/include/asm/mach-imx/sys_proto.h @@ -69,8 +69,13 @@ enum imx6_bmode_emi { enum imx6_bmode { IMX6_BMODE_EMI, - IMX6_BMODE_UART, +#if defined(CONFIG_MX6UL) || defined(CONFIG_MX6ULL) + IMX6_BMODE_QSPI, + IMX6_BMODE_RESERVED, +#else + IMX6_BMODE_RESERVED, IMX6_BMODE_SATA, +#endif IMX6_BMODE_SERIAL_ROM, IMX6_BMODE_SD, IMX6_BMODE_ESD, @@ -85,6 +90,8 @@ static inline u8 imx6_is_bmode_from_gpr9(void) } u32 imx6_src_get_boot_mode(void); +void gpr_init(void); + #endif /* CONFIG_MX6 */ u32 get_nr_cpus(void); diff --git a/arch/arm/mach-imx/mx6/soc.c b/arch/arm/mach-imx/mx6/soc.c index 9ede1f5..b724668 100644 --- a/arch/arm/mach-imx/mx6/soc.c +++ b/arch/arm/mach-imx/mx6/soc.c @@ -551,6 +551,7 @@ void imx_get_mac_from_fuse(int dev_id, unsigned char *mac) } #endif +#ifndef CONFIG_SPL_BUILD /* * cfg_val will be used for * Boot_cfg4[7:0]:Boot_cfg3[7:0]:Boot_cfg2[7:0]:Boot_cfg1[7:0] @@ -577,6 +578,7 @@ const struct boot_mode soc_boot_modes[] = { {"esdhc4", MAKE_CFGVAL(0x40, 0x38, 0x00, 0x00)}, {NULL, 0}, }; +#endif void reset_misc(void) { @@ -681,6 +683,23 @@ void imx_setup_hdmi(void) } #endif +void gpr_init(void) +{ + struct iomuxc *iomux = (struct iomuxc *)IOMUXC_BASE_ADDR; + + /* enable AXI cache for VDOA/VPU/IPU */ + writel(0xF00000CF, &iomux->gpr[4]); + if (is_mx6dqp()) { + /* set IPU AXI-id1 Qos=0x1 AXI-id0/2/3 Qos=0x7 */ + writel(0x77177717, &iomux->gpr[6]); + writel(0x77177717, &iomux->gpr[7]); + } else { + /* set IPU AXI-id0 Qos=0xf(bypass) AXI-id1 Qos=0x7 */ + writel(0x007F007F, &iomux->gpr[6]); + writel(0x007F007F, &iomux->gpr[7]); + } +} + #ifdef CONFIG_IMX_BOOTAUX int arch_auxiliary_core_up(u32 core_id, u32 boot_private_data) { diff --git a/arch/arm/mach-imx/mx7/psci-mx7.c b/arch/arm/mach-imx/mx7/psci-mx7.c index 502552d..7f429b0 100644 --- a/arch/arm/mach-imx/mx7/psci-mx7.c +++ b/arch/arm/mach-imx/mx7/psci-mx7.c @@ -1,3 +1,10 @@ +/* + * Copyright (C) 2015-2016 Freescale Semiconductor, Inc. + * Copyright 2017 NXP + * + * SPDX-License-Identifier: GPL-2.0+ + */ + #include <asm/io.h> #include <asm/psci.h> #include <asm/secure.h> diff --git a/arch/arm/mach-imx/mx7/psci.S b/arch/arm/mach-imx/mx7/psci.S index 96e88d6..fc5eb34 100644 --- a/arch/arm/mach-imx/mx7/psci.S +++ b/arch/arm/mach-imx/mx7/psci.S @@ -1,3 +1,10 @@ +/* + * Copyright (C) 2015-2016 Freescale Semiconductor, Inc. + * Copyright 2017 NXP + * + * SPDX-License-Identifier: GPL-2.0+ + */ + #include <config.h> #include <linux/linkage.h> diff --git a/arch/arm/mach-imx/spl.c b/arch/arm/mach-imx/spl.c index 75698c4..258578a 100644 --- a/arch/arm/mach-imx/spl.c +++ b/arch/arm/mach-imx/spl.c @@ -15,6 +15,8 @@ #include <spl.h> #include <asm/mach-imx/hab.h> +DECLARE_GLOBAL_DATA_PTR; + #if defined(CONFIG_MX6) /* determine boot device from SRC_SBMR1 (BOOT_CFG[4:1]) or SRC_GPR9 register */ u32 spl_boot_device(void) @@ -27,7 +29,7 @@ u32 spl_boot_device(void) * BOOT_MODE - see IMX6DQRM Table 8-1 */ if (((bmode >> 24) & 0x03) == 0x01) /* Serial Downloader */ - return BOOT_DEVICE_UART; + return BOOT_DEVICE_BOARD; /* BOOT_CFG1[7:4] - see IMX6DQRM Table 8-8 */ switch ((reg & IMX6_BMODE_MASK) >> IMX6_BMODE_SHIFT) { @@ -42,11 +44,13 @@ u32 spl_boot_device(void) break; } /* Reserved: Used to force Serial Downloader */ - case IMX6_BMODE_UART: - return BOOT_DEVICE_UART; + case IMX6_BMODE_RESERVED: + return BOOT_DEVICE_BOARD; /* SATA: See 8.5.4, Table 8-20 */ +#if !defined(CONFIG_MX6UL) && !defined(CONFIG_MX6ULL) case IMX6_BMODE_SATA: return BOOT_DEVICE_SATA; +#endif /* Serial ROM: See 8.5.5.1, Table 8-22 */ case IMX6_BMODE_SERIAL_ROM: /* BOOT_CFG4[2:0] */ @@ -126,3 +130,13 @@ __weak void __noreturn jump_to_image_no_args(struct spl_image_info *spl_image) } #endif + +#if defined(CONFIG_MX6) && defined(CONFIG_SPL_OS_BOOT) +int dram_init_banksize(void) +{ + gd->bd->bi_dram[0].start = CONFIG_SYS_SDRAM_BASE; + gd->bd->bi_dram[0].size = imx_ddr_size(); + + return 0; +} +#endif diff --git a/arch/arm/mach-imx/timer.c b/arch/arm/mach-imx/timer.c index 9b01114..69dbf3c 100644 --- a/arch/arm/mach-imx/timer.c +++ b/arch/arm/mach-imx/timer.c @@ -74,8 +74,7 @@ int timer_init(void) __raw_writel(GPTCR_SWR, &cur_gpt->control); /* We have no udelay by now */ - for (i = 0; i < 100; i++) - __raw_writel(0, &cur_gpt->control); + __raw_writel(0, &cur_gpt->control); i = __raw_readl(&cur_gpt->control); i &= ~GPTCR_CLKSOURCE_MASK; |