Commit Graph

1828 Commits

Author SHA1 Message Date
Soby Mathew 3ccfcd6e3d
Merge pull request #1587 from antonio-nino-diaz-arm/an/deprecated
Remove deprecated interfaces for all platforms
2018-10-02 10:12:32 +01:00
Dimitris Papastamos 9a983cfec2
Merge pull request #1589 from hzhuang1/topic/fix_clang
Topic/fix clang
2018-10-01 11:29:36 +01:00
Antonio Nino Diaz 991f1f4d94 uniphier: Migrate to new interfaces
- Remove references to removed build options.
- Migrate to bl31_early_platform_setup2().

Change-Id: I9242c4d02a36e385bf0bf8ee56287106030153d1
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:34:17 +01:00
Antonio Nino Diaz 2d6f1f01b1 rockchip: Migrate to new interfaces
- Migrate to new GIC interfaces.
- Migrate to bl31_early_platform_setup2().
- Use bl31_warm_entrypoint() instead of psci_entrypoint().
- Use PLAT_VIRT_ADDR_SPACE_SIZE and PLAT_PHY_ADDR_SPACE_SIZE.
- Update Makefile paths.
- Remove references to removed build options.
- Use private definition of bl31_params_t.

Change-Id: I860341594b5c868b2fcaa59d23957ee718472ef1
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:34:17 +01:00
Antonio Nino Diaz fdcc112797 tegra: Migrate to new interfaces
- Migrate to bl31_early_platform_setup2().
- Remove references to removed build options.
- Replace zeromem16() by zeromem().
- Use private definition of bl31_params_t.

This is an incomplete migration, the platform doesn't currently compile.

Change-Id: I67fbf2206678be80c3a16692024221a131cec42f
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:34:17 +01:00
Antonio Nino Diaz b8424642bc mediatek: Migrate to new interfaces
- mt6795: Migrate to new GIC interfaces.
- Remove support for PSCI platform compatibility layer.
- Migrate to bl31_early_platform_setup2().
- Migrate from cm_init_context() to cm_init_my_context().
- Use PLAT_VIRT_ADDR_SPACE_SIZE and PLAT_PHY_ADDR_SPACE_SIZE.
- Update Makefile paths.
- Use private definition of bl31_params_t.

This is an incomplete migration, mt6795 doesn't currently compile.

Change-Id: Icf9307637066cd6f2166524715e4f117f5ce2350
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:34:17 +01:00
Antonio Nino Diaz 35795b4e87 marvell: Migrate to new interfaces
- Migrate to bl2_early_platform_setup2().
- Remove references to removed build options.
- Use private definition of bl31_params_t.

This is an incomplete migration, the platform doesn't currently compile.

Change-Id: I1ae477b1f2489f49b651528050fdf06e4a55e425
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:34:17 +01:00
Antonio Nino Diaz b840662cb0 ls1043: Migrate to new interfaces
- Migrate to new GIC interfaces.
- Remove references to removed build options.

Change-Id: I6f90a33d5438a9d7b71be3f93e8d9da278c8c6e6
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:34:17 +01:00
Antonio Nino Diaz 601d2f3c23 imx8qm: imx8qx: Migrate to new interfaces
- Migrate to new GIC interfaces.
- Migrate to bl31_early_platform_setup2().
- Remove references to removed build options.

Change-Id: Ia7c63f75325ea4b41e32a9de3f01b0007d0ae210
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:34:17 +01:00
Antonio Nino Diaz 82fbaa33e8 poplar: Migrate to new interfaces
- Remove support for LOAD_IMAGE_V2=0.
- Replace deprecated bl1_init_bl2_mem_layout().
- Migrate to bl2_early_platform_setup2().
- Migrate to bl31_early_platform_setup2().
- Use PLAT_VIRT_ADDR_SPACE_SIZE and PLAT_PHY_ADDR_SPACE_SIZE.
- Remove references to removed build options.
- Update Makefile paths.

Change-Id: I52e02633365b3db4244f7ff0f99a6446eae619f0
Tested-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:32:47 +01:00
Antonio Nino Diaz 8cff97d1b4 zynqmp: Migrate to new interfaces
- Remove references to removed build options.
- Migrate to bl31_early_platform_setup2().

