xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Anthony PERARD <anthony.perard@citrix.com>
To: Ian Campbell <Ian.Campbell@citrix.com>
Cc: Stefano Stabellini <Stefano.Stabellini@eu.citrix.com>,
	Xen Devel <xen-devel@lists.xen.org>
Subject: Re: [PATCH] xen: Fix BUFIOREQ evtchn init for a stubdom.
Date: Tue, 26 Jun 2012 16:06:09 +0100	[thread overview]
Message-ID: <CAJJyHjKMisPam2b2m-_tRHno9rC+UUBHdPRAnqGR_E3MfxYXBg@mail.gmail.com> (raw)
In-Reply-To: <1340720499.3832.132.camel@zakaz.uk.xensource.com>

On Tue, Jun 26, 2012 at 3:21 PM, Ian Campbell <Ian.Campbell@citrix.com> wrote:
> On Tue, 2012-06-26 at 15:13 +0100, Anthony PERARD wrote:
>> On Tue, Jun 26, 2012 at 11:54 AM, Ian Campbell <Ian.Campbell@citrix.com> wrote:
>> > On Tue, 2012-06-26 at 11:45 +0100, Anthony PERARD wrote:
>> >> This is a missing part from the previous patch that add the BUFIOREQ_EVTCHN
>> >> parameter. This patch changes the ownership of the buifioreq event channel to
>> >> the stubdom (when HVM_PARAM_DM_DOMAIN is set within the stubdom).
>> >>
>> >> This fix the initialization of QEMU inside the stubdomain.
>> >>
>> >> Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
>> >
>> > This fixes stub domains for me, thanks.
>> >
>> > The user of this field (hvm_buffered_io_send) takes iorp->lock so we
>> > probably want to put the update inside that too, just like for the
>> > non-buffered case?
>>
>> Will do.
>>
>> > It would be nice to extract the alloc&replace functionality into a
>> > helper.
>>
>> I tried but it does not work well.
>> xen_port is an it (non-buffer case) and params[bufioreq...] is an
>> uint64_t. Both should be argument of the helper, as a pointer to be
>> pass to xchg().
>>
>> The prototype of the not working helper:
>> static int hvm_replace_event_channel(struct vcpu *v, uint64_t
>> remote_domid, int *port)
>>
>> So unless there is another way to create this helper, there won't be any.
>
> Although params[...] are generally uint64_t the params[BUFIOREQ_EVTCHN]
> is really an int (or more properly an evtchn_port_t, although this is
> only used in include/public). Perhaps a cast is appropriate in this
> case?

All right, I will cast.

-- 
Anthony PERARD

      reply	other threads:[~2012-06-26 15:06 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-26 10:45 [PATCH] xen: Fix BUFIOREQ evtchn init for a stubdom Anthony PERARD
2012-06-26 10:54 ` Ian Campbell
2012-06-26 14:13   ` Anthony PERARD
2012-06-26 14:21     ` Ian Campbell
2012-06-26 15:06       ` Anthony PERARD [this message]

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=CAJJyHjKMisPam2b2m-_tRHno9rC+UUBHdPRAnqGR_E3MfxYXBg@mail.gmail.com \
    --to=anthony.perard@citrix.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=Stefano.Stabellini@eu.citrix.com \
    --cc=xen-devel@lists.xen.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).