From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
To: Oliver Chick <oliver.chick@citrix.com>
Cc: "xen-devel@lists.xen.org" <xen-devel@lists.xen.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] Persistent grant maps for xen blk drivers
Date: Thu, 20 Sep 2012 09:52:59 -0400 [thread overview]
Message-ID: <20120920135257.GD1998@localhost.localdomain> (raw)
In-Reply-To: <1348146745.24539.42.camel@oliverchick-Precision-WorkStation-T3400>
On Thu, Sep 20, 2012 at 02:12:25PM +0100, Oliver Chick wrote:
> Thank you for all your useful feedback, Konrad.
>
> I have made most of the changes you suggest. I will test them and
> repost. I have made a few points below.
Great. Looking forward to your next patch. Also pls include it
as an attachment as I could not apply it last time.. Not sure if
that is something with your mailer - but attachments usually survive
any MUA mangling.
> > > + page_to_pfn(pers_gnt->page));
> >
> > Would it make sense to cache this in the 'pers_gnt' structure?
>
> As far as I can tell, we only need this value when mapping, and
> unmapping. So if we cache it, we will use it a maximum of one time. I
> think it's cheap to calculate. Am I right?
Then lets not cache it.
> > > @@ -688,7 +804,7 @@ static int dispatch_rw_block_io(struct xen_blkif *blkif,
> > > for (i = 0; i < nseg; i++) {
> > > while ((bio == NULL) ||
> > > (bio_add_page(bio,
> > > - blkbk->pending_page(pending_req, i),
> >
> > Can we get rid of pending_page macro?
>
> Unfortunately not, it is still used in the non-persistent mode to
> populate the pages[].
Fair enough
> > > + memcpy(shared_data + sg->offset,
> > > + bvec_data + sg->offset,
> > > + sg->length);
> >
> > Do we need to worry about it spilling over a page? Should we check that
> > sg>offset + sg->length < PAGE_SIZE ?
>
> I agree, this is probably a worthwhile thing to check.
>
> >
> > Also this would imply that based on the offset (so say it is 3999) that the old data (0->3998)
> > might be still there - don't know how important that is?
>
> This is true. I spoke with IanC about this, and we *think* that this is
> ok. Any old data that is there will have already been given to blkback,
> so we're not really leaking data that we shouldn't be.
Put a comment in saying that. In case in the future we want to share
the persistent grants with other domains, we would need to address this.
next prev parent reply other threads:[~2012-09-20 13:53 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-19 10:51 [PATCH] Persistent grant maps for xen blk drivers Oliver Chick
2012-09-19 11:17 ` Konrad Rzeszutek Wilk
2012-09-19 12:03 ` [Xen-devel] " Jan Beulich
2012-09-20 8:51 ` Oliver Chick
2012-09-20 9:11 ` Jan Beulich
2012-09-19 13:16 ` Pasi Kärkkäinen
2012-09-20 9:35 ` Oliver Chick
2012-09-20 10:09 ` Pasi Kärkkäinen
2012-09-19 14:11 ` Konrad Rzeszutek Wilk
2012-09-20 13:12 ` Oliver Chick
2012-09-20 13:52 ` Konrad Rzeszutek Wilk [this message]
2012-09-20 10:34 ` [Xen-devel] " David Vrabel
2012-09-20 11:30 ` Oliver Chick
2012-09-20 11:48 ` Jan Beulich
2012-09-20 13:49 ` Konrad Rzeszutek Wilk
2012-09-20 14:13 ` Oliver Chick
2012-09-20 16:10 ` Jan Beulich
2012-09-20 21:24 ` Konrad Rzeszutek Wilk
2012-09-21 7:18 ` Jan Beulich
2012-09-21 8:41 ` Oliver Chick
2012-09-21 9:41 ` Jan Beulich
2012-09-21 8:10 ` Ian Campbell
2012-09-21 14:26 ` Konrad Rzeszutek Wilk
2012-09-20 15:35 ` Jan Beulich
2012-09-21 12:23 ` David Vrabel
2012-09-21 14:27 ` Konrad Rzeszutek Wilk
2012-09-21 16:17 ` David Vrabel
2012-09-21 17:13 ` Konrad Rzeszutek Wilk
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=20120920135257.GD1998@localhost.localdomain \
--to=konrad.wilk@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=oliver.chick@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