f48c273b4a55589c97e901efa0691fcff9dfb8ed
[openwrt/svn-archive/archive.git] / target / linux / ixp4xx / patches-3.3 / 600-skb_avoid_dmabounce.patch
1 --- a/net/core/skbuff.c
2 +++ b/net/core/skbuff.c
3 @@ -176,6 +176,10 @@ struct sk_buff *__alloc_skb(unsigned int
4 struct sk_buff *skb;
5 u8 *data;
6
7 +#ifdef CONFIG_ARCH_IXP4XX
8 + gfp_mask |= GFP_DMA;
9 +#endif
10 +
11 cache = fclone ? skbuff_fclone_cache : skbuff_head_cache;
12
13 /* Get the HEAD */
14 @@ -929,6 +933,10 @@ int pskb_expand_head(struct sk_buff *skb
15 if (skb_shared(skb))
16 BUG();
17
18 +#ifdef CONFIG_ARCH_IXP4XX
19 + gfp_mask |= GFP_DMA;
20 +#endif
21 +
22 size = SKB_DATA_ALIGN(size);
23
24 /* Check if we can avoid taking references on fragments if we own