Bug 1432295 - Add gpa2hpa command to qemu hmp
Summary: Add gpa2hpa command to qemu hmp
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: qemu-kvm-rhev
Version: 7.4
Hardware: x86_64
OS: Unspecified
Target Milestone: rc
: ---
Assignee: Paolo Bonzini
QA Contact: Chao Yang
: 1450130 (view as bug list)
Depends On:
Blocks: 1335351
TreeView+ depends on / blocked
Reported: 2017-03-15 02:22 UTC by Guo, Zhiyi
Modified: 2017-08-02 03:39 UTC (History)
8 users (show)

Fixed In Version: qemu-kvm-rhev-2.9.0-2.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2017-08-02 03:39:56 UTC
Target Upstream Version:

Attachments (Terms of Use)
x-gpa2hpa patch (6.36 KB, application/mbox)
2017-03-15 02:22 UTC, Guo, Zhiyi
no flags Details

System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2017:2392 0 normal SHIPPED_LIVE Important: qemu-kvm-rhev security, bug fix, and enhancement update 2017-08-01 20:04:36 UTC

Description Guo, Zhiyi 2017-03-15 02:22:31 UTC
Created attachment 1263167 [details]
x-gpa2hpa patch

Description of problem:
Test against Bug 1402104 - [Intel 7.4 FEAT] KVM local MCE enabling - qemu
Without x-gpa2hpa command, only visibility of lmce can be tested but leave the functionnality cannot be tested inside guest.

x-gpa2hpa maybe for debug only, so could anyone help to confirm whether we need this command from qemu-kvm-rhev?

Attach the x-gpa2hpa patch provided by Zhang, Haozhong(haozhong.zhang@intel.com) from intel

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:

Actual results:

Expected results:

Additional info:

Comment 2 Miroslav Rezanina 2017-04-28 10:07:33 UTC
Fix included in qemu-kvm-rhev-2.9.0-2.el7

Comment 4 Ademar Reis 2017-06-08 01:50:32 UTC
*** Bug 1450130 has been marked as a duplicate of this bug. ***

Comment 5 Guo, Zhiyi 2017-06-15 10:01:35 UTC
Test against qemu-kvm-rhev-2.9.0-9.el7.x86_64, I can see gpa2hpa command in hmp. And use gpa2hpa following the way in https://bugzilla.redhat.com/attachment.cgi?id=1262511(this is attached to bug 1402102), I can pass the test steps written by Haozhong from intel.

1. run vtop to get guest address:
# ./vtop 
2. Translate address using gpa2hpa:
(qemu) gpa2hpa 0xa9260000
Host physical address for 0xa9260000 (pc.ram) is 0x123ffb000
3. In guest, write this address to SRAO and pass it to mce-inject.
echo "ADDR 0x123ffb000" >> SRAO
mce-inject < SRAO
4. Check key information from lmce log:
# cat /var/log/mcelog | grep SRAO
# cat /var/log/mcelog | grep 123ffb000
MISC 8c ADDR 123ffb000
# cat /var/log/mcelog | grep LMCE

Above test match the expect result from https://bugzilla.redhat.com/attachment.cgi?id=1262511

Per robert's result in Bug 1402104 - [Intel 7.4 FEAT] KVM local MCE enabling - qemu, intel confirm 1402104 is passed, so gpa2hpa is worked well in intel's verification.

So mark the bug verified.

Comment 7 errata-xmlrpc 2017-08-02 03:39:56 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


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