Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fa57079e authored by Swetha Chikkaboraiah's avatar Swetha Chikkaboraiah Committed by Gerrit - the friendly Code Review server
Browse files

net: support __alloc_skb to always use GFP_DMA



This makes it possible to ensure that any clients which use
__alloc_skb always allocate memory from the DMA zone.

Change-Id: I3b399b8da113e38a050b0b3e81eeaec549253bb9
Signed-off-by: default avatarLiam Mark <lmark@codeaurora.org>
Signed-off-by: default avatarSwetha Chikkaboraiah <schikk@codeaurora.org>
Signed-off-by: default avatarAshok Raj D <adeenada@codeaurora.org>
parent 670dc321
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -183,6 +183,9 @@ struct sk_buff *__alloc_skb(unsigned int size, gfp_t gfp_mask,
	u8 *data;
	bool pfmemalloc;

	if (IS_ENABLED(CONFIG_FORCE_ALLOC_FROM_DMA_ZONE))
		gfp_mask |= GFP_DMA;

	cache = (flags & SKB_ALLOC_FCLONE)
		? skbuff_fclone_cache : skbuff_head_cache;