From mboxrd@z Thu Jan 1 00:00:00 1970
From: bugzilla-daemon@bugzilla.kernel.org
Subject: [Bug 65561] KVM:Entry failed on Single stepping sti instruction
Date: Sun, 25 May 2014 06:46:13 +0000
Message-ID:
References:
Mime-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
To: kvm@vger.kernel.org
Return-path:
Received: from mail.kernel.org ([198.145.19.201]:51961 "EHLO mail.kernel.org"
rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP
id S1751227AbaEYGqQ (ORCPT );
Sun, 25 May 2014 02:46:16 -0400
Received: from mail.kernel.org (localhost [127.0.0.1])
by mail.kernel.org (Postfix) with ESMTP id 7B5352037E
for ; Sun, 25 May 2014 06:46:15 +0000 (UTC)
Received: from bugzilla1.web.kernel.org (bugzilla1.web.kernel.org [172.20.200.51])
by mail.kernel.org (Postfix) with ESMTP id DB22220117
for ; Sun, 25 May 2014 06:46:13 +0000 (UTC)
In-Reply-To:
Sender: kvm-owner@vger.kernel.org
List-ID:
https://bugzilla.kernel.org/show_bug.cgi?id=65561
--- Comment #31 from Jidong Xiao ---
Hi, Paolo,
I added a sti instruction in kvm-unit-tests:x86/debug.c, like this:
asm volatile(
"pushf\n\t"
"pop %%rax\n\t"
"sti\n\t"
"or $(1<<8),%%rax\n\t"
"push %%rax\n\t"
"lea (%%rip),%0\n\t"
"popf\n\t"
"and $~(1<<8),%%rax\n\t"
"push %%rax\n\t"
"popf\n\t"
: "=g" (start) : : "rax");
report("single step",
n == 3 &&
bp_addr[0] == start+1+6 && dr6[0] == 0xffff4ff0 &&
bp_addr[1] == start+1+6+1 && dr6[1] == 0xffff4ff0 &&
bp_addr[2] == start+1+6+1+1 && dr6[2] == 0xffff4ff0);
And then make, and run the test, it looks like everything is okay.
linux:~/code/kvm-unit-tests # /usr/local2/bin/qemu-system-x86_64 -enable-kvm
-device pc-testdev -serial stdio -device isa-debug-exit,iobase=0xf4,iosize=0x4
-kernel ./x86/debug.flat
enabling apic
PASS: #BP
PASS: hw breakpoint
PASS: single step
PASS: hw watchpoint
I also tried to add a cli before sti, and the test also passed.
--
You are receiving this mail because:
You are watching the assignee of the bug.