Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1638500 > unrolled thread
| Started by | Jason Wang <jasowang@redhat.com> |
|---|---|
| First post | 2017-05-10 04:40 +0200 |
| Last post | 2017-05-10 04:40 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH net-next V3 2/9] skb_array: introduce skb_array_unconsume Jason Wang <jasowang@redhat.com> - 2017-05-10 04:40 +0200
| From | Jason Wang <jasowang@redhat.com> |
|---|---|
| Date | 2017-05-10 04:40 +0200 |
| Subject | [PATCH net-next V3 2/9] skb_array: introduce skb_array_unconsume |
| Message-ID | <tFpHH-2eO-1@gated-at.bofh.it> |
Signed-off-by: Jason Wang <jasowang@redhat.com>
---
include/linux/skb_array.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/include/linux/skb_array.h b/include/linux/skb_array.h
index f4dfade..79850b6 100644
--- a/include/linux/skb_array.h
+++ b/include/linux/skb_array.h
@@ -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);
--
2.7.4
Back to top | Article view | linux.kernel
csiph-web