mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Viresh Kumar <viresh.kumar@linaro.org>
To: Pavel Machek <pavel@ucw.cz>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
	Len Brown <len.brown@intel.com>,
	linux-pm@vger.kernel.org,
	Vincent Guittot <vincent.guittot@linaro.org>,
	sunzhaosheng@hisilicon.com, jean.xupeng@hisilicon.com,
	yuwei3@hisilicon.com, gengyanping@hisilicon.com,
	peter.panshilin@hisilicon.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/2] PM / wakeup: Remove timer from wakeup_source_remove()
Date: Tue, 12 Mar 2019 17:11:47 +0530	[thread overview]
Message-ID: <20190312114147.emnt4ed4gpnyibyo@vireshk-i7> (raw)
In-Reply-To: <20190312090430.GA28905@amd>

On 12-03-19, 10:04, Pavel Machek wrote:
> On Tue 2019-03-12 08:58:02, Viresh Kumar wrote:
> > On 11-03-19, 13:05, Rafael J. Wysocki wrote:
> > > On Friday, March 8, 2019 10:53:11 AM CET Viresh Kumar wrote:
> > > > wakeup_source_remove() is the counterpart of wakeup_source_add() helper
> > > > and must undo the initializations done by wakeup_source_add(). Currently
> > > > the timer is initialized by wakeup_source_add() but removed from
> > > > wakeup_source_drop(), which doesn't look logically correct. Also it
> > > > should be okay to call wakeup_source_add() right after calling
> > > > wakeup_source_remove(), and in that case we may end up calling
> > > > timer_setup() for a potentially scheduled timer which is surely
> > > > incorrect.
> > > > 
> > > > Move the timer removal part to wakeup_source_remove() instead.
> 
> > > 
> > > I've merged it with the [2/2], rewritten the subject and changelog and
> > > queued the result as commit d856f39ac1cc ("PM / wakeup: Rework wakeup
> > > source timer cancellation").
> > 
> > Okay, thanks. We (Android guys) want this to be backported into 4.4+
> > kernels via the stable tree. Can we mark this for stable in the commit
> > itself ? Else I would be required to send this separately for all the
> > kernels. I should have marked it for stable initially though, sorry
> > about forgetting then.
> 
> Greg is normally pretty agressive about backporting everything
> remotely looking like a fix...
> 
> But better changelog would help. How is the bug actually affecting
> users?

The Android wakelock infrastructure (not in mainline) is based on the
wakeup sources stuff and that is where we found the issue. A wakelock
was taken due to a bug in user driver and the board never attempts
going into suspend anymore.

If this patch doesn't go into the stable kernels, I would be required
to send this separately for Android kernels and the Android guys will
suggest getting it via stable tree.

And because this fixes a potential issue it was worth trying getting
it via the stable kernel :)

-- 
viresh

      reply	other threads:[~2019-03-12 11:41 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-08  9:53 Viresh Kumar
2019-03-08  9:53 ` [PATCH 2/2] PM / wakeup: Clear timer.function in wakeup_source_remove() Viresh Kumar
2019-03-11 12:05 ` [PATCH 1/2] PM / wakeup: Remove timer from wakeup_source_remove() Rafael J. Wysocki
2019-03-12  3:28   ` Viresh Kumar
2019-03-12  9:03     ` Rafael J. Wysocki
2019-03-12  9:04     ` Pavel Machek
2019-03-12 11:41       ` Viresh Kumar [this message]

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=20190312114147.emnt4ed4gpnyibyo@vireshk-i7 \
    --to=viresh.kumar@linaro.org \
    --cc=gengyanping@hisilicon.com \
    --cc=jean.xupeng@hisilicon.com \
    --cc=len.brown@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=pavel@ucw.cz \
    --cc=peter.panshilin@hisilicon.com \
    --cc=rjw@rjwysocki.net \
    --cc=sunzhaosheng@hisilicon.com \
    --cc=vincent.guittot@linaro.org \
    --cc=yuwei3@hisilicon.com \
    /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

all inboxes | Powered by JetHome®