kernel: update 3.10 to 3.10.32
[openwrt.git] / target / linux / ixp4xx / patches-3.10 / 600-skb_avoid_dmabounce.patch
1 --- a/net/core/skbuff.c
2 +++ b/net/core/skbuff.c
3 @@ -208,6 +208,9 @@ struct sk_buff *__alloc_skb(unsigned int
4  
5         if (sk_memalloc_socks() && (flags & SKB_ALLOC_RX))
6                 gfp_mask |= __GFP_MEMALLOC;
7 +#ifdef CONFIG_ARCH_IXP4XX
8 +       gfp_mask |= GFP_DMA;
9 +#endif
10  
11         /* Get the HEAD */
12         skb = kmem_cache_alloc_node(cache, gfp_mask & ~__GFP_DMA, node);
13 @@ -1052,6 +1055,10 @@ int pskb_expand_head(struct sk_buff *skb
14         if (skb_shared(skb))
15                 BUG();
16  
17 +#ifdef CONFIG_ARCH_IXP4XX
18 +       gfp_mask |= GFP_DMA;
19 +#endif
20 +
21         size = SKB_DATA_ALIGN(size);
22  
23         if (skb_pfmemalloc(skb))