From: Marcelo Tosatti <mtosatti@redhat.com>
To: Peter Xu <peterx@redhat.com>
Cc: linux-kernel@vger.kernel.org,
Thomas Gleixner <tglx@linutronix.de>,
John Stultz <john.stultz@linaro.org>,
Stephen Boyd <sboyd@kernel.org>,
Luiz Capitulino <lcapitulino@redhat.com>
Subject: Re: [PATCH] timers: Fix up get_target_base() to use old base properly
Date: Thu, 6 Jun 2019 12:28:08 -0300 [thread overview]
Message-ID: <20190606152805.GA3652@amt.cnet> (raw)
In-Reply-To: <20190603132944.9726-1-peterx@redhat.com>
On Mon, Jun 03, 2019 at 09:29:44PM +0800, Peter Xu wrote:
> get_target_base() in the timer code is not using the "base" parameter
> at all. My gut feeling is that instead of removing that extra
> parameter, what we really want to do is "return the old base if it
> does not suite for a new one".
Hi Peter,
I think its a dead parameter: you always want to use the local base
if the timer is not pinned.
> CC: Thomas Gleixner <tglx@linutronix.de>
> CC: John Stultz <john.stultz@linaro.org>
> CC: Stephen Boyd <sboyd@kernel.org>
> CC: Luiz Capitulino <lcapitulino@redhat.com>
> CC: Marcelo Tosatti <mtosatti@redhat.com>
> CC: linux-kernel@vger.kernel.org
> Signed-off-by: Peter Xu <peterx@redhat.com>
> ---
> kernel/time/timer.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/kernel/time/timer.c b/kernel/time/timer.c
> index 343c7ba33b1c..6ff6ffd2c719 100644
> --- a/kernel/time/timer.c
> +++ b/kernel/time/timer.c
> @@ -868,7 +868,7 @@ get_target_base(struct timer_base *base, unsigned tflags)
> !(tflags & TIMER_PINNED))
> return get_timer_cpu_base(tflags, get_nohz_timer_target());
> #endif
> - return get_timer_this_cpu_base(tflags);
> + return base;
> }
>
> static inline void forward_timer_base(struct timer_base *base)
> --
> 2.17.1
next prev parent reply other threads:[~2019-06-06 15:28 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-03 13:29 [PATCH] timers: Fix up get_target_base() to use old base properly Peter Xu
2019-06-04 5:42 ` Peter Xu
2019-06-06 15:28 ` Marcelo Tosatti [this message]
2019-06-10 1:05 ` Peter Xu
2019-06-17 4:09 ` Peter Xu
2019-06-17 6:09 ` Thomas Gleixner
2019-06-17 9:11 ` Peter Xu
2019-06-17 12:07 ` Thomas Gleixner
2019-06-18 0:41 ` Peter Xu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190606152805.GA3652@amt.cnet \
--to=mtosatti@redhat.com \
--cc=john.stultz@linaro.org \
--cc=lcapitulino@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=peterx@redhat.com \
--cc=sboyd@kernel.org \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).