Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1246308
| From | Pan Xinhui <xinhuix.pan@intel.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH] gfp: GFP_RECLAIM_MASK should include __GFP_NO_KSWAPD |
| Date | 2015-10-14 07:40 +0200 |
| Message-ID | <qjmX7-5Me-9@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
From: Pan Xinhui <xinhuix.pan@intel.com>
GFP_RECLAIM_MASK was introduced in commit 6cb062296f73 ("Categorize GFP
flags"). In slub subsystem, this macro controls slub's allocation
behavior. In particular, some flags which are not in GFP_RECLAIM_MASK
will be cleared. So when slub pass this new gfp_flag into page
allocator, we might lost some very important flags.
There are some mistakes when we introduce __GFP_NO_KSWAPD. This flag is
used to avoid any scheduler-related codes recursive. But it seems like
patch author forgot to add it into GFP_RECLAIM_MASK. So lets add it now.
Signed-off-by: Pan Xinhui <xinhuix.pan@intel.com>
---
include/linux/gfp.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/linux/gfp.h b/include/linux/gfp.h
index f92cbd2..9ebad4d 100644
--- a/include/linux/gfp.h
+++ b/include/linux/gfp.h
@@ -130,7 +130,8 @@ struct vm_area_struct;
/* Control page allocator reclaim behavior */
#define GFP_RECLAIM_MASK (__GFP_WAIT|__GFP_HIGH|__GFP_IO|__GFP_FS|\
__GFP_NOWARN|__GFP_REPEAT|__GFP_NOFAIL|\
- __GFP_NORETRY|__GFP_MEMALLOC|__GFP_NOMEMALLOC)
+ __GFP_NORETRY|__GFP_MEMALLOC|__GFP_NOMEMALLOC|\
+ __GFP_NO_KSWAPD)
/* Control slab gfp mask during early boot */
#define GFP_BOOT_MASK (__GFP_BITS_MASK & ~(__GFP_WAIT|__GFP_IO|__GFP_FS))
--
1.9.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH] gfp: GFP_RECLAIM_MASK should include __GFP_NO_KSWAPD Pan Xinhui <xinhuix.pan@intel.com> - 2015-10-14 07:40 +0200
Re: [PATCH] gfp: GFP_RECLAIM_MASK should include __GFP_NO_KSWAPD Pan Xinhui <xinhuix.pan@intel.com> - 2015-10-14 08:10 +0200
Re: [PATCH] gfp: GFP_RECLAIM_MASK should include __GFP_NO_KSWAPD Michal Hocko <mhocko@kernel.org> - 2015-10-14 09:50 +0200
Re: [PATCH] gfp: GFP_RECLAIM_MASK should include __GFP_NO_KSWAPD Pan Xinhui <xinhuix.pan@intel.com> - 2015-10-14 10:40 +0200
Re: [PATCH] gfp: GFP_RECLAIM_MASK should include __GFP_NO_KSWAPD Michal Hocko <mhocko@kernel.org> - 2015-10-14 09:40 +0200
Re: [PATCH] gfp: GFP_RECLAIM_MASK should include __GFP_NO_KSWAPD Pan Xinhui <xinhuix.pan@intel.com> - 2015-10-14 10:30 +0200
Re: [PATCH] gfp: GFP_RECLAIM_MASK should include __GFP_NO_KSWAPD Michal Hocko <mhocko@kernel.org> - 2015-10-14 10:40 +0200
Re: [PATCH] gfp: GFP_RECLAIM_MASK should include __GFP_NO_KSWAPD Pan Xinhui <xinhuix.pan@intel.com> - 2015-10-14 10:50 +0200
csiph-web