Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e38bceb8 authored by Mark Rutland's avatar Mark Rutland Committed by Sami Tolvanen
Browse files

UPSTREAM: arm64: head.S: ensure idmap_t0sz is visible



We write idmap_t0sz with SCTLR_EL1.{C,M} clear, but we only have the
guarnatee that the kernel Image is clean, not invalid in the caches, and
therefore we might read a stale value once the MMU is enabled.

This patch ensures we invalidate the corresponding cacheline after the
write as we do for all other data written before we set SCTLR_EL1.{C.M},
guaranteeing that the value will be visible later. We rely on the DSBs
in __create_page_tables to complete the maintenance.

Signed-off-by: default avatarMark Rutland <mark.rutland@arm.com>
CC: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will.deacon@arm.com>
Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>

Bug: 31432001
Change-Id: I356a316bbdaca774ac96def6dc495eac654c6924
(cherry picked from commit 0c20856c260236b96f54c452d38dbe1348ed34d2)
Signed-off-by: default avatarSami Tolvanen <samitolvanen@google.com>
parent 8e931c99
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment