fix(mm): extend Stage 1 mapping limit
As Stage 1 mappings are limited to 512GB, registering FF-A RxTx buffers
fails when the physical address of these buffers exceeds 512GB. This
fix removes the limitation and allows Stage 1 mapping up to the
supported PA range.
Make necessary changes in hftest, to initialize stage-1 page table
maximum level for test running in VM and non-VM case. Also retain the
stage-1 PA range as 512GB for test running in VM.
Signed-off-by: Arunachalam Ganapathy <arunachalam.ganapathy@arm.com>
Change-Id: I4cb8d68fc18e0edf4a7ee06ae636849d552d72a9
diff --git a/inc/hf/arch/mm.h b/inc/hf/arch/mm.h
index b629e8b..043c564 100644
--- a/inc/hf/arch/mm.h
+++ b/inc/hf/arch/mm.h
@@ -115,6 +115,11 @@
void arch_mm_flush_dcache(void *base, size_t size);
/**
+ * Sets the maximum level allowed in the page table for stage-1.
+ */
+void arch_mm_stage1_max_level_set(uint32_t pa_bits);
+
+/**
* Gets the maximum level allowed in the page table for stage-1.
*/
uint8_t arch_mm_stage1_max_level(void);