lkml.org 
[lkml]   [2015]   [Jun]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH 07/25] mm, vmscan: Make kswapd think of reclaim in terms of nodes
Date
> -	/* Reclaim above the high watermark. */
> - sc->nr_to_reclaim = max(SWAP_CLUSTER_MAX, high_wmark_pages(zone));
> + /* Aim to reclaim above all the zone high watermarks */
> + for (z = 0; z <= end_zone; z++) {
> + zone = pgdat->node_zones + end_zone;
s/end_zone/z/ ?
> + nr_to_reclaim += high_wmark_pages(zone);
>
[...]
> @@ -3280,13 +3177,26 @@ static unsigned long balance_pgdat(pg_data_t *pgdat, int order,
> compact_pgdat(pgdat, order);
>
> /*
> + * Stop reclaiming if any eligible zone is balanced and clear
> + * node writeback or congested.
> + */
> + for (i = 0; i <= *classzone_idx; i++) {
> + zone = pgdat->node_zones + i;
> +
> + if (zone_balanced(zone, sc.order, 0, *classzone_idx)) {
> + clear_bit(PGDAT_CONGESTED, &pgdat->flags);
> + clear_bit(PGDAT_DIRTY, &pgdat->flags);
> + break;
s/break/goto out/ ?
> + }
> + }
> +
> + /*
> * Raise priority if scanning rate is too low or there was no
> * progress in reclaiming pages
> */
> if (raise_priority || !sc.nr_reclaimed)
> sc.priority--;
> - } while (sc.priority >= 1 &&
> - !pgdat_balanced(pgdat, order, *classzone_idx));
> + } while (sc.priority >= 1);
>
> out:
> /*
> --
> 2.3.5



\
 
 \ /
  Last update: 2015-06-12 09:41    [W:0.046 / U:0.208 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site