diff options
author | Koen Kooi <koen@dominion.thruhere.net> | 2012-03-26 08:52:27 -0500 |
---|---|---|
committer | Denys Dmytriyenko <denys@ti.com> | 2012-03-30 19:04:44 -0400 |
commit | 7df8fc578b63662ec03ad3e69ecc6f04f7d77fb8 (patch) | |
tree | 3dcbd22c5b3298ab871b5cd2a02fb148af17778e /recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.12/0018-sfc-Fix-assignment-of-ip_summed-for-pre-allocated-sk.patch | |
parent | c5bb2de92249f802c7a038401b696be9c636895a (diff) | |
download | meta-ti-7df8fc578b63662ec03ad3e69ecc6f04f7d77fb8.tar.gz |
linux-ti33x-psp 3.2: update to 3.2.13
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Denys Dmytriyenko <denys@ti.com>
Diffstat (limited to 'recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.12/0018-sfc-Fix-assignment-of-ip_summed-for-pre-allocated-sk.patch')
-rw-r--r-- | recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.12/0018-sfc-Fix-assignment-of-ip_summed-for-pre-allocated-sk.patch | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.12/0018-sfc-Fix-assignment-of-ip_summed-for-pre-allocated-sk.patch b/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.12/0018-sfc-Fix-assignment-of-ip_summed-for-pre-allocated-sk.patch new file mode 100644 index 00000000..ac641a9b --- /dev/null +++ b/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.12/0018-sfc-Fix-assignment-of-ip_summed-for-pre-allocated-sk.patch | |||
@@ -0,0 +1,56 @@ | |||
1 | From 724515edd415300e12da1a3d2e84cadd6a5cd90b Mon Sep 17 00:00:00 2001 | ||
2 | From: Ben Hutchings <bhutchings@solarflare.com> | ||
3 | Date: Fri, 24 Feb 2012 15:12:34 +0000 | ||
4 | Subject: [PATCH 18/42] sfc: Fix assignment of ip_summed for pre-allocated | ||
5 | skbs | ||
6 | |||
7 | [ Upstream commit ff3bc1e7527504a93710535611b2f812f3bb89bf ] | ||
8 | |||
9 | When pre-allocating skbs for received packets, we set ip_summed = | ||
10 | CHECKSUM_UNNCESSARY. We used to change it back to CHECKSUM_NONE when | ||
11 | the received packet had an incorrect checksum or unhandled protocol. | ||
12 | |||
13 | Commit bc8acf2c8c3e43fcc192762a9f964b3e9a17748b ('drivers/net: avoid | ||
14 | some skb->ip_summed initializations') mistakenly replaced the latter | ||
15 | assignment with a DEBUG-only assertion that ip_summed == | ||
16 | CHECKSUM_NONE. This assertion is always false, but it seems no-one | ||
17 | has exercised this code path in a DEBUG build. | ||
18 | |||
19 | Fix this by moving our assignment of CHECKSUM_UNNECESSARY into | ||
20 | efx_rx_packet_gro(). | ||
21 | |||
22 | Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> | ||
23 | Signed-off-by: David S. Miller <davem@davemloft.net> | ||
24 | Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> | ||
25 | --- | ||
26 | drivers/net/ethernet/sfc/rx.c | 4 ++-- | ||
27 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
28 | |||
29 | diff --git a/drivers/net/ethernet/sfc/rx.c b/drivers/net/ethernet/sfc/rx.c | ||
30 | index 752d521..5ef4cc0 100644 | ||
31 | --- a/drivers/net/ethernet/sfc/rx.c | ||
32 | +++ b/drivers/net/ethernet/sfc/rx.c | ||
33 | @@ -156,11 +156,10 @@ static int efx_init_rx_buffers_skb(struct efx_rx_queue *rx_queue) | ||
34 | if (unlikely(!skb)) | ||
35 | return -ENOMEM; | ||
36 | |||
37 | - /* Adjust the SKB for padding and checksum */ | ||
38 | + /* Adjust the SKB for padding */ | ||
39 | skb_reserve(skb, NET_IP_ALIGN); | ||
40 | rx_buf->len = skb_len - NET_IP_ALIGN; | ||
41 | rx_buf->is_page = false; | ||
42 | - skb->ip_summed = CHECKSUM_UNNECESSARY; | ||
43 | |||
44 | rx_buf->dma_addr = pci_map_single(efx->pci_dev, | ||
45 | skb->data, rx_buf->len, | ||
46 | @@ -499,6 +498,7 @@ static void efx_rx_packet_gro(struct efx_channel *channel, | ||
47 | |||
48 | EFX_BUG_ON_PARANOID(!checksummed); | ||
49 | rx_buf->u.skb = NULL; | ||
50 | + skb->ip_summed = CHECKSUM_UNNECESSARY; | ||
51 | |||
52 | gro_result = napi_gro_receive(napi, skb); | ||
53 | } | ||
54 | -- | ||
55 | 1.7.9.4 | ||
56 | |||