mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 19:08:57 +09:00
KVM: PPC: Book3S HV: Fix the set_one_reg for MMCR3
[ Upstream commit f9ca6a10be20479d526f27316cc32cfd1785ed39 ]
The kvmppc_set_one_reg_hv() wrongly get() the value
instead of set() for MMCR3. Fix the same.
Fixes: 5752fe0b81 ("KVM: PPC: Book3S HV: Save/restore new PMU registers")
Signed-off-by: Shivaprasad G Bhat <sbhat@linux.ibm.com>
Reviewed-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://msgid.link/171759276847.1480.16387950124201117847.stgit@linux.ibm.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
d115e1759d
commit
74e308be5b
@@ -2484,7 +2484,7 @@ static int kvmppc_set_one_reg_hv(struct kvm_vcpu *vcpu, u64 id,
|
||||
vcpu->arch.mmcrs = set_reg_val(id, *val);
|
||||
break;
|
||||
case KVM_REG_PPC_MMCR3:
|
||||
*val = get_reg_val(id, vcpu->arch.mmcr[3]);
|
||||
kvmppc_set_mmcr_hv(vcpu, 3, set_reg_val(id, *val));
|
||||
break;
|
||||
case KVM_REG_PPC_PMC1 ... KVM_REG_PPC_PMC8:
|
||||
i = id - KVM_REG_PPC_PMC1;
|
||||
|
||||
Reference in New Issue
Block a user