[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20170926111211.GC25906@in.ibm.com>
Date: Tue, 26 Sep 2017 16:42:11 +0530
From: Gautham R Shenoy <ego@...ux.vnet.ibm.com>
To: Kees Cook <keescook@...omium.org>
Cc: Thomas Gleixner <tglx@...utronix.de>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 03/31] timer: Remove init_timer_pinned_deferrable() in
favor of setup_pinned_deferrable_timer()
On Wed, Sep 20, 2017 at 04:27:27PM -0700, Kees Cook wrote:
> Remove uses of init_timer_pinned_deferrable() with open-coded
> function and data assignments that could be expressed using
> setup_pinned_deferrable_timer().
>
> Signed-off-by: Kees Cook <keescook@...omium.org>
Reviewed-by: Gautham R. Shenoy <ego@...ux.vnet.ibm.com>
> ---
> drivers/cpufreq/powernv-cpufreq.c | 5 ++---
> include/linux/timer.h | 2 --
> 2 files changed, 2 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufreq/powernv-cpufreq.c
> index 3ff5160451b4..3946660b0987 100644
> --- a/drivers/cpufreq/powernv-cpufreq.c
> +++ b/drivers/cpufreq/powernv-cpufreq.c
> @@ -800,9 +800,8 @@ static int powernv_cpufreq_cpu_init(struct cpufreq_policy *policy)
> policy->driver_data = gpstates;
>
> /* initialize timer */
> - init_timer_pinned_deferrable(&gpstates->timer);
> - gpstates->timer.data = (unsigned long)policy;
> - gpstates->timer.function = gpstate_timer_handler;
> + setup_pinned_deferrable_timer(&gpstates->timer, gpstate_timer_handler,
> + (unsigned long)policy);
> gpstates->timer.expires = jiffies +
> msecs_to_jiffies(GPSTATE_TIMER_INTERVAL);
> spin_lock_init(&gpstates->gpstate_lock);
> diff --git a/include/linux/timer.h b/include/linux/timer.h
> index e6789b8757d5..1b2bb2d978de 100644
> --- a/include/linux/timer.h
> +++ b/include/linux/timer.h
> @@ -132,8 +132,6 @@ static inline void init_timer_on_stack_key(struct timer_list *timer,
> __init_timer((timer), TIMER_PINNED)
> #define init_timer_deferrable(timer) \
> __init_timer((timer), TIMER_DEFERRABLE)
> -#define init_timer_pinned_deferrable(timer) \
> - __init_timer((timer), TIMER_DEFERRABLE | TIMER_PINNED)
> #define init_timer_on_stack(timer) \
> __init_timer_on_stack((timer), 0)
>
> --
> 2.7.4
>
Powered by blists - more mailing lists