xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Shriram Rajagopalan <rshriram@cs.ubc.ca>
To: Daniel Stodden <daniel.stodden@citrix.com>
Cc: Xen Developers <xen-devel@lists.xensource.com>
Subject: Re: xen-blkfront: simplify resume?
Date: Thu, 24 Mar 2011 13:08:42 -0700	[thread overview]
Message-ID: <AANLkTik6PRJ3qrBBfg=2=J4gnmoRSiaPjZRxbAXW6BL2@mail.gmail.com> (raw)
In-Reply-To: <1300959061.3507.1600.camel@ramone.fritz.box>


[-- Attachment #1.1: Type: text/plain, Size: 1637 bytes --]

On Thu, Mar 24, 2011 at 2:31 AM, Daniel Stodden
<daniel.stodden@citrix.com>wrote:

>
> Dear xen-devel.
>
> I think the blkif_recover (blkfront's transparent VM resume) stuff looks
> quite overcomplicated.
>
> We copy the ring message to a shadow request allocated during submit, a
> process involving some none-obvious-looking get_id_from_freelist()
> subroutine to obtain a vector slot, and a memcpy.
>
> When receiving a resume callback from xenstore, we memcpy the entire
> shadow vector, reset the original one to zero, then reallocate the
> thereby freed shadow entries and not only copy the message on the ring,
> but the shadow back into the shadow vector just freed to keep stuff
> consistent. Hmmm.
>
> I wonder, should we just take the pending request and push it back onto
> the request_queue (with a blk_requeue_request)?
>
> Different from the present code, this should also help preserve original
> submit order if done right. (Don't panic, not like it matters a lot
> anymore since the block barrier flags are gone.)
>
> If we want to keep the shadow copy, let's do so with a prep_rq_fn. It
> gets called before the request gets pulled off the queue. Looks nicer,
> and one can arrange things so it only gets called once.
>
> Counter opinions?
>
> A bit confused. If things were as simple as stuffing the pending reqs back
into the req_queue, why resort to shadowing the requests in the first place?
(esp, with the blk barrier flags gone)

shriram

> Thanks,
> Daniel
>
>
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel
>

[-- Attachment #1.2: Type: text/html, Size: 2323 bytes --]

[-- Attachment #2: Type: text/plain, Size: 138 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel

  reply	other threads:[~2011-03-24 20:08 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-24  9:31 xen-blkfront: simplify resume? Daniel Stodden
2011-03-24 20:08 ` Shriram Rajagopalan [this message]
2011-03-24 21:46   ` Daniel Stodden
2011-03-24 21:47 ` Keir Fraser
2011-03-25  2:39   ` Daniel Stodden

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='AANLkTik6PRJ3qrBBfg=2=J4gnmoRSiaPjZRxbAXW6BL2@mail.gmail.com' \
    --to=rshriram@cs.ubc.ca \
    --cc=daniel.stodden@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 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).