From: Jon Hunter <jonathanh@nvidia.com>
To: Geert Uytterhoeven <geert@linux-m68k.org>,
Ulf Hansson <ulf.hansson@linaro.org>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
Kevin Hilman <khilman@kernel.org>,
Linux PM list <linux-pm@vger.kernel.org>,
Len Brown <len.brown@intel.com>, Pavel Machek <pavel@ucw.cz>,
Geert Uytterhoeven <geert+renesas@glider.be>,
Lina Iyer <lina.iyer@linaro.org>,
Axel Haslam <ahaslam@baylibre.com>,
Marek Szyprowski <m.szyprowski@samsung.com>,
Andy Gross <andy.gross@linaro.org>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Subject: Re: [PATCH] PM / Domains: Convert pm_genpd_init() to return an error code
Date: Fri, 17 Jun 2016 13:07:37 +0100 [thread overview]
Message-ID: <5763E809.3040200@nvidia.com> (raw)
In-Reply-To: <CAMuHMdVofBY-kNULQHWmoAuovLfK4HG4Ce1VORrKekOG9vAbWg@mail.gmail.com>
On 17/06/16 11:59, Geert Uytterhoeven wrote:
> On Fri, Jun 17, 2016 at 12:27 PM, Ulf Hansson <ulf.hansson@linaro.org> wrote:
>> The are already cases when pm_genpd_init() can fail. Currently we hide the
>> failures instead of propagating an error code, which is a better method.
>>
>> Moreover, to prepare for future changes like moving away from using a
>> fixed array-size of the struct genpd_power_state, to instead dynamically
>> allocate data for it, the pm_genpd_init() API needs to be able to return
>> an error code, as allocation can fail.
>>
>> Current users of the pm_genpd_init() is thus requested to start dealing
>> with error codes. In the transition phase, users will have to live with
>> only error messages being printed to log.
>
> What can we do in case of error? It's not like anything is going to work
> if PM domains are failing...
It seems natural that you would WARN and skip any failing PM domains and
just initialise all the ones you can. Hopefully, not all would fail and
you would have some functionality ...
Cheers
Jon
--
nvpublic
next prev parent reply other threads:[~2016-06-17 12:07 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-17 10:27 [PATCH] PM / Domains: Convert pm_genpd_init() to return an error code Ulf Hansson
2016-06-17 10:59 ` Geert Uytterhoeven
2016-06-17 12:07 ` Jon Hunter [this message]
2016-06-20 11:17 ` Ulf Hansson
2016-06-20 18:00 ` Kevin Hilman
2016-07-04 13:06 ` Rafael J. Wysocki
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=5763E809.3040200@nvidia.com \
--to=jonathanh@nvidia.com \
--cc=ahaslam@baylibre.com \
--cc=andy.gross@linaro.org \
--cc=geert+renesas@glider.be \
--cc=geert@linux-m68k.org \
--cc=khilman@kernel.org \
--cc=laurent.pinchart@ideasonboard.com \
--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 \
--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).