]> git.baikalelectronics.ru Git - kernel.git/commit
arm64: hibernate: Clean the __hyp_text to PoC after resume
authorJames Morse <james.morse@arm.com>
Thu, 24 Jan 2019 16:32:57 +0000 (16:32 +0000)
committerWill Deacon <will.deacon@arm.com>
Fri, 1 Feb 2019 14:10:02 +0000 (14:10 +0000)
commitf7253ec1c59f06241fa5ca8be131b37629855b34
tree596174a269bafb0bd8977633aa4b9ad2828db324
parenta430fbe9f758b03a6096545055f2157bad846c8e
arm64: hibernate: Clean the __hyp_text to PoC after resume

During resume hibernate restores all physical memory. Any memory
that is accessed with the MMU disabled needs to be cleaned to the
PoC.

KVMs __hyp_text was previously ommitted as it runs with the MMU
enabled, but now that the hyp-stub is located in this section,
we must clean __hyp_text too.

This ensures secondary CPUs that come online after hibernate
has finished resuming, and load KVM via the freshly written
hyp-stub see the correct instructions.

Signed-off-by: James Morse <james.morse@arm.com>
Cc: stable@vger.kernel.org
Signed-off-by: Will Deacon <will.deacon@arm.com>
arch/arm64/kernel/hibernate.c