soc: ace_v1x: unmap entire unused virtual space

This patch corrects the initial unmapping of unused l2 memory
to unmap until the end of virtual address space instead
of unmapping until the end of l2 physical memory.

Signed-off-by: Jaroslaw Stelter <Jaroslaw.Stelter@intel.com>
This commit is contained in:
Jaroslaw Stelter 2022-07-12 10:53:18 +02:00 committed by Maureen Helm
commit afb156a1eb

View file

@ -681,9 +681,10 @@ static int sys_mm_drv_mm_init(const struct device *dev)
}
/*
* Unmap unused physical pages from the TLB to save power
* Unmap all unused physical pages from the entire
* virtual address space to save power
*/
size_t unused_size = L2_SRAM_BASE + L2_SRAM_SIZE -
size_t unused_size = CONFIG_KERNEL_VM_BASE + CONFIG_KERNEL_VM_SIZE -
unused_l2_start_aligned;
ret = sys_mm_drv_unmap_region(UINT_TO_POINTER(unused_l2_start_aligned),