>> >> - page = alloc_page(gfp_mask); >> + page = skb_frag_page(f); >> + if (page_count(page) == 1) { >> + skb_frag_ref(skb, i); > > This could be : get_page(page);
Ah, indeed. Thanks. > >> + goto copy_done; >> + } >> + >> + if (f->size > PAGE_SIZE) { >> + order = get_order(f->size); >> + mask |= __GFP_COMP; > > Note that this would probably fail under memory pressure. > > We could instead try to explode the few segments into order-0 only > pages. Good point. I'll revise to use only order-0 here.