Change-Id: Ibeb8982a0a841f55ce778c4f09f06b72b47b21d8
Tested-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:54 +01:00
Antonio Nino Diaz 210d90a985 hikey960: Migrate to new interfaces
- Migrate to new GIC interfaces.
- Remove unused bl1_init_bl2_mem_layout().
- Migrate to bl31_early_platform_setup2().
- Use PLAT_VIRT_ADDR_SPACE_SIZE and PLAT_PHY_ADDR_SPACE_SIZE.
- Remove references to removed build options.
- Update Makefile paths.

Change-Id: I583fd893555e6535f32d87ed67bbae430b8e6afe
Tested-by: Haojian Zhuang <haojian.zhuang@linaro.org>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:54 +01:00
Antonio Nino Diaz c3b5800bbb hikey: Migrate to new interfaces
- Migrate to new GIC interfaces.
- Remove unused bl1_init_bl2_mem_layout().
- Migrate to bl31_early_platform_setup2().
- Use PLAT_VIRT_ADDR_SPACE_SIZE and PLAT_PHY_ADDR_SPACE_SIZE.
- Update Makefile paths.
- Remove references to removed build options.

Change-Id: Idd1e99b4864b2a72e9e12ff1fcd73d8285bc1c94
Tested-by: Haojian Zhuang <haojian.zhuang@linaro.org>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz 1ba2ff7b0f qemu: Migrate to new interfaces
- Remove references to removed build options.
- Remove support for LOAD_IMAGE_V2=0.
- Migrate to sp_min_early_platform_setup2().

Change-Id: I884399139fb8e2554adeded888969f44672d56c0
Co-authored-by: Jens Wiklander <jens.wiklander@linaro.org>
Tested-by: Jens Wiklander <jens.wiklander@linaro.org>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz 99865e0afe warp7: Migrate to new interfaces
- Fix reference to bl2_el3_early_platform_setup()
- Remove references to removed build options.

Change-Id: I9733bec64fc28db15716ddf481c05bdc30700b4a
Tested-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Acked-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz 9e119a4025 sgi: sgm: Migrate to new interfaces
- Remove references to removed build options.
- Remove support for LOAD_IMAGE_V2=0.

Change-Id: I296385ef2ebf829446c76a54400d73f963ed265f
Tested-by: Nariman Poushin <nariman.poushin@linaro.org>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz e7d23bf498 allwinner: Remove references to removed build flags
Change-Id: I206478597dd9855d3fe1577e7e2c0fe6d2af1cc5
Tested-by: Andre Przywara <andre.przywara@arm.com>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz 7045147082 ti: k3: Migrate to new interfaces
- Migrate to bl31_early_platform_setup2().
- Remove references to removed build options.

Change-Id: Ie9f149e3fdec935f9329402ed3dd8e1c00b8832c
Acked-by: Andrew F. Davis <afd@ti.com>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz ce1f43ac34 synquacer: Migrate to new interfaces
- Remove references to removed build options.
- Update Makefile paths.
- Migrate to bl31_early_platform_setup2().

Change-Id: I51cbf09a0297ac1ee645a959063238c9d556d8e1
Tested-by: Sumit Garg <sumit.garg@linaro.org>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz de5457e39b stm32mp1: Migrate to new interfaces
- Remove references to removed build options.
- Remove useless include to removed file.

Change-Id: I256da4135ac0a6ff80d4f211689ab4d08436206f
Tested-by: Yann Gautier <yann.gautier@st.com>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz 62fa9c2e8f rpi3: Remove references to removed build options
Change-Id: Ida5364da1346261cf1636c6a4956a562a5c36ee7
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz 60e19f5744 plat/arm: Migrate to new interfaces
- Remove references to removed build options.
- Remove support for legacy GIC driver.
- Remove support for LOAD_IMAGE_V2=0.

Change-Id: I72f8c05620bdf4a682765e6e53e2c04ca749a3d5
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz fe199e3bac Remove all other deprecated interfaces and files
Change-Id: Icd1cdd42afdc78895a9be6c46b414b0a155cfa63
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz 5b5ca4f23c Remove deprecated bl1_init_bl2_mem_layout()
Change-Id: I8ec8b4439ca1d7606aae069c2c576a9a8b18c92c
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz 34244d946d Remove deprecated early platform setup interfaces
The affected interfaces are bl31_early_platform_setup(),
sp_min_early_platform_setup() and bl2_early_platform_setup().

