[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAPDyKFohY+p8c9R3M82jcGrRxEA6V6fGyOUBz6ABMQQjyxKBzw@mail.gmail.com>
Date: Fri, 13 Sep 2024 14:01:59 +0200
From: Ulf Hansson <ulf.hansson@...aro.org>
To: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
Cc: Heiko Stuebner <heiko@...ech.de>, linux-pm@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, linux-rockchip@...ts.infradead.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] pmdomain: rockchip: Simplify dropping OF node reference
On Sun, 25 Aug 2024 at 20:31, Krzysztof Kozlowski
<krzysztof.kozlowski@...aro.org> wrote:
>
> Drop OF node reference immediately after using it in
> syscon_node_to_regmap(), which is both simpler and typical/expected
> code pattern.
>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
Applied for next, thanks!
Kind regards
Uffe
> ---
> drivers/pmdomain/rockchip/pm-domains.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/pmdomain/rockchip/pm-domains.c b/drivers/pmdomain/rockchip/pm-domains.c
> index 64b4d7120d83..5ee7efbd2ef8 100644
> --- a/drivers/pmdomain/rockchip/pm-domains.c
> +++ b/drivers/pmdomain/rockchip/pm-domains.c
> @@ -716,12 +716,11 @@ static int rockchip_pm_add_one_domain(struct rockchip_pmu *pmu,
> goto err_unprepare_clocks;
> }
> pd->qos_regmap[j] = syscon_node_to_regmap(qos_node);
> + of_node_put(qos_node);
> if (IS_ERR(pd->qos_regmap[j])) {
> error = -ENODEV;
> - of_node_put(qos_node);
> goto err_unprepare_clocks;
> }
> - of_node_put(qos_node);
> }
> }
>
> --
> 2.43.0
>
Powered by blists - more mailing lists