* [patch] bugfix, correct itc_offset calculations
@ 2009-05-25 8:22 Jes Sorensen
2009-05-25 9:07 ` Zhang, Xiantao
2009-05-25 11:47 ` Avi Kivity
0 siblings, 2 replies; 3+ messages in thread
From: Jes Sorensen @ 2009-05-25 8:22 UTC (permalink / raw)
To: kvm-ia64
[-- Attachment #1: Type: text/plain, Size: 218 bytes --]
Hi,
Gleb Natapov spotted that I had been a little over aggressive when I
introduced the vcpu_online counter, so the code in kvm_arch_vcpu_init()
only calculated the itc_offset for vCPU 0.
Please apply.
Cheers,
Jes
[-- Attachment #2: 4000-kvm-ia64-itc-init.patch --]
[-- Type: text/x-patch, Size: 810 bytes --]
Init the itc_offset for all possible vCPUs. The current code by
mistake ends up only initializing the offset on vCPU 0.
Spotted by Gleb Natapov
Signed-off-by: Jes Sorensen <jes@sgi.com>
---
arch/ia64/kvm/kvm-ia64.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: linux-2.6.git/arch/ia64/kvm/kvm-ia64.c
===================================================================
--- linux-2.6.git.orig/arch/ia64/kvm/kvm-ia64.c
+++ linux-2.6.git/arch/ia64/kvm/kvm-ia64.c
@@ -1166,7 +1166,7 @@
/*Initialize itc offset for vcpus*/
itc_offset = 0UL - ia64_getreg(_IA64_REG_AR_ITC);
- for (i = 0; i < kvm->arch.online_vcpus; i++) {
+ for (i = 0; i < KVM_MAX_VCPUS; i++) {
v = (struct kvm_vcpu *)((char *)vcpu +
sizeof(struct kvm_vcpu_data) * i);
v->arch.itc_offset = itc_offset;
^ permalink raw reply [flat|nested] 3+ messages in thread
* RE: [patch] bugfix, correct itc_offset calculations
2009-05-25 8:22 [patch] bugfix, correct itc_offset calculations Jes Sorensen
@ 2009-05-25 9:07 ` Zhang, Xiantao
2009-05-25 11:47 ` Avi Kivity
1 sibling, 0 replies; 3+ messages in thread
From: Zhang, Xiantao @ 2009-05-25 9:07 UTC (permalink / raw)
To: kvm-ia64
Aha, it should be introduced when implement vcpu_online mechanism.
Acked-by : Xiantao Zhang <xiantao.zhang@intel.com>
Xiantao
Jes Sorensen wrote:
> Hi,
>
> Gleb Natapov spotted that I had been a little over aggressive when I
> introduced the vcpu_online counter, so the code in
> kvm_arch_vcpu_init() only calculated the itc_offset for vCPU 0.
>
> Please apply.
>
> Cheers,
> Jes
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [patch] bugfix, correct itc_offset calculations
2009-05-25 8:22 [patch] bugfix, correct itc_offset calculations Jes Sorensen
2009-05-25 9:07 ` Zhang, Xiantao
@ 2009-05-25 11:47 ` Avi Kivity
1 sibling, 0 replies; 3+ messages in thread
From: Avi Kivity @ 2009-05-25 11:47 UTC (permalink / raw)
To: kvm-ia64
Jes Sorensen wrote:
> Hi,
>
> Gleb Natapov spotted that I had been a little over aggressive when I
> introduced the vcpu_online counter, so the code in kvm_arch_vcpu_init()
> only calculated the itc_offset for vCPU 0.
Applied, thanks.
--
error compiling committee.c: too many arguments to function
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2009-05-25 11:47 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-25 8:22 [patch] bugfix, correct itc_offset calculations Jes Sorensen
2009-05-25 9:07 ` Zhang, Xiantao
2009-05-25 11:47 ` Avi Kivity
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.