Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

x86/hyperv: Fix check of return value from snp_set_vmsa()

snp_set_vmsa() returns 0 as success result and so fix it.

Cc: stable@vger.kernel.org
Fixes: 44676bb9d566 ("x86/hyperv: Add smp support for SEV-SNP guest")
Signed-off-by: Tianyu Lan <tiala@microsoft.com>
Reviewed-by: Michael Kelley <mhklinux@outlook.com>
Link: https://lore.kernel.org/r/20250313085217.45483-1-ltykernel@gmail.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>
Message-ID: <20250313085217.45483-1-ltykernel@gmail.com>

authored by

Tianyu Lan and committed by
Wei Liu
e792d843 07b74192

+1 -1
+1 -1
arch/x86/hyperv/ivm.c
··· 338 338 vmsa->sev_features = sev_status >> 2; 339 339 340 340 ret = snp_set_vmsa(vmsa, true); 341 - if (!ret) { 341 + if (ret) { 342 342 pr_err("RMPADJUST(%llx) failed: %llx\n", (u64)vmsa, ret); 343 343 free_page((u64)vmsa); 344 344 return ret;