Displaying 16 results from an estimated 16 matches for "skb_frag_unref".
2013 Oct 31
6
[PATCH net-next 1/2] net: introduce skb_coalesce_rx_frag()
...b_add_rx_frag);
+void skb_coalesce_rx_frag(struct sk_buff *skb, int i, int off, int size,
+ unsigned int truesize)
+{
+ skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
+
+ skb_frag_size_add(frag, size);
+ skb->len += size;
+ skb->data_len += size;
+ skb->truesize += truesize;
+ skb_frag_unref(skb, i);
+}
+EXPORT_SYMBOL(skb_coalesce_rx_frag);
+
static void skb_drop_list(struct sk_buff **listp)
{
kfree_skb_list(*listp);
--
1.8.1.2
2013 Oct 31
6
[PATCH net-next 1/2] net: introduce skb_coalesce_rx_frag()
...b_add_rx_frag);
+void skb_coalesce_rx_frag(struct sk_buff *skb, int i, int off, int size,
+ unsigned int truesize)
+{
+ skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
+
+ skb_frag_size_add(frag, size);
+ skb->len += size;
+ skb->data_len += size;
+ skb->truesize += truesize;
+ skb_frag_unref(skb, i);
+}
+EXPORT_SYMBOL(skb_coalesce_rx_frag);
+
static void skb_drop_list(struct sk_buff **listp)
{
kfree_skb_list(*listp);
--
1.8.1.2
2013 Nov 01
5
[PATCH net-next V3 1/2] net: introduce skb_coalesce_rx_frag()
...au>
Cc: Michael S. Tsirkin <mst at redhat.com>
Cc: Michael Dalton <mwdalton at google.com>
Cc: Eric Dumazet <edumazet at google.com>
Acked-by: Michael S. Tsirkin <mst at redhat.com>
Signed-off-by: Jason Wang <jasowang at redhat.com>
---
Changes from V2:
- remove the skb_frag_unref() and let the called to put the page reference
Changes from V1:
- remove the useless off parameter.
---
include/linux/skbuff.h | 3 +++
net/core/skbuff.c | 12 ++++++++++++
2 files changed, 15 insertions(+)
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h
index 2c15497..fffaeaf...
2013 Nov 01
5
[PATCH net-next V3 1/2] net: introduce skb_coalesce_rx_frag()
...au>
Cc: Michael S. Tsirkin <mst at redhat.com>
Cc: Michael Dalton <mwdalton at google.com>
Cc: Eric Dumazet <edumazet at google.com>
Acked-by: Michael S. Tsirkin <mst at redhat.com>
Signed-off-by: Jason Wang <jasowang at redhat.com>
---
Changes from V2:
- remove the skb_frag_unref() and let the called to put the page reference
Changes from V1:
- remove the useless off parameter.
---
include/linux/skbuff.h | 3 +++
net/core/skbuff.c | 12 ++++++++++++
2 files changed, 15 insertions(+)
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h
index 2c15497..fffaeaf...
2013 Oct 31
4
[PATCH net-next V2 1/2] net: introduce skb_coalesce_rx_frag()
...SYMBOL(skb_add_rx_frag);
+void skb_coalesce_rx_frag(struct sk_buff *skb, int i, int size,
+ unsigned int truesize)
+{
+ skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
+
+ skb_frag_size_add(frag, size);
+ skb->len += size;
+ skb->data_len += size;
+ skb->truesize += truesize;
+ skb_frag_unref(skb, i);
+}
+EXPORT_SYMBOL(skb_coalesce_rx_frag);
+
static void skb_drop_list(struct sk_buff **listp)
{
kfree_skb_list(*listp);
--
1.8.1.2
2013 Oct 31
4
[PATCH net-next V2 1/2] net: introduce skb_coalesce_rx_frag()
...SYMBOL(skb_add_rx_frag);
+void skb_coalesce_rx_frag(struct sk_buff *skb, int i, int size,
+ unsigned int truesize)
+{
+ skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
+
+ skb_frag_size_add(frag, size);
+ skb->len += size;
+ skb->data_len += size;
+ skb->truesize += truesize;
+ skb_frag_unref(skb, i);
+}
+EXPORT_SYMBOL(skb_coalesce_rx_frag);
+
static void skb_drop_list(struct sk_buff **listp)
{
kfree_skb_list(*listp);
--
1.8.1.2
2013 Oct 31
0
[PATCH net-next 1/2] net: introduce skb_coalesce_rx_frag()
...gt; + skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
>> > +
>> > + skb_frag_size_add(frag, size);
>> > + skb->len += size;
>> > + skb->data_len += size;
>> > + skb->truesize += truesize;
>> > + skb_frag_unref(skb, i);
>> > +}
> I didn't see you use "off" in skb_coalesce_rx_frag.
>
Ture, it's useless. Will post V2.
Thanks
2013 Oct 31
0
[PATCH net-next 1/2] net: introduce skb_coalesce_rx_frag()
...unsigned int truesize)
> +{
> + skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
> +
> + skb_frag_size_add(frag, size);
> + skb->len += size;
> + skb->data_len += size;
> + skb->truesize += truesize;
> + skb_frag_unref(skb, i);
> +}
I didn't see you use "off" in skb_coalesce_rx_frag.
> +EXPORT_SYMBOL(skb_coalesce_rx_frag);
> +
> static void skb_drop_list(struct sk_buff **listp)
> {
> kfree_skb_list(*listp);
> --
> 1.8.1.2
>
> --
> To unsubscribe from thi...
2013 Oct 31
0
[PATCH net-next 1/2] net: introduce skb_coalesce_rx_frag()
...unsigned int truesize)
> +{
> + skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
> +
> + skb_frag_size_add(frag, size);
> + skb->len += size;
> + skb->data_len += size;
> + skb->truesize += truesize;
> + skb_frag_unref(skb, i);
> +}
I didn't see you use "off" in skb_coalesce_rx_frag.
> +EXPORT_SYMBOL(skb_coalesce_rx_frag);
> +
> static void skb_drop_list(struct sk_buff **listp)
> {
> kfree_skb_list(*listp);
> --
> 1.8.1.2
>
> --
> To unsubscribe from thi...
2013 Oct 31
0
[PATCH net-next V2 1/2] net: introduce skb_coalesce_rx_frag()
...x_frag(struct sk_buff *skb, int i, int size,
> + unsigned int truesize)
> +{
> + skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
> +
> + skb_frag_size_add(frag, size);
> + skb->len += size;
> + skb->data_len += size;
> + skb->truesize += truesize;
> + skb_frag_unref(skb, i);
This unref is not logical, or should at least be
__skb_frag_unref(frag);
But I do think this is best done in the caller.
In virtio_net this would be a :
put_page(page);
In tcp stack we do almost the same, but we take the reference on the
page if we could not coalesce with prio frag,...
2012 Oct 31
8
[PATCHv2 net-next 0/8] enable/disable zero copy tx dynamically
tun supports zero copy transmit since 0690899b4d4501b3505be069b9a687e68ccbe15b,
however you can only enable this mode if you know your workload does not
trigger heavy guest to host/host to guest traffic - otherwise you
get a (minor) performance regression.
This patchset addresses this problem by notifying the owner
device when callback is invoked because of a data copy.
This makes it possible to
2012 Oct 31
8
[PATCHv2 net-next 0/8] enable/disable zero copy tx dynamically
tun supports zero copy transmit since 0690899b4d4501b3505be069b9a687e68ccbe15b,
however you can only enable this mode if you know your workload does not
trigger heavy guest to host/host to guest traffic - otherwise you
get a (minor) performance regression.
This patchset addresses this problem by notifying the owner
device when callback is invoked because of a data copy.
This makes it possible to
2012 Oct 29
9
[PATCH net-next 0/8] enable/disable zero copy tx dynamically
tun supports zero copy transmit since 0690899b4d4501b3505be069b9a687e68ccbe15b,
however you can only enable this mode if you know your workload does not
trigger heavy guest to host/host to guest traffic - otherwise you
get a (minor) performance regression.
This patchset addresses this problem by notifying the owner
device when callback is invoked because of a data copy.
This makes it possible to
2012 Oct 29
9
[PATCH net-next 0/8] enable/disable zero copy tx dynamically
tun supports zero copy transmit since 0690899b4d4501b3505be069b9a687e68ccbe15b,
however you can only enable this mode if you know your workload does not
trigger heavy guest to host/host to guest traffic - otherwise you
get a (minor) performance regression.
This patchset addresses this problem by notifying the owner
device when callback is invoked because of a data copy.
This makes it possible to
2012 Nov 01
9
[PATCHv3 net-next 0/8] enable/disable zero copy tx dynamically
tun supports zero copy transmit since 0690899b4d4501b3505be069b9a687e68ccbe15b,
however you can only enable this mode if you know your workload does not
trigger heavy guest to host/host to guest traffic - otherwise you
get a (minor) performance regression.
This patchset addresses this problem by notifying the owner
device when callback is invoked because of a data copy.
This makes it possible to
2012 Nov 01
9
[PATCHv3 net-next 0/8] enable/disable zero copy tx dynamically
tun supports zero copy transmit since 0690899b4d4501b3505be069b9a687e68ccbe15b,
however you can only enable this mode if you know your workload does not
trigger heavy guest to host/host to guest traffic - otherwise you
get a (minor) performance regression.
This patchset addresses this problem by notifying the owner
device when callback is invoked because of a data copy.
This makes it possible to