summaryrefslogtreecommitdiff
path: root/tools/perf/lib/Documentation/tutorial/git@git.tavy.me:linux.git
diff options
context:
space:
mode:
authorKornel Dulęba <korneld@google.com>2025-11-14 11:11:53 +0000
committerMarc Zyngier <maz@kernel.org>2026-01-16 09:46:26 +0000
commit582234b0d8419e0b6cbfd87ae3f80568c8d0917e (patch)
tree27c57cd0d117dcd6b9f5890d24e8bbc1b6c5c612 /tools/perf/lib/Documentation/tutorial/git@git.tavy.me:linux.git
parent4b16ad0bf821d4aceb050e9f569dc329883f1c5b (diff)
KVM: arm64: Fix error checking for FFA_VERSION
According to section 13.2 of the DEN0077 FF-A specification, when firmware does not support the requested version, it should reply with FFA_RET_NOT_SUPPORTED(-1). Table 13.6 specifies the type of the error code as int32. Currently, the error checking logic compares the unsigned long return value it got from the SMC layer, against a "-1" literal. This fails due to a type mismatch: the literal is extended to 64 bits, whereas the register contains only 32 bits of ones(0x00000000ffffffff). Consequently, hyp_ffa_init misinterprets the "-1" return value as an invalid FF-A version. This prevents pKVM initialization on devices where FF-A is not supported in firmware. Fix this by explicitly casting res.a0 to s32. Signed-off-by: Kornel Dulęba <korneld@google.com> Acked-by: Will Deacon <will@kernel.org> Link: https://patch.msgid.link/20251114-pkvm_init_noffa-v1-1-87a82e87c345@google.com Signed-off-by: Marc Zyngier <maz@kernel.org>
Diffstat (limited to 'tools/perf/lib/Documentation/tutorial/git@git.tavy.me:linux.git')
0 files changed, 0 insertions, 0 deletions