arm64: Implement branch predictor hardening for Falkor
Falkor is susceptible to branch predictor aliasing and can theoretically be attacked by malicious code. This patch implements a mitigation for these attacks, preventing any malicious entries from affecting other victim contexts. Signed-off-by: Shanker Donthineni <shankerd@codeaurora.org> [will: fix label name when !CONFIG_KVM and remove references to MIDR_FALKOR] Signed-off-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
This commit is contained in:

committed by
Catalin Marinas

parent
aa6acde65e
commit
ec82b567a7
@@ -196,3 +196,15 @@ alternative_endif
|
||||
|
||||
eret
|
||||
ENDPROC(__fpsimd_guest_restore)
|
||||
|
||||
ENTRY(__qcom_hyp_sanitize_btac_predictors)
|
||||
/**
|
||||
* Call SMC64 with Silicon provider serviceID 23<<8 (0xc2001700)
|
||||
* 0xC2000000-0xC200FFFF: assigned to SiP Service Calls
|
||||
* b15-b0: contains SiP functionID
|
||||
*/
|
||||
movz x0, #0x1700
|
||||
movk x0, #0xc200, lsl #16
|
||||
smc #0
|
||||
ret
|
||||
ENDPROC(__qcom_hyp_sanitize_btac_predictors)
|
||||
|
Reference in New Issue
Block a user