Bug 656984 - TSC offset of virtual machines is not initialized correctly by 'kvm_amd' kernel module.
TSC offset of virtual machines is not initialized correctly by 'kvm_amd' kern...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: kvm (Show other bugs)
5.6
x86_64 Linux
high Severity high
: rc
: ---
Assigned To: Virtualization Maintenance
Virtualization Bugs
: ZStream
Depends On: 642659
Blocks: Rhel5KvmTier1
  Show dependency treegraph
 
Reported: 2010-11-24 11:08 EST by RHEL Product and Program Management
Modified: 2013-01-10 22:36 EST (History)
14 users (show)

See Also:
Fixed In Version: kvm-83-164.el5_5.30
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-12-20 12:37:20 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description RHEL Product and Program Management 2010-11-24 11:08:58 EST
This bug has been copied from bug #642659 and has been proposed
to be backported to 5.5 z-stream (EUS).
Comment 7 juzhang 2010-12-14 21:07:38 EST
Using the bz642659 comment26 test on kvm-83-164.el5_5.29,failed.

---snip of output---
crash> px ((struct vcpu_svm *)0xffff810133e841c0)->vcpu.arch.host_tsc
$9 = 0x1322fe6d16801

crash> px ((struct vcpu_svm *)0xffff810133e841c0)->vmcb.control.tsc_offset
$8 = 0xfffd9ba044aaf031

crash> px 0-0xfffd9ba044aaf031
$10 = 0x2645fbb550fcf

crash> pd 0x1322fe6d16801-0x2645fbb550fcf
$11 = -336655986960334
             -----The difference between host TSC and guest TSC offset is
-336655986960334(negative) cycles,so,failed.

Set this issue status as assigned.
Comment 8 Zachary Amsden 2010-12-14 23:48:07 EST
Fixes have not been ported to 5.5.z yet, so failure is expected.
Comment 9 Dor Laor 2010-12-15 03:06:11 EST
(In reply to comment #8)
> Fixes have not been ported to 5.5.z yet, so failure is expected.

Which fixes Zach? comment #4 states that the fixes are there. Are there more?
Comment 12 Zachary Amsden 2010-12-15 10:26:31 EST
(In reply to comment #9)
> (In reply to comment #8)
> > Fixes have not been ported to 5.5.z yet, so failure is expected.
> 
> Which fixes Zach? comment #4 states that the fixes are there. Are there more?

I checked the 5.5.z git tree and no changes had been ported.  I haven't worked with z-stream before so I'm not 100% familiar with the process.

Now I can't access git at all.

[zamsden@mysore rhel5.5.z]$ git pull
fatal: The remote end hung up unexpectedly

On second thought, perhaps I'm a bit confused.  The changes would be to the KVM module, which isn't part of the 5.5.z git tree.  In fact, I don't know where the KVM tree corresponding to 5.5.z lives.  Is there a kvm-rhel5.5.z.git tree to which these should be ported?

Also, there were two patches, the first required a correction.  Perhaps one of them is missing.

I'll check as soon as git access is restored.
Comment 13 Zachary Amsden 2010-12-15 10:45:00 EST
Okay, it looks as though the kvm-rhel5.5.z kmod is built from the branch rhel55/next in the kvm-rhel5 git tree, and that Eduardo just pulled the second fix into that branch.  All should be well now.
Comment 14 juzhang 2010-12-15 22:09:16 EST
Verified on kvm-83-164.el5_5.30,passed.

---snip of output---

crash> px ((struct vcpu_svm *)0xffff81011e19c040)->vcpu.arch.host_tsc
$6 = 0x1ef3ea5660f29
crash> px ((struct vcpu_svm *)0xffff81011e19c040)->vmcb.control.tsc_offset
$7 = 0xfffe10c16374676f
crash> px 0-0xfffe10c16374676f
$8 = 0x1ef3e9c8b9891
crash> pd 0x1ef3ea5660f29-0x1ef3e9c8b9891
$9 = 148534936

The difference between host TSC and guest TSC offset
              is only 148534936 cycles.
Comment 17 errata-xmlrpc 2010-12-20 12:37:20 EST
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2010-0998.html

Note You need to log in before you can comment on or make changes to this bug.