aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mm/vmscan.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/mm/vmscan.c b/mm/vmscan.c
index 465bfa54dfd6..0ca6007d655b 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -1599,17 +1599,23 @@ int zone_reclaim(struct zone *zone, gfp_t gfp_mask, unsigned int order)
1599 struct task_struct *p = current; 1599 struct task_struct *p = current;
1600 struct reclaim_state reclaim_state; 1600 struct reclaim_state reclaim_state;
1601 struct scan_control sc; 1601 struct scan_control sc;
1602 cpumask_t mask;
1603 int node_id;
1602 1604
1603 if (time_before(jiffies, 1605 if (time_before(jiffies,
1604 zone->last_unsuccessful_zone_reclaim + ZONE_RECLAIM_INTERVAL)) 1606 zone->last_unsuccessful_zone_reclaim + ZONE_RECLAIM_INTERVAL))
1605 return 0; 1607 return 0;
1606 1608
1607 if (!(gfp_mask & __GFP_WAIT) || 1609 if (!(gfp_mask & __GFP_WAIT) ||
1608 zone->zone_pgdat->node_id != numa_node_id() ||
1609 zone->all_unreclaimable || 1610 zone->all_unreclaimable ||
1610 atomic_read(&zone->reclaim_in_progress) > 0) 1611 atomic_read(&zone->reclaim_in_progress) > 0)
1611 return 0; 1612 return 0;
1612 1613
1614 node_id = zone->zone_pgdat->node_id;
1615 mask = node_to_cpumask(node_id);
1616 if (!cpus_empty(mask) && node_id != numa_node_id())
1617 return 0;
1618
1613 sc.may_writepage = 0; 1619 sc.may_writepage = 0;
1614 sc.may_swap = 0; 1620 sc.may_swap = 0;
1615 sc.nr_scanned = 0; 1621 sc.nr_scanned = 0;