[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH RFC] xen-netback: coalesce frags before copying



On Fri, 2013-03-15 at 10:42 +0000, Ian Campbell wrote:

> >                     goto err;
> >  
> > -           gop->source.u.ref = txp->gref;
> > -           gop->source.domid = vif->domid;
> > -           gop->source.offset = txp->offset;
> > -
> > -           gop->dest.u.gmfn = virt_to_mfn(page_address(page));
> > -           gop->dest.domid = DOMID_SELF;
> > -           gop->dest.offset = txp->offset;
> > -
> > -           gop->len = txp->size;
> > -           gop->flags = GNTCOPY_source_gref;
> > +           nr_txp = 0;
> > +           dst_offset = 0;
> > +           first = NULL;
> > +           while (dst_offset < PAGE_SIZE && j < nr_frags) {
> 
> I think splitting the handling of a single request slot into a function
> would be useful for clarity. e.g. xen_netbk_handle_one_request or
> something.
> 

Regarding this comment, I think it looks better as-is. This loop is
closely related to the outer loop.


Wei.



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.