[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <qetrwlvqekobedpwexeltaxqpnemenlfhky2t2razmcdtwlcv3@qdlesuiac2mr>
Date: Mon, 29 Jul 2024 10:44:12 +0200
From: Ondřej Jirman <megi@....cz>
To: Dragan Simic <dsimic@...jaro.org>
Cc: Jacobe Zang <jacobe.zang@...ion.com>, robh@...nel.org,
krzk+dt@...nel.org, heiko@...ech.de, kvalo@...nel.org, davem@...emloft.net,
edumazet@...gle.com, kuba@...nel.org, pabeni@...hat.com, conor+dt@...nel.org,
arend.vanspriel@...adcom.com, efectn@...tonmail.com, jagan@...eble.ai,
devicetree@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-rockchip@...ts.infradead.org, linux-kernel@...r.kernel.org, arend@...adcom.com,
linux-wireless@...r.kernel.org, netdev@...r.kernel.org, duoming@....edu.cn, bhelgaas@...gle.com,
minipli@...ecurity.net, brcm80211@...ts.linux.dev, brcm80211-dev-list.pdl@...adcom.com,
nick@...das.com
Subject: Re: [PATCH v4 4/5] wifi: brcmfmac: Add optional lpo clock enable
support
On Mon, Jul 29, 2024 at 09:12:20AM GMT, Dragan Simic wrote:
> Hello Jacobe,
>
> [...]
>
> >
> > + clk = devm_clk_get_optional_enabled(dev, "lpo");
> > + if (IS_ERR(clk))
> > + if (clk) {
>
> These two lines looks really confusing. Shouldn't it be just a single
> "if (!IS_ERR(clk)) {" line instead?
It should be `!IS_ERR(clk) && clk` otherwise the debug message will be
incorrect.
Kind regards,
o.
> > + brcmf_dbg(INFO, "enabling 32kHz clock\n");
> > + clk_set_rate(clk, 32768);
> > + }
> > +
> > if (!np || !of_device_is_compatible(np, "brcm,bcm4329-fmac"))
> > return;
Powered by blists - more mailing lists