All of lore.kernel.org
 help / color / mirror / Atom feed
From: bugzilla-daemon@bugzilla.kernel.org
To: kvm@vger.kernel.org
Subject: [Bug 116011] New: After hot plug vcpu, kvm_arch->use_master_clock will never be true.
Date: Thu, 07 Apr 2016 07:42:14 +0000	[thread overview]
Message-ID: <bug-116011-28872@https.bugzilla.kernel.org/> (raw)

https://bugzilla.kernel.org/show_bug.cgi?id=116011

            Bug ID: 116011
           Summary: After hot plug vcpu, kvm_arch->use_master_clock will
                    never be true.
           Product: Virtualization
           Version: unspecified
    Kernel Version: 4.5
          Hardware: x86-64
                OS: Linux
              Tree: Mainline
            Status: NEW
          Severity: normal
          Priority: P1
         Component: kvm
          Assignee: virtualization_kvm@kernel-bugs.osdl.org
          Reporter: changlimin@h3c.com
        Regression: No

1. In function kvm_write_tsc, when tsc first matched, do
kvm->arch.nr_vcpus_matched_tsc++;

2. In function pvclock_update_vm_gtod_copy, if vcpus_matched (also with other
conditions meet), ka->use_master_clock will be true;

3. After hot plug vcpu, kvm_arch_vcpu_postcreate and Qemu will call
kvm_write_tsc for the new vcpu. Because the tsc will not match, so do
kvm->arch.nr_vcpus_matched_tsc = 0;

4. For other already existed vcpu will not call kvm_write_tsc, so will not do
kvm->arch.nr_vcpus_matched_tsc++;

5. So vcpus_matched in function pvclock_update_vm_gtod_copy will be false
forever, this cause ka->use_master_clock will never be true;

-- 
You are receiving this mail because:
You are watching the assignee of the bug.

                 reply	other threads:[~2016-04-07  7:42 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-116011-28872@https.bugzilla.kernel.org/ \
    --to=bugzilla-daemon@bugzilla.kernel.org \
    --cc=kvm@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.