From: Greg KH <gregkh@linuxfoundation.org>
To: Sudeep Holla <sudeep.holla@arm.com>
Cc: stable@vger.kernel.org, rafael.j.wysocki@intel.com,
ulf.hansson@linaro.org
Subject: Re: [PATCH v4.4 STABLE] PM / Domains: defer setting dev->pm_domain until genpd->attach_dev succeeds if present
Date: Thu, 3 Aug 2017 15:35:33 -0700 [thread overview]
Message-ID: <20170803223533.GE2396@kroah.com> (raw)
In-Reply-To: <1501063655-30208-1-git-send-email-sudeep.holla@arm.com>
On Wed, Jul 26, 2017 at 11:07:35AM +0100, Sudeep Holla wrote:
> commit 975e83cfb8dc16e7a2fdc58188c77c0c605876c2 upstream.
>
> If the genpd->attach_dev or genpd->power_on fails, genpd_dev_pm_attach
> may return -EPROBE_DEFER initially. However genpd_alloc_dev_data sets
> the PM domain for the device unconditionally.
>
> When subsequent attempts are made to call genpd_dev_pm_attach, it may
> return -EEXISTS checking dev->pm_domain without re-attempting to call
> attach_dev or power_on.
>
> platform_drv_probe then attempts to call drv->probe as the return value
> -EEXIST != -EPROBE_DEFER, which may end up in a situation where the
> device is accessed without it's power domain switched on.
>
> Fixes: f104e1e5ef57 (PM / Domains: Re-order initialization of generic_pm_domain_data)
> Cc: 4.4+ <stable@vger.kernel.org> # v4.4+
> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
> Acked-by: Ulf Hansson <ulf.hansson@linaro.org>
> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> ---
> drivers/base/power/domain.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
Now applied, thanks.
greg k-h
prev parent reply other threads:[~2017-08-03 22:35 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-25 17:54 FAILED: patch "[PATCH] PM / Domains: defer dev_pm_domain_set() until" failed to apply to 4.4-stable tree gregkh
2017-07-26 10:07 ` [PATCH v4.4 STABLE] PM / Domains: defer setting dev->pm_domain until genpd->attach_dev succeeds if present Sudeep Holla
2017-08-03 22:35 ` Greg KH [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=20170803223533.GE2396@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=rafael.j.wysocki@intel.com \
--cc=stable@vger.kernel.org \
--cc=sudeep.holla@arm.com \
--cc=ulf.hansson@linaro.org \
/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).