From: Ulf Hansson <ulf.hansson@linaro.org>
To: Lina Iyer <lina.iyer@linaro.org>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>,
Len Brown <len.brown@intel.com>, Pavel Machek <pavel@ucw.cz>,
Kevin Hilman <khilman@kernel.org>,
Geert Uytterhoeven <geert@linux-m68k.org>,
Jon Hunter <jonathanh@nvidia.com>,
Marek Szyprowski <m.szyprowski@samsung.com>,
Brian Norris <briannorris@chromium.org>
Subject: Re: [PATCH] PM / Domains: Restore lock-less behaviour for the genpd syscore APIs
Date: Wed, 8 Feb 2017 13:41:25 +0100 [thread overview]
Message-ID: <CAPDyKFpvmp9TY6xyU_jS66zv-gSwuq3VBGkNFdQA9Obd4AWrCw@mail.gmail.com> (raw)
In-Reply-To: <20170207215229.GA2564@linaro.org>
Hi Lina,
--
>> drivers/base/power/domain.c | 48
>> +++++++++++++++++++++++++--------------------
>> 1 file changed, 27 insertions(+), 21 deletions(-)
>>
>> diff --git a/drivers/base/power/domain.c b/drivers/base/power/domain.c
>> index 271e208..3a75fb1 100644
>> --- a/drivers/base/power/domain.c
>> +++ b/drivers/base/power/domain.c
>> @@ -729,16 +729,17 @@ static bool genpd_dev_active_wakeup(struct
>> generic_pm_domain *genpd,
>> /**
>> * genpd_sync_power_off - Synchronously power off a PM domain and its
>> masters.
>> * @genpd: PM domain to power off, if possible.
>> + * @use_lock: use the lock.
>
>
> I am not too fond of this. It would rather be much cleaner if you could
> overload the genpd_lock/unlock() calls to make this genpd lockless. A
> flag for the genpd, perhaps that could turn the lock functions into a
> NOP?
That's not going to work, because this isn't about a lock-less genpd.
The problem occurs only during system suspend for a syscore device (in
this case the sh_cmt_clock_event device), calling pm_genpd_syscore*
APIs.
Kind regards
Uffe
prev parent reply other threads:[~2017-02-08 12:41 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-07 15:53 [PATCH] PM / Domains: Restore lock-less behaviour for the genpd syscore APIs Ulf Hansson
2017-02-07 18:29 ` Kevin Hilman
2017-02-08 12:06 ` Ulf Hansson
2017-02-08 12:06 ` Rafael J. Wysocki
2017-02-08 12:13 ` Ulf Hansson
2017-02-08 12:15 ` Rafael J. Wysocki
2017-02-08 12:35 ` Ulf Hansson
2017-02-07 19:09 ` Geert Uytterhoeven
2017-02-07 21:52 ` Lina Iyer
2017-02-08 12:41 ` Ulf Hansson [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=CAPDyKFpvmp9TY6xyU_jS66zv-gSwuq3VBGkNFdQA9Obd4AWrCw@mail.gmail.com \
--to=ulf.hansson@linaro.org \
--cc=briannorris@chromium.org \
--cc=geert@linux-m68k.org \
--cc=jonathanh@nvidia.com \
--cc=khilman@kernel.org \
--cc=len.brown@intel.com \
--cc=lina.iyer@linaro.org \
--cc=linux-pm@vger.kernel.org \
--cc=m.szyprowski@samsung.com \
--cc=pavel@ucw.cz \
--cc=rjw@rjwysocki.net \
/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).