core: introduce a new memory type for external dtb image

When CFG_DT=y, the external dtb image is mapped as
IO_NSEC memory type in init_external_dt function,
which may conflicts with dynamic shared memory check.
Below is the panic log with qemu boot:

	E/TC:0 0 check_phys_mem_is_outside:333 Non-sec mem (0x40000000:0x3fe00000) overlaps map (type 13 0x40000000:0x100000)
	E/TC:0 0 Panic at core/arch/arm/mm/core_mmu.c:334 <check_phys_mem_is_outside>
	E/TC:0 0 TEE load address @ 0x1bd0f000

This patch introduces a new memory type MEM_AREA_EXT_DT
which is used to map external dtb image. This memory type
will be skipped over in core_mmu_set_discovered_nsec_ddr()
in order to avoid the above panic.

Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
Signed-off-by: Fangsuo Wu <fangsuowu@asrmicro.com>
3 files changed
tree: 5ad098e456f7e35ee93f0dfa30d0a4e2ece571c4
  1. .github/
  2. core/
  3. keys/
  4. ldelf/
  5. lib/
  6. mk/
  7. scripts/
  8. ta/
  9. .gitignore
  10. .shippable.yml
  11. .travis.yml
  12. CHANGELOG.md
  13. LICENSE
  14. MAINTAINERS
  15. Makefile
  16. README.md
  17. typedefs.checkpatch
README.md

OP-TEE Trusted OS

This git contains source code for the secure side implementation of OP-TEE project.

All official OP-TEE documentation has moved to http://optee.readthedocs.io.

// OP-TEE core maintainers