On Fri, Sep 07, 2018 at 11:22:00AM +0800, Jason Wang wrote:
Why bother with refcounting for a drop though? It should be simple.Yes, I have patch on top to amortize this, the idea is to have a very big@@ -1668,6 +1668,9 @@ static struct sk_buff *tun_build_skb(struct tun_struct *tun,This adds an atomic op on XDP_DROP which is a data path
if (copied != len)
return ERR_PTR(-EFAULT);
+ get_page(alloc_frag->page);
+ alloc_frag->offset += buflen;
+
operation for some workloads.
refcount once after the frag was allocated and maintain a bias and decrease
them all when allocating new frags.'