Change-Id: I50c01ec68bcbe97fe4e5d101bcd0f763358b8e1e
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Antonio Nino Diaz f9ed3cb624 gic: Remove deprecated driver and interfaces
Change-Id: I567a406edb090ae9d109382f6874846a79dd7473
Co-authored-by: Roberto Vargas <roberto.vargas@arm.com>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:53 +01:00
Roberto Vargas ed51b51f7a Remove build option LOAD_IMAGE_V2
The code of LOAD_IMAGE_V2=0 has been removed.

Change-Id: Iea03e5bebb90c66889bdb23f85c07d0c9717fffe
Co-authored-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:52 +01:00
Antonio Nino Diaz 0b81230599 PSCI: Remove deprecated file plat_psci_common.c
Change-Id: I9fd8016527ad7706494f34356fdae8efacef5f72
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:52 +01:00
Roberto Vargas 871de5373d PSCI: Remove platform compatibility layer
Change-Id: I40d040aa05bcbf11536a96ce59827711456b93a8
Co-authored-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
2018-09-28 15:31:52 +01:00
Dimitris Papastamos 7401edf2e0
Revert "sgm: increase SCP_BL2 maximum size" 2018-09-28 14:23:26 +01:00
Dimitris Papastamos e5af67910c
Merge pull request #1592 from shawnguo2/fix-recovery-build
poplar: fix build error with POPLAR_RECOVERY=1
2018-09-28 13:57:45 +01:00
Shawn Guo d5ed294640 poplar: fix build error with POPLAR_RECOVERY=1
Commit eba1b6b3c7 ("plat/poplar: migrate to mmc framework") defines
variable 'info' without !POPLAR_RECOVERY protection, and hence causes
the following unused variable error with POPLAR_RECOVERY=1 build.

plat/hisilicon/poplar/bl1_plat_setup.c: In function ‘bl1_platform_setup’:
plat/hisilicon/poplar/bl1_plat_setup.c:95:25: error: unused variable ‘info’ [-Werror=unused-variable]
  struct mmc_device_info info;
                         ^~~~

The patches fixes the build error with POPLAR_RECOVERY=1.

Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
2018-09-27 17:04:46 +08:00
Haojian Zhuang 492a504c12 hikey960: fix build issue for clang
plat/hisilicon/hikey960/include/plat_macros.S:19:55: error: unexpected token in
'.asciz' directive
 .asciz "gicd_ispendr regs (Offsets 0x200 - 0x278)\n" " Offset:\t\t\tvalue\n"
                                                      ^
Makefile:720: recipe for target 'build/hikey960/debug/bl1/cortex_a53.o' failed
make: *** [build/hikey960/debug/bl1/cortex_a53.o] Error 1

Merge the two lines into one.

Signed-off-by: Haojian Zhuang <haojian.zhuang@linaro.org>
2018-09-26 16:48:39 +08:00
Haojian Zhuang 00a6462481 hikey: fix build issue for clang
plat/hisilicon/hikey/include/plat_macros.S:19:55: error: unexpected token in '.asciz' directive
 .asciz "gicd_ispendr regs (Offsets 0x200 - 0x278)\n" " Offset:\t\t\tvalue\n"
                                                      ^
Makefile:720: recipe for target 'build/hikey/debug/bl1/cortex_a53.o' failed
make: *** [build/hikey/debug/bl1/cortex_a53.o] Error 1

Merge two lines into one line.

Signed-off-by: Haojian Zhuang <haojian.zhuang@linaro.org>
2018-09-26 16:10:24 +08:00
Elieva Pignat 3a8667b917 sgm: increase SCP_BL2 maximum size
For sgm775 the SCP_BL2 build in debug mode is around 94KiB which
is higher than the maximum size for SCP_BL2.

This patch increase the maximum allowed size for SCP_BL2 to
96KiB.

Change-Id: Ibca0daadba41429301c651ae21cbba87e45ccddf
Signed-off-by: Elieva Pignat <Elieva.Pignat@arm.com>
2018-09-24 15:37:28 +01:00
Soby Mathew 6254241994
Merge pull request #1570 from Andre-ARM/allwinner/pmic-fixes
Allwinner PMIC fixes
2018-09-19 10:50:46 +01:00
Andre Przywara dfc0fb2725 drivers: i2c: mentor: move platform code into header files
At the moment we have two I2C stub drivers (for the Allwinner and the
Marvell platform), which #include the actual .c driver file.
Change this into the more usual design, by renaming and moving the stub
drivers into platform specific header files and including these from the
actual driver file. The platform specific include directories make sure
the driver picks up the right header automatically.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
2018-09-19 09:24:02 +01:00
Soby Mathew 943bb7f8f4 ARM platforms: Reintroduce coherent memory for BL1 and BL2
The patch d323af9 removed the support for coherent memory in BL1 and
BL2 for ARM platforms. But the CryptoCell SBROM  integration depends
on use of coherent buffers for passing data from the AP CPU to the
CryptoCell. Hence this patch reintroduces support for coherent
memory in BL1 and BL2 if ARM_CRYPTOCELL_INTEG=1.

