aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorAntonio Nino Diaz <antonio.ninodiaz@arm.com>2017-10-25 11:53:25 +0100
committerAntonio Nino Diaz <antonio.ninodiaz@arm.com>2017-11-08 18:05:14 +0000
commitad02a7596f73ea9f07ebc9e04970ab7e9961c868 (patch)
tree435ae69cc9a11a59fb6ad16f8dda2022bed574a3 /include
parent92cad5fa4bb4f7662574350df91196bb8017a820 (diff)
downloadplatform_external_arm-trusted-firmware-ad02a7596f73ea9f07ebc9e04970ab7e9961c868.tar.gz
platform_external_arm-trusted-firmware-ad02a7596f73ea9f07ebc9e04970ab7e9961c868.tar.bz2
platform_external_arm-trusted-firmware-ad02a7596f73ea9f07ebc9e04970ab7e9961c868.zip
xlat: Make function to calculate TCR PA bits public
This function can be useful to setup TCR_ELx by callers that don't use the translation tables library to setup the system registers related to them. By making it common, it can be reused whenever it is needed without duplicating code. Change-Id: Ibfada9e846d2a6cd113b1925ac911bb27327d375 Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
Diffstat (limited to 'include')
-rw-r--r--include/lib/xlat_tables/aarch64/xlat_tables_aarch64.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/lib/xlat_tables/aarch64/xlat_tables_aarch64.h b/include/lib/xlat_tables/aarch64/xlat_tables_aarch64.h
index 7381bc829..6021e4070 100644
--- a/include/lib/xlat_tables/aarch64/xlat_tables_aarch64.h
+++ b/include/lib/xlat_tables/aarch64/xlat_tables_aarch64.h
@@ -16,6 +16,11 @@
#endif
/*
+ * Encode a Physical Address Space size for its use in TCR_ELx.
+ */
+unsigned long long tcr_physical_addr_size_bits(unsigned long long max_addr);
+
+/*
* In AArch64 state, the MMU may support 4 KB, 16 KB and 64 KB page
* granularity. For 4KB granularity, a level 0 table descriptor doesn't support
* block translation. For 16KB, the same thing happens to levels 0 and 1. For