[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250820040722.fdf2544cdz6k6dcq@vireshk-i7>
Date: Wed, 20 Aug 2025 09:37:22 +0530
From: Viresh Kumar <viresh.kumar@...aro.org>
To: Nicolas Frattaroli <nicolas.frattaroli@...labora.com>
Cc: Dan Carpenter <dan.carpenter@...aro.org>,
"Rafael J. Wysocki" <rafael@...nel.org>,
Matthias Brugger <matthias.bgg@...il.com>,
AngeloGioacchino Del Regno <angelogioacchino.delregno@...labora.com>,
kernel@...labora.com,
AngeloGioacchino Del Regno <angelogiaocchino.delregno@...labora.com>,
linux-pm@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org,
linux-mediatek@...ts.infradead.org
Subject: Re: [PATCH] cpufreq: mediatek-hw: don't use error path on NULL fdvfs
On 19-08-25, 13:21, Nicolas Frattaroli wrote:
> The IS_ERR_OR_NULL check for priv->fdvfs is inappropriate, and should be
> an IS_ERR check instead, as a NULL value here would propagate it to
> PTR_ERR.
>
> In practice, there is no problem here, as devm_of_iomap cannot return
> NULL in any circumstance. However, it causes a Smatch static checker
> warning.
>
> Fix the warning by changing the check from IS_ERR_OR_NULL to IS_ERR.
>
> Fixes: 32e0d669f3ac ("cpufreq: mediatek-hw: Add support for MT8196")
> Reported-by: Dan Carpenter <dan.carpenter@...aro.org>
> Closes: https://lore.kernel.org/linux-pm/aKQubSEXH1TXQpnR@stanley.mountain/
> Signed-off-by: Nicolas Frattaroli <nicolas.frattaroli@...labora.com>
> ---
> drivers/cpufreq/mediatek-cpufreq-hw.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied. Thanks.
--
viresh
Powered by blists - more mailing lists