From: Viresh Kumar <viresh.kumar@linaro.org>
To: Rafael Wysocki <rjw@rjwysocki.net>,
jy0922.shim@samsung.com, Viresh Kumar <vireshk@kernel.org>,
Nishanth Menon <nm@ti.com>, Stephen Boyd <sboyd@codeaurora.org>
Cc: linaro-kernel@lists.linaro.org, linux-pm@vger.kernel.org,
linux-kernel@vger.kernel.org,
Vincent Guittot <vincent.guittot@linaro.org>,
"# v4 . 4+" <stable@vger.kernel.org>
Subject: Re: [PATCH V4] PM / OPP: Pass opp_table to dev_pm_opp_put_regulator()
Date: Wed, 30 Nov 2016 16:17:45 +0530 [thread overview]
Message-ID: <20161130104745.GM3288@vireshk-i7> (raw)
In-Reply-To: <480ae6e161788d338fb1637aa2615a75588ac3c6.1480478081.git.viresh.kumar@linaro.org>
On 30-11-16, 09:29, Viresh Kumar wrote:
> +struct opp_table *dev_pm_opp_set_regulator(struct device *dev, const char *name)
> {
> struct opp_table *opp_table;
> struct regulator *reg;
> - int ret;
>
> mutex_lock(&opp_table_lock);
>
> opp_table = _add_opp_table(dev);
> if (!opp_table) {
> - ret = -ENOMEM;
> + opp_table = ERR_PTR(-ENOMEM);
> goto unlock;
> }
>
> /* This should be called before OPPs are initialized */
> if (WARN_ON(!list_empty(&opp_table->opp_list))) {
> - ret = -EBUSY;
> + opp_table = ERR_PTR(-EBUSY);
The pointer opp_table shouldn't be overwritten here as it will be used
in the error path. Will resend the patch shortly.
--
viresh
next prev parent reply other threads:[~2016-11-30 10:47 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20161130040034epcas5p4344849b26e8b5c435e658e3a0179cef6@epcas5p4.samsung.com>
2016-11-30 3:59 ` [PATCH V4] PM / OPP: Pass opp_table to dev_pm_opp_put_regulator() Viresh Kumar
2016-11-30 6:19 ` Joonyoung Shim
2016-11-30 8:05 ` Viresh Kumar
2016-12-01 1:45 ` Joonyoung Shim
2016-12-01 3:29 ` Viresh Kumar
2016-11-30 10:47 ` Viresh Kumar [this message]
2016-11-30 10:51 ` [PATCH V5] " Viresh Kumar
2016-11-30 22:00 ` Stephen Boyd
2016-12-01 0:25 ` Viresh Kumar
2016-12-01 14:28 ` 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=20161130104745.GM3288@vireshk-i7 \
--to=viresh.kumar@linaro.org \
--cc=jy0922.shim@samsung.com \
--cc=linaro-kernel@lists.linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=nm@ti.com \
--cc=rjw@rjwysocki.net \
--cc=sboyd@codeaurora.org \
--cc=stable@vger.kernel.org \
--cc=vincent.guittot@linaro.org \
--cc=vireshk@kernel.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