mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-21 14:11:20 +00:00
skb_array: introduce skb_array_unconsume
Signed-off-by: Jason Wang <jasowang@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
197a5212c3
commit
3acb696015
1 changed files with 6 additions and 0 deletions
|
@ -156,6 +156,12 @@ static void __skb_array_destroy_skb(void *ptr)
|
|||
kfree_skb(ptr);
|
||||
}
|
||||
|
||||
static inline void skb_array_unconsume(struct skb_array *a,
|
||||
struct sk_buff **skbs, int n)
|
||||
{
|
||||
ptr_ring_unconsume(&a->ring, (void **)skbs, n, __skb_array_destroy_skb);
|
||||
}
|
||||
|
||||
static inline int skb_array_resize(struct skb_array *a, int size, gfp_t gfp)
|
||||
{
|
||||
return ptr_ring_resize(&a->ring, size, gfp, __skb_array_destroy_skb);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue