[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] Adjust skb->truesize appropriately in netback driver.
# HG changeset patch # User kaf24@xxxxxxxxxxxxxxxxxxxx # Node ID 9aba6cd8e9e1c1b3c5b13b4c32096db8b36cb03e # Parent 9ce1e7c67d5d9994ee01268fcee2cedf0fc916e5 Adjust skb->truesize appropriately in netback driver. When you generate non-linear skb's as netback does, it is up to you to ensure that truesize reflects the size of paged part of the skb. Otherwise socket memory accounting in Linux falls apart. Thanks to the new check that David Miller added to TCP we were able to catch this bug. Signed-off-by: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx> --- linux-2.6-xen-sparse/drivers/xen/netback/netback.c | 1 + 1 files changed, 1 insertion(+) diff -r 9ce1e7c67d5d -r 9aba6cd8e9e1 linux-2.6-xen-sparse/drivers/xen/netback/netback.c --- a/linux-2.6-xen-sparse/drivers/xen/netback/netback.c Fri May 05 13:46:59 2006 +0100 +++ b/linux-2.6-xen-sparse/drivers/xen/netback/netback.c Fri May 05 13:49:49 2006 +0100 @@ -659,6 +659,7 @@ static void net_tx_action(unsigned long skb->data_len = txreq.size - data_len; skb->len += skb->data_len; + skb->truesize += skb->data_len; skb->dev = netif->dev; skb->protocol = eth_type_trans(skb, skb->dev); _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |