diff options
author | Christoph Lameter <clameter@sgi.com> | 2006-03-10 01:33:47 (GMT) |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-03-10 03:47:37 (GMT) |
commit | a6bf527091b1dd40f1b6a496812ce7520621c282 (patch) | |
tree | bed2341cbb2e4bf71d29f2e8b6ab7affa72aabd5 /mm/vmscan.c | |
parent | 04b857f74cec5efc7730e9db47e291310f4708a4 (diff) | |
download | linux-fsl-qoriq-a6bf527091b1dd40f1b6a496812ce7520621c282.tar.xz |
[PATCH] vmscan: no zone_reclaim if PF_MALLOC is set
If the process has already set PF_MALLOC and is already using
current->reclaim_state then do not try to reclaim memory from the zone.
This is set by kswapd and/or synchrononous global reclaim which will not
take it lightly if we zap the reclaim_state.
Signed-off-by: Christoph Lameter <clameter@sig.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'mm/vmscan.c')
-rw-r--r-- | mm/vmscan.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mm/vmscan.c b/mm/vmscan.c index b0af759..7ccf763 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c @@ -1883,7 +1883,8 @@ int zone_reclaim(struct zone *zone, gfp_t gfp_mask, unsigned int order) if (!(gfp_mask & __GFP_WAIT) || zone->all_unreclaimable || - atomic_read(&zone->reclaim_in_progress) > 0) + atomic_read(&zone->reclaim_in_progress) > 0 || + (p->flags & PF_MEMALLOC)) return 0; node_id = zone->zone_pgdat->node_id; |