linux-sunxi.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: Daniel Lezcano <daniel.lezcano@linaro.org>
To: "Ondřej Jirman" <megi@xff.cz>,
	"Maxime Ripard" <maxime@cerno.tech>,
	"Christophe JAILLET" <christophe.jaillet@wanadoo.fr>,
	"Vasily Khoruzhick" <anarsoul@gmail.com>,
	"Yangtao Li" <tiny.windzz@gmail.com>,
	"Rafael J. Wysocki" <rafael@kernel.org>,
	"Amit Kucheria" <amitk@kernel.org>,
	"Zhang Rui" <rui.zhang@intel.com>, "Chen-Yu Tsai" <wens@csie.org>,
	"Jernej Skrabec" <jernej.skrabec@gmail.com>,
	"Samuel Holland" <samuel@sholland.org>,
	"Philipp Zabel" <p.zabel@pengutronix.de>,
	linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org,
	linux-pm@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-sunxi@lists.linux.dev
Subject: Re: [PATCH v2] thermal/drivers/sun8i: Fix some error handling paths in sun8i_ths_probe()
Date: Tue, 13 Jun 2023 10:49:24 +0200	[thread overview]
Message-ID: <ad78c18e-13dd-fca3-1aff-5b8e68a91c90@linaro.org> (raw)
In-Reply-To: <u7mmywm63bm5q4zlsbnooeplscn4rrd3qnslkfq2xnquxgnkkd@n3tsnrutmfjp>

On 15/05/2023 14:33, Ondřej Jirman wrote:
> Hi Maxime,
> 
> On Mon, May 15, 2023 at 01:54:41PM +0200, Maxime Ripard wrote:
>> Hi,
>>
>> On Sun, May 14, 2023 at 08:46:05PM +0200, Christophe JAILLET wrote:
>>> Should an error occur after calling sun8i_ths_resource_init() in the probe
>>> function, some resources need to be released, as already done in the
>>> .remove() function.
>>>
>>> Switch to the devm_clk_get_enabled() helper and add a new devm_action to
>>> turn sun8i_ths_resource_init() into a fully managed function.
>>>
>>> Move the place where reset_control_deassert() is called so that the
>>> recommended order of reset release/clock enable steps is kept.
>>> A64 manual states that:
>>>
>>> 	3.3.6.4. Gating and reset
>>>
>>> 	Make sure that the reset signal has been released before the release of
>>> 	module clock gating;
>>>
>>> This fixes the issue and removes some LoC at the same time.
>>
>> It should really be three different patches:
>>   - One to fix the resource release, that can be backported to stable
>>     releases
>>   - One to switch to devm_clk_get_enabled
>>   - and one to change the order of clock enable vs reset deassertion
> 
> The order was correct before this patch. I don't think an incorrect order
> should be intorduced, even if temporarily between two patches.

Maxime ?

-- 
<http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs

Follow Linaro:  <http://www.facebook.com/pages/Linaro> Facebook |
<http://twitter.com/#!/linaroorg> Twitter |
<http://www.linaro.org/linaro-blog/> Blog


  reply	other threads:[~2023-06-13  8:49 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-14 18:46 [PATCH v2] thermal/drivers/sun8i: Fix some error handling paths in sun8i_ths_probe() Christophe JAILLET
2023-05-15 11:54 ` Maxime Ripard
2023-05-15 12:33   ` Ondřej Jirman
2023-06-13  8:49     ` Daniel Lezcano [this message]
2023-06-13  9:16       ` Maxime Ripard
2023-06-13  9:17         ` Daniel Lezcano

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=ad78c18e-13dd-fca3-1aff-5b8e68a91c90@linaro.org \
    --to=daniel.lezcano@linaro.org \
    --cc=amitk@kernel.org \
    --cc=anarsoul@gmail.com \
    --cc=christophe.jaillet@wanadoo.fr \
    --cc=jernej.skrabec@gmail.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux-sunxi@lists.linux.dev \
    --cc=maxime@cerno.tech \
    --cc=megi@xff.cz \
    --cc=p.zabel@pengutronix.de \
    --cc=rafael@kernel.org \
    --cc=rui.zhang@intel.com \
    --cc=samuel@sholland.org \
    --cc=tiny.windzz@gmail.com \
    --cc=wens@csie.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).