Re: [PATCH] mm, vmstat: make quiet_vmstat lighter (was: Re: fast path cycle muncher (vmstat: make vmstat_updater deferrable) again and shut down on idle)

From: Christoph Lameter
Date: Thu Jan 28 2016 - 11:42:29 EST


On Thu, 28 Jan 2016, Michal Hocko wrote:

> Thinking about it some more, making vmstat_update deferrable should help
> to not interrupt idle no?

It will align with the tick then. Yes indeed this should be done.
> ---
> diff --git a/mm/vmstat.c b/mm/vmstat.c
> index eb30bf45bd55..69537d2be6f6 100644
> --- a/mm/vmstat.c
> +++ b/mm/vmstat.c
> @@ -1512,7 +1512,7 @@ static void __init start_shepherd_timer(void)
> int cpu;
>
> for_each_possible_cpu(cpu)
> - INIT_DELAYED_WORK(per_cpu_ptr(&vmstat_work, cpu),
> + INIT_DEFERRABLE_WORK(per_cpu_ptr(&vmstat_work, cpu),
> vmstat_update);
>
> if (!alloc_cpumask_var(&cpu_stat_off, GFP_KERNEL))
>