qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: "Christian Borntraeger" <borntraeger@de.ibm.com>,
	"Alex Bennée" <alex.bennee@linaro.org>
Cc: Claudio Imbrenda <imbrenda@linux.vnet.ibm.com>, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v1 1/2] gdbstub: Fix single-step
Date: Mon, 10 Oct 2016 16:36:26 +0200	[thread overview]
Message-ID: <133a4c1d-d029-0bc2-d538-4e5c8e3dac1b@redhat.com> (raw)
In-Reply-To: <b4ce9f74-4a76-a23b-22ab-12b34f257c0f@de.ibm.com>



On 10/10/2016 14:51, Christian Borntraeger wrote:
> On 10/10/2016 01:50 PM, Claudio Imbrenda wrote:
>> Commit e0eeb4a21a3ca4b296220ce4449d8acef9de9049 introduced a bug that
>> causes single-step in the gdbstub to not work, at least in kvm. CPUs
>> that are supposed to single-step will instead run normally.
>>
>> This small patch fixes the problem. (tested on s390x)
>>
>> Signed-off-by: Claudio Imbrenda <imbrenda@linux.vnet.ibm.com>
>> ---
>>  kvm-all.c | 1 +
>>  1 file changed, 1 insertion(+)
>>
>> diff --git a/kvm-all.c b/kvm-all.c
>> index efb5fe3..46b8dcd 100644
>> --- a/kvm-all.c
>> +++ b/kvm-all.c
>> @@ -2237,6 +2237,7 @@ int kvm_update_guest_debug(CPUState *cpu, unsigned long reinject_trap)
>>          data.dbg.control |= KVM_GUESTDBG_ENABLE | KVM_GUESTDBG_SINGLESTEP;
>>      }
>>      kvm_arch_update_guest_debug(cpu, &data.dbg);
>> +    data.cpu = cpu;
>>
>>      run_on_cpu(cpu, kvm_invoke_set_guest_debug, &data);
>>      return data.err;
>>
> 
> Adding Alex and Paolo to cc.

The patch works but it also makes sense to use the new CPUState*
argument of kvm_invoke_set_guest_debug.  This way the
kvm_set_guest_debug_data struct doesn't need the "cpu" field anymore.

Paolo

  reply	other threads:[~2016-10-10 14:36 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-10 11:50 [Qemu-devel] [PATCH v1 0/2] Qemu: gdbstub: fix vCont and single-step Claudio Imbrenda
2016-10-10 11:50 ` [Qemu-devel] [PATCH v1 1/2] gdbstub: Fix single-step Claudio Imbrenda
2016-10-10 12:51   ` Christian Borntraeger
2016-10-10 14:36     ` Paolo Bonzini [this message]
2016-10-10 15:46       ` [Qemu-devel] [PATCH] kvm-all: don't use stale dbg_data->cpu Alex Bennée
2016-10-10 16:39         ` Paolo Bonzini
2016-10-10 17:18           ` Christian Borntraeger
2016-10-11 11:48         ` Claudio Imbrenda
2016-10-10 11:50 ` [Qemu-devel] [PATCH v1 2/2] gdbstub: Fix vCont behaviour Claudio Imbrenda
2016-10-11  8:18   ` Paolo Bonzini
2016-10-12 13:15     ` David Hildenbrand
2016-10-12 13:55       ` Claudio Imbrenda
2016-10-12 16:48         ` Paolo Bonzini
2016-10-12 18:38         ` David Hildenbrand
2016-10-13  7:49           ` Paolo Bonzini

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=133a4c1d-d029-0bc2-d538-4e5c8e3dac1b@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=alex.bennee@linaro.org \
    --cc=borntraeger@de.ibm.com \
    --cc=imbrenda@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).