* [PATCH] KVM: PPC: Book3S HV: Remove vcpu->arch.dec usage
@ 2017-12-19 14:56 Alexander Graf
2018-01-11 10:01 ` Paul Mackerras
0 siblings, 1 reply; 2+ messages in thread
From: Alexander Graf @ 2017-12-19 14:56 UTC (permalink / raw)
To: kvm-ppc; +Cc: linuxppc-dev, linux-kernel, kvm, Paul Mackerras
On Book3S in HV mode, we don't use the vcpu->arch.dec field at all.
Instead, all logic is built around vcpu->arch.dec_expires.
So let's remove the one remaining piece of code that was setting it.
Signed-off-by: Alexander Graf <agraf@suse.de>
---
Looking through the DEC logic, I fail to see any code that allows
save or restore of DEC. Do we maybe miss out on that register for
(live) migration?
---
arch/powerpc/kvm/book3s_hv_rmhandlers.S | 1 -
1 file changed, 1 deletion(-)
diff --git a/arch/powerpc/kvm/book3s_hv_rmhandlers.S b/arch/powerpc/kvm/book3s_hv_rmhandlers.S
index 2659844784b8..c8ffd69adfec 100644
--- a/arch/powerpc/kvm/book3s_hv_rmhandlers.S
+++ b/arch/powerpc/kvm/book3s_hv_rmhandlers.S
@@ -957,7 +957,6 @@ ALT_FTR_SECTION_END_IFCLR(CPU_FTR_ARCH_300)
mftb r7
subf r3,r7,r8
mtspr SPRN_DEC,r3
- std r3,VCPU_DEC(r4)
ld r5, VCPU_SPRG0(r4)
ld r6, VCPU_SPRG1(r4)
--
2.12.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] KVM: PPC: Book3S HV: Remove vcpu->arch.dec usage
2017-12-19 14:56 [PATCH] KVM: PPC: Book3S HV: Remove vcpu->arch.dec usage Alexander Graf
@ 2018-01-11 10:01 ` Paul Mackerras
0 siblings, 0 replies; 2+ messages in thread
From: Paul Mackerras @ 2018-01-11 10:01 UTC (permalink / raw)
To: Alexander Graf; +Cc: kvm-ppc, linuxppc-dev, linux-kernel, kvm
On Tue, Dec 19, 2017 at 03:56:24PM +0100, Alexander Graf wrote:
> On Book3S in HV mode, we don't use the vcpu->arch.dec field at all.
> Instead, all logic is built around vcpu->arch.dec_expires.
>
> So let's remove the one remaining piece of code that was setting it.
>
> Signed-off-by: Alexander Graf <agraf@suse.de>
Thanks, applied to my kvm-ppc-next branch.
> Looking through the DEC logic, I fail to see any code that allows
> save or restore of DEC. Do we maybe miss out on that register for
> (live) migration?
Yes, it looks like we do. I'm amazed no-one has noticed before. I'll
fix it.
Paul.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-01-11 10:01 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-12-19 14:56 [PATCH] KVM: PPC: Book3S HV: Remove vcpu->arch.dec usage Alexander Graf
2018-01-11 10:01 ` Paul Mackerras
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).