Skip to contentSkip to conversation

net, skbuff: Get rid of unused skb_propagate_pfmemalloc

PATCH In review [email protected] 1 participant 2 messages Aug 27, 2015 – Sep 25, 2015 Networking

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net, skbuff: Get rid of unused skb_propagate_pfmemalloc

From: Michal Hocko <[email protected]>

It seems that skb_propagate_pfmemalloc has never had a user since it was introduced by 0614002bb5f7 ("netvm: propagate page->pfmemalloc from skb_alloc_page to skb"). Remove it.

---
Hi,
this has been noticed while working on 2f064f3485cd ("mm: make page pfmemalloc check more robust").

 include/linux/skbuff.h | 12 ------------
 1 file changed, 12 deletions(-)
include/linux/skbuff.h +0 -12
index 9b88536487e6..9fcf69daa26c 100644
@@ -2252,18 +2252,6 @@ static inline struct page *dev_alloc_page(void)
 }
 
 /**
- *	skb_propagate_pfmemalloc - Propagate pfmemalloc if skb is allocated after RX page
- *	@page: The page that was allocated from skb_alloc_page
- *	@skb: The skb that may need pfmemalloc set
- */
-static inline void skb_propagate_pfmemalloc(struct page *page,
-					     struct sk_buff *skb)
-{
-	if (page_is_pfmemalloc(page))
-		skb->pfmemalloc = true;
-}
-
-/**
  * skb_frag_page - retrieve the page referred to by a paged fragment
  * @frag: the paged fragment
  *
Signature · 1 line
2.5.0
#1 lore raw
Quoted 11 lines · On Thu 27-08-15 10:46:37, [email protected] wrote:

From: Michal Hocko <[email protected]>

It seems that skb_propagate_pfmemalloc has never had a user since it was introduced by 0614002bb5f7 ("netvm: propagate page->pfmemalloc from skb_alloc_page to skb"). Remove it.

---
Hi,
this has been noticed while working on 2f064f3485cd ("mm: make page pfmemalloc check more robust").

Has this just fallen through cracks or it is not interesting?

Quoted 30 lines
 include/linux/skbuff.h | 12 ------------
 1 file changed, 12 deletions(-)
include/linux/skbuff.h +0 -12
index 9b88536487e6..9fcf69daa26c 100644
@@ -2252,18 +2252,6 @@ static inline struct page *dev_alloc_page(void)
 }
 
 /**
- *	skb_propagate_pfmemalloc - Propagate pfmemalloc if skb is allocated after RX page
- *	@page: The page that was allocated from skb_alloc_page
- *	@skb: The skb that may need pfmemalloc set
- */
-static inline void skb_propagate_pfmemalloc(struct page *page,
-					     struct sk_buff *skb)
-{
-	if (page_is_pfmemalloc(page))
-		skb->pfmemalloc = true;
-}
-
-/**
  * skb_frag_page - retrieve the page referred to by a paged fragment
  * @frag: the paged fragment
  *
Signature · 1 line
2.5.0
Signature · 2 lines
Michal Hocko
SUSE Labs