aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnshuman Khandual <[email protected]>2019-10-04 09:53:58 +0530
committerCatalin Marinas <[email protected]>2019-10-16 13:56:30 +0100
commit6ec939f8b809cb06ba7802e17ef7024d1bc0ee84 (patch)
tree53eb34b9662392068280a4b2f4841a442ffb9fdc
parent899ee4afe5eb262236717188ccdaa0192c00dc5a (diff)
arm64/mm: Poison initmem while freeing with free_reserved_area()
Platform implementation for free_initmem() should poison the memory while freeing it up. Hence pass across POISON_FREE_INITMEM while calling into free_reserved_area(). The same is being followed in the generic fallback for free_initmem() and some other platforms overriding it. Cc: Mark Rutland <[email protected]> Cc: [email protected] Reviewed-by: Steven Price <[email protected]> Acked-by: Will Deacon <[email protected]> Signed-off-by: Anshuman Khandual <[email protected]> Signed-off-by: Catalin Marinas <[email protected]>
-rw-r--r--arch/arm64/mm/init.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm64/mm/init.c b/arch/arm64/mm/init.c
index 87a0e3b6c146..7c225d0132b8 100644
--- a/arch/arm64/mm/init.c
+++ b/arch/arm64/mm/init.c
@@ -571,7 +571,7 @@ void free_initmem(void)
{
free_reserved_area(lm_alias(__init_begin),
lm_alias(__init_end),
- 0, "unused kernel");
+ POISON_FREE_INITMEM, "unused kernel");
/*
* Unmap the __init region but leave the VM area in place. This
* prevents the region from being reused for kernel modules, which