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

Re: [Xen-devel] BUG in xennet_make_frags with paged skb data



2014-11-10 16:42 GMT+00:00 David Vrabel <david.vrabel@xxxxxxxxxx>:
On 10/11/14 16:39, Zoltan Kiss wrote:
>
> The BUG_ON suggested by Stefan would be still reasonable:
>
> BUG_ON(((page-compound_head(page))*PAGE_SIZE)+offset+len >
> PAGE_SIZE<<compound_order(compound_head(page)));

Well, it wouldn't trigger but I don't think it is useful any more.

David


Looks like this structure was designed to just contains physical single pages and was extended to support compound pages however there are still some functions that assume the usage of single pages. Just for instance the offset/size of fragments are computed from PAGE_SIZE. On x86 (4KB pages) if your compound page is bigger than 64KB you cannot fully use for a fragment as offset/size are 16 bits. Some functions in skbuff.c use kmap which is limited to physical page.

Frediano

_______________________________________________
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®.