summaryrefslogtreecommitdiff
path: root/arch/arm
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2019-07-18 11:31:37 -0400
committerTom Rini <trini@konsulko.com>2019-07-18 11:31:37 -0400
commit0de815356474912ef5bef9a69f0327a5a93bb2c2 (patch)
tree92db8fda09396081f58a0c5fb182e72fbc3fdd50 /arch/arm
parent9a06eb800c1bdc68aa81fcad6d4f404e12dfff33 (diff)
parentbf88d2b023063a0c46d7617a4f6897d5d561662d (diff)
Merge branch '2019-07-17-master-imports'
- Various FS/disk related fixes with security implications. - Proper fix for the pci_ep test. - Assorted bugfixes - Some MediaTek updates. - 'env erase' support.
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/Kconfig30
-rw-r--r--arch/arm/cpu/armv8/fsl-layerscape/Kconfig7
-rw-r--r--arch/arm/dts/mt7629-rfb.dts1
-rw-r--r--arch/arm/dts/mt7629.dtsi4
-rw-r--r--arch/arm/include/asm/proc-armv/ptrace.h2
-rw-r--r--arch/arm/mach-mediatek/mt7629/lowlevel_init.S13
6 files changed, 46 insertions, 11 deletions
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 05606d9722..51d4acedac 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -840,6 +840,7 @@ config ARCH_OWL
config ARCH_QEMU
bool "QEMU Virtual Platform"
+ select ARCH_SUPPORT_TFABOOT
select DM
select DM_SERIAL
select OF_CONTROL
@@ -1100,6 +1101,7 @@ config TARGET_LS1088AQDS
select ARCH_MISC_INIT
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_LATE_INIT
select SUPPORT_SPL
select FSL_DDR_INTERACTIVE if !SD_BOOT
@@ -1115,6 +1117,7 @@ config TARGET_LS2080AQDS
select ARCH_MISC_INIT
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_LATE_INIT
select SUPPORT_SPL
imply SCSI
@@ -1133,6 +1136,7 @@ config TARGET_LS2080ARDB
select ARCH_MISC_INIT
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_LATE_INIT
select SUPPORT_SPL
select FSL_DDR_BIST
@@ -1165,6 +1169,7 @@ config TARGET_LX2160ARDB
select ARCH_MISC_INIT
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_LATE_INIT
help
Support for NXP LX2160ARDB platform.
@@ -1178,6 +1183,7 @@ config TARGET_LX2160AQDS
select ARCH_MISC_INIT
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_LATE_INIT
help
Support for NXP LX2160AQDS platform.
@@ -1218,6 +1224,7 @@ config TARGET_LS1012AQDS
bool "Support ls1012aqds"
select ARCH_LS1012A
select ARM64
+ select ARCH_SUPPORT_TFABOOT
select BOARD_LATE_INIT
help
Support for Freescale LS1012AQDS platform.
@@ -1229,6 +1236,7 @@ config TARGET_LS1012ARDB
bool "Support ls1012ardb"
select ARCH_LS1012A
select ARM64
+ select ARCH_SUPPORT_TFABOOT
select BOARD_LATE_INIT
imply SCSI
imply SCSI_AHCI
@@ -1242,6 +1250,7 @@ config TARGET_LS1012A2G5RDB
bool "Support ls1012a2g5rdb"
select ARCH_LS1012A
select ARM64
+ select ARCH_SUPPORT_TFABOOT
select BOARD_LATE_INIT
imply SCSI
help
@@ -1254,6 +1263,7 @@ config TARGET_LS1012AFRWY
bool "Support ls1012afrwy"
select ARCH_LS1012A
select ARM64
+ select ARCH_SUPPORT_TFABOOT
select BOARD_LATE_INIT
imply SCSI
imply SCSI_AHCI
@@ -1267,6 +1277,7 @@ config TARGET_LS1012AFRDM
bool "Support ls1012afrdm"
select ARCH_LS1012A
select ARM64
+ select ARCH_SUPPORT_TFABOOT
help
Support for Freescale LS1012AFRDM platform.
The LS1012A Freedom board (FRDM) is a high-performance
@@ -1278,6 +1289,7 @@ config TARGET_LS1028AQDS
select ARCH_LS1028A
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
help
Support for Freescale LS1028AQDS platform
The LS1028A Development System (QDS) is a high-performance
@@ -1289,6 +1301,7 @@ config TARGET_LS1028ARDB
select ARCH_LS1028A
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
help
Support for Freescale LS1028ARDB platform
The LS1028A Development System (RDB) is a high-performance
@@ -1301,6 +1314,7 @@ config TARGET_LS1088ARDB
select ARCH_MISC_INIT
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_LATE_INIT
select SUPPORT_SPL
select FSL_DDR_INTERACTIVE if !SD_BOOT
@@ -1359,6 +1373,7 @@ config TARGET_LS1043AQDS
select ARCH_LS1043A
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select SUPPORT_SPL
@@ -1373,6 +1388,7 @@ config TARGET_LS1043ARDB
select ARCH_LS1043A
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select SUPPORT_SPL
@@ -1384,6 +1400,7 @@ config TARGET_LS1046AQDS
select ARCH_LS1046A
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select DM_SPI_FLASH if DM_SPI
@@ -1403,6 +1420,7 @@ config TARGET_LS1046ARDB
select ARCH_LS1046A
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select DM_SPI_FLASH if DM_SPI
@@ -1422,6 +1440,7 @@ config TARGET_LS1046AFRWY
select ARCH_LS1046A
select ARM64
select ARMV8_MULTIENTRY
+ select ARCH_SUPPORT_TFABOOT
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select DM_SPI_FLASH if DM_SPI
@@ -1565,6 +1584,17 @@ config ARCH_ASPEED
endchoice
+config ARCH_SUPPORT_TFABOOT
+ bool
+
+config TFABOOT
+ bool "Support for booting from TF-A"
+ depends on ARCH_SUPPORT_TFABOOT
+ default n
+ help
+ Enabling this will make a U-Boot binary that is capable of being
+ booted via TF-A.
+
config TI_SECURE_DEVICE
bool "HS Device Type Support"
depends on ARCH_KEYSTONE || ARCH_OMAP2PLUS || ARCH_K3
diff --git a/arch/arm/cpu/armv8/fsl-layerscape/Kconfig b/arch/arm/cpu/armv8/fsl-layerscape/Kconfig
index 3f6c983aaf..5c32738fbf 100644
--- a/arch/arm/cpu/armv8/fsl-layerscape/Kconfig
+++ b/arch/arm/cpu/armv8/fsl-layerscape/Kconfig
@@ -623,10 +623,3 @@ config HAS_FSL_XHCI_USB
help
For some SoC(such as LS1043A and LS1046A), USB and QE-HDLC multiplex use
pins, select it when the pins are assigned to USB.
-
-config TFABOOT
- bool "Support for booting from TFA"
- default n
- help
- Enabling this will make a U-Boot binary that is capable of being
- booted via TFA.
diff --git a/arch/arm/dts/mt7629-rfb.dts b/arch/arm/dts/mt7629-rfb.dts
index 4612218a1e..08c3b59222 100644
--- a/arch/arm/dts/mt7629-rfb.dts
+++ b/arch/arm/dts/mt7629-rfb.dts
@@ -18,7 +18,6 @@
chosen {
stdout-path = &uart0;
- tick-timer = &timer0;
};
};
diff --git a/arch/arm/dts/mt7629.dtsi b/arch/arm/dts/mt7629.dtsi
index c87115e0fe..ecbd29d7ae 100644
--- a/arch/arm/dts/mt7629.dtsi
+++ b/arch/arm/dts/mt7629.dtsi
@@ -82,8 +82,8 @@
compatible = "mediatek,timer";
reg = <0x10004000 0x80>;
interrupts = <GIC_SPI 152 IRQ_TYPE_LEVEL_LOW>;
- clocks = <&topckgen CLK_TOP_10M_SEL>,
- <&topckgen CLK_TOP_CLKXTAL_D4>;
+ clocks = <&topckgen CLK_TOP_CLKXTAL_D4>,
+ <&topckgen CLK_TOP_10M_SEL>;
clock-names = "mux", "src";
u-boot,dm-pre-reloc;
};
diff --git a/arch/arm/include/asm/proc-armv/ptrace.h b/arch/arm/include/asm/proc-armv/ptrace.h
index 183b00a087..e37ad8fd1f 100644
--- a/arch/arm/include/asm/proc-armv/ptrace.h
+++ b/arch/arm/include/asm/proc-armv/ptrace.h
@@ -86,7 +86,7 @@ struct pt_regs {
#define user_mode(regs) \
(((regs)->ARM_cpsr & 0xf) == 0)
-#ifdef CONFIG_ARM_THUMB
+#if CONFIG_IS_ENABLED(SYS_THUMB_BUILD)
#define thumb_mode(regs) \
(((regs)->ARM_cpsr & T_BIT))
#else
diff --git a/arch/arm/mach-mediatek/mt7629/lowlevel_init.S b/arch/arm/mach-mediatek/mt7629/lowlevel_init.S
index 3375796b79..0a0672cbea 100644
--- a/arch/arm/mach-mediatek/mt7629/lowlevel_init.S
+++ b/arch/arm/mach-mediatek/mt7629/lowlevel_init.S
@@ -4,6 +4,7 @@
*/
#include <linux/linkage.h>
+#include <asm/proc-armv/ptrace.h>
#define WAIT_CODE_SRAM_BASE 0x0010ff00
@@ -27,6 +28,18 @@ ENTRY(lowlevel_init)
movt r0, #0x131
mcr p15, 0, r0, c14, c0, 0
+ cps #MON_MODE
+ mrc p15, 0, r1, c1, c1, 0 @ Get Secure Config
+ orr r0, r1, #1
+ mcr p15, 0, r0, c1, c1, 0 @ Set Non Secure bit
+ isb
+ mov r0, #0
+ mcrr p15, 4, r0, r0, c14 @ CNTVOFF = 0
+ isb
+ mcr p15, 0, r1, c1, c1, 0 @ Set Secure bit
+ isb
+ cps #SVC_MODE
+
/* enable SMP bit */
mrc p15, 0, r0, c1, c0, 1
orr r0, r0, #0x40