]> Git Repo - linux.git/commitdiff
KVM: PPC: Book3S HV nestedv2: Keep nested guest HASHPKEYR in sync
authorShivaprasad G Bhat <[email protected]>
Wed, 5 Jun 2024 13:07:49 +0000 (13:07 +0000)
committerMichael Ellerman <[email protected]>
Thu, 6 Jun 2024 12:39:04 +0000 (22:39 +1000)
The nestedv2 APIs has the guest state element defined for HASHPKEYR
for the save-restore with L0. However, its ignored in the code.

The patch takes care of this for the HASHPKEYR GSID.

Signed-off-by: Shivaprasad G Bhat <[email protected]>
Signed-off-by: Michael Ellerman <[email protected]>
Link: https://msgid.link/[email protected]
arch/powerpc/kvm/book3s_hv_nestedv2.c

index 606e4fbc36d93ff58a5405a0a5f610c9327a6b67..eeecea8f202b3643d08c7d12b143b870eea0e1c9 100644 (file)
@@ -199,6 +199,9 @@ static int gs_msg_ops_vcpu_fill_info(struct kvmppc_gs_buff *gsb,
                case KVMPPC_GSID_HASHKEYR:
                        rc = kvmppc_gse_put_u64(gsb, iden, vcpu->arch.hashkeyr);
                        break;
+               case KVMPPC_GSID_HASHPKEYR:
+                       rc = kvmppc_gse_put_u64(gsb, iden, vcpu->arch.hashpkeyr);
+                       break;
                case KVMPPC_GSID_CIABR:
                        rc = kvmppc_gse_put_u64(gsb, iden, vcpu->arch.ciabr);
                        break;
@@ -457,6 +460,9 @@ static int gs_msg_ops_vcpu_refresh_info(struct kvmppc_gs_msg *gsm,
                case KVMPPC_GSID_HASHKEYR:
                        vcpu->arch.hashkeyr = kvmppc_gse_get_u64(gse);
                        break;
+               case KVMPPC_GSID_HASHPKEYR:
+                       vcpu->arch.hashpkeyr = kvmppc_gse_get_u64(gse);
+                       break;
                case KVMPPC_GSID_CIABR:
                        vcpu->arch.ciabr = kvmppc_gse_get_u64(gse);
                        break;
This page took 0.056694 seconds and 4 git commands to generate.