Change-Id: I011482dda7f7a3ec9e3e79bfb3f4fa03796f7e02
Signed-Off-by: Soby Mathew <soby.mathew@arm.com>
2018-09-18 13:29:35 +01:00
Andre Przywara 159c52491a allwinner: sun50i_h6: initialise I2C just before powering down
Even though we initialise the platform part and the I2C controller
itself at boot time, we actually only access the bus on power down.
Meanwhile a rich OS might have configured the I2C pins differently or
even disabled the controller.
So repeat the platform setup and controller initialisation just before
we actually access the bus to power off the system. This is safe,
because at this point the rich OS should no longer be running.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
2018-09-17 09:51:22 +01:00
Andre Przywara 1a910bcee2 allwinner: sun50i_h6: improve I2C setup
Drop the unnecessary check for the I2C pins being already configured as
I2C pins (we actually don't care).
Also avoid resetting *every* peripheral that is covered by the PRCM reset
controller, instead just clear the one line connected to the I2C controller.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
2018-09-17 09:51:22 +01:00
Soby Mathew 441b1e8df7
Merge pull request #1569 from soby-mathew/sm/cov_fix_scmi
CSS: Fix overrun if system power level is not available
2018-09-10 12:44:56 +01:00
Soby Mathew d4ee9aa6cd CSS: Fix overrun if system power level is not available
This patch fixes an array overrun in CSS scmi driver if the
system power domain level is less than 2. This was reported from
https://scan.coverity.com/projects/arm-software-arm-trusted-firmware

CID 308492

Change-Id: I3a59c700490816718d20c71141281f19b2b7e7f7
Signed-off-by: Soby Mathew <soby.mathew@arm.com>
2018-09-10 11:32:49 +01:00
Soby Mathew 8242659969
Merge pull request #1555 from theopolis/tbb-hikey960
hikey960: Add development TBB support
2018-09-10 11:10:12 +01:00
Soby Mathew e636812dce
Merge pull request #1534 from Icenowy/sun50i_h6_pmic
Add support for Allwinner H6 + X-Powers AXP805 PMIC combination
2018-09-10 11:06:16 +01:00
Teddy Reed 745d8a82b9 hikey960: Add development TBB support
This patch adds experimental support for TBB to the HiKey960 board. To
build and test with TBB modify the uefi-tools project platforms.config

+ATF_BUILDFLAGS=TRUSTED_BOARD_BOOT=1 GENERATE_COT=1 SAVE_KEYS=1 \
  MBEDTLS_DIR=./mbedtls

Signed-off-by: Teddy Reed <teddy@casualhacking.io>
2018-09-09 08:02:50 -04:00
Soby Mathew 03f3632ce6
Merge pull request #1566 from EvanLloyd/non_secure_uart
ARM Platforms:Enable non-secure access to UART1
2018-09-07 16:34:02 +01:00
Icenowy Zheng 5069c1cfef allwinner: implement system power down on H6 w/ AXP805
The AXP805 PMIC used with H6 is capable of shutting down the system.

Add support for using it to shut down the system power.

The original placeholder power off code is moved to A64 code, as it's
still TODO to implement PMIC operations for A64.

Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
2018-09-07 23:20:17 +08:00
Icenowy Zheng 6d37282807 allwinner: sun50i_h6: add initial AXP805 PMIC code
The OTT reference design of Allwinner H6 SoC uses an X-Powers AXP805
PMIC.

Add initial code for it.

Currently it's only detected.

Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
2018-09-07 23:20:17 +08:00
Dimitris Papastamos b51d4337c3
Merge pull request #1565 from satheesbalya-arm/sb1_2332_fwu_sds_register
juno: Revert FWU update detect mechanism
2018-09-07 16:01:03 +01:00
Icenowy Zheng 7c26b6ecea allwinner: call PMIC setup code
As the ATF may need to do some power initialization on Allwinner
platform with AXP PMICs, call the PMIC setup code in BL31.

Stub of PMIC setup code is added, to prevent undefined reference.

Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
2018-09-07 22:09:45 +08:00