All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Alexander Graf <agraf@suse.de>, Don Slutz <dslutz@verizon.com>,
	qemu-devel@nongnu.org
Cc: xen-devel@lists.xensource.com,
	"Marcel Apfelbaum" <marcel.a@redhat.com>,
	"Michael S. Tsirkin" <mst@redhat.com>,
	"Markus Armbruster" <armbru@redhat.com>,
	"Anthony Liguori" <aliguori@amazon.com>,
	"Andreas Färber" <afaerber@suse.de>,
	"Stefano Stabellini" <stefano.stabellini@eu.citrix.com>
Subject: Re: [Qemu-devel] [PATCH 1/1] xen-hvm.c: Add support for Xen access to vmport
Date: Mon, 29 Sep 2014 14:21:35 +0200	[thread overview]
Message-ID: <54294ECF.1040705@redhat.com> (raw)
In-Reply-To: <54294832.9060001@suse.de>

Il 29/09/2014 13:53, Alexander Graf ha scritto:
> 
>   cpu_handle_ioreq()
>   {
>     ...
> 
>     if (req->type == IOPORT_REGISTERS_SYNCHRONIZED) {
>         cpu->xen_vcpu_dirty = true;
>         synchronize_xen_to_env(xenptr, cpu);
>     }
> 
>     handle_ioreq();
> 
>     if (req->type == IOPORT_REGISTERS_SYNCHRONIZED) {
>         cpu->xen_vcpu_dirty = false;
>         synchronize_env_to_xen(xenptr, cpu);
>     }
> 
>     ...
>   }
> 
>   void xen_cpu_synchronize_state(CPUState *cpu)
>   {
>     assert(cpu->xen_vcpu_dirty);
>   }
> 
> Then no changes to the vmport code would be necessary and this problems
> where some code path wants to do direct access to registers
> automatically tells us that things are broken.

Yeah, that would be possible.  You do not even need synchronize_state,
it seems to me that it introduces more complication for little gain.

Paolo

WARNING: multiple messages have this Message-ID (diff)
From: Paolo Bonzini <pbonzini@redhat.com>
To: Alexander Graf <agraf@suse.de>, Don Slutz <dslutz@verizon.com>,
	qemu-devel@nongnu.org
Cc: xen-devel@lists.xensource.com,
	"Marcel Apfelbaum" <marcel.a@redhat.com>,
	"Michael S. Tsirkin" <mst@redhat.com>,
	"Markus Armbruster" <armbru@redhat.com>,
	"Anthony Liguori" <aliguori@amazon.com>,
	"Andreas Färber" <afaerber@suse.de>,
	"Stefano Stabellini" <stefano.stabellini@eu.citrix.com>
Subject: Re: [PATCH 1/1] xen-hvm.c: Add support for Xen access to vmport
Date: Mon, 29 Sep 2014 14:21:35 +0200	[thread overview]
Message-ID: <54294ECF.1040705@redhat.com> (raw)
In-Reply-To: <54294832.9060001@suse.de>

Il 29/09/2014 13:53, Alexander Graf ha scritto:
> 
>   cpu_handle_ioreq()
>   {
>     ...
> 
>     if (req->type == IOPORT_REGISTERS_SYNCHRONIZED) {
>         cpu->xen_vcpu_dirty = true;
>         synchronize_xen_to_env(xenptr, cpu);
>     }
> 
>     handle_ioreq();
> 
>     if (req->type == IOPORT_REGISTERS_SYNCHRONIZED) {
>         cpu->xen_vcpu_dirty = false;
>         synchronize_env_to_xen(xenptr, cpu);
>     }
> 
>     ...
>   }
> 
>   void xen_cpu_synchronize_state(CPUState *cpu)
>   {
>     assert(cpu->xen_vcpu_dirty);
>   }
> 
> Then no changes to the vmport code would be necessary and this problems
> where some code path wants to do direct access to registers
> automatically tells us that things are broken.

Yeah, that would be possible.  You do not even need synchronize_state,
it seems to me that it introduces more complication for little gain.

Paolo

  reply	other threads:[~2014-09-29 12:22 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-26 18:47 [Qemu-devel] [PATCH 0/1] Add support for Xen access to vmport Don Slutz
2014-09-26 18:47 ` Don Slutz
2014-09-26 18:47 ` [Qemu-devel] [PATCH 1/1] xen-hvm.c: " Don Slutz
2014-09-26 18:47   ` Don Slutz
2014-09-29  8:12   ` [Qemu-devel] " Alexander Graf
2014-09-29  8:12     ` Alexander Graf
2014-09-29 11:10     ` [Qemu-devel] " Paolo Bonzini
2014-09-29 11:10       ` Paolo Bonzini
2014-09-29 11:53       ` [Qemu-devel] " Alexander Graf
2014-09-29 11:53         ` Alexander Graf
2014-09-29 12:21         ` Paolo Bonzini [this message]
2014-09-29 12:21           ` Paolo Bonzini
2014-09-29 12:57           ` [Qemu-devel] " Alexander Graf
2014-09-29 12:57             ` Alexander Graf
2014-09-29 13:14             ` [Qemu-devel] " Paolo Bonzini
2014-09-29 13:14               ` Paolo Bonzini
2014-09-30  1:05               ` [Qemu-devel] " Don Slutz
2014-09-30  1:05                 ` Don Slutz
2014-09-30  8:14                 ` [Qemu-devel] " Paolo Bonzini
2014-09-30  8:14                   ` Paolo Bonzini
2014-09-30  1:00         ` [Qemu-devel] " Don Slutz
2014-09-30  1:00           ` Don Slutz
2014-09-29 10:15   ` [Qemu-devel] " Stefano Stabellini
2014-09-29 10:15     ` Stefano Stabellini
2014-09-29 10:25     ` [Qemu-devel] " Stefano Stabellini
2014-09-29 10:25       ` Stefano Stabellini
2014-09-30  0:32       ` [Qemu-devel] " Don Slutz
2014-09-30  0:32         ` Don Slutz
2014-09-30 10:35         ` [Qemu-devel] " Stefano Stabellini
2014-09-30 10:35           ` Stefano Stabellini
2014-10-01  5:21           ` [Qemu-devel] " Slutz, Donald Christopher
2014-10-01  5:21             ` Slutz, Donald Christopher
2014-10-01  9:20             ` [Qemu-devel] " Stefano Stabellini
2014-10-01  9:20               ` Stefano Stabellini
2014-10-01 12:33               ` [Qemu-devel] " Don Slutz
2014-10-01 12:33                 ` Don Slutz
2014-10-01 14:44               ` [Qemu-devel] [Xen-devel] " Ian Campbell
2014-10-01 14:44                 ` Ian Campbell
2014-10-01 16:01                 ` [Qemu-devel] " Anthony Liguori
2014-10-01 16:01                   ` Anthony Liguori
2014-10-01 15:08               ` [Qemu-devel] " Paul Durrant
2014-10-01 15:08                 ` Paul Durrant

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=54294ECF.1040705@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=afaerber@suse.de \
    --cc=agraf@suse.de \
    --cc=aliguori@amazon.com \
    --cc=armbru@redhat.com \
    --cc=dslutz@verizon.com \
    --cc=marcel.a@redhat.com \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=xen-devel@lists.xensource.com \
    /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.