From: Arend van Spriel <arend.vanspriel@broadcom.com>
To: Dragan Simic <dsimic@manjaro.org>
Cc: Jacobe Zang <jacobe.zang@wesion.com>,
robh@kernel.org, krzk+dt@kernel.org, heiko@sntech.de,
kvalo@kernel.org, davem@davemloft.net, edumazet@google.com,
kuba@kernel.org, pabeni@redhat.com, conor+dt@kernel.org,
efectn@protonmail.com, jagan@edgeble.ai,
devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org,
arend@broadcom.com, linux-wireless@vger.kernel.org,
netdev@vger.kernel.org, duoming@zju.edu.cn, bhelgaas@google.com,
minipli@grsecurity.net, brcm80211@lists.linux.dev,
brcm80211-dev-list.pdl@broadcom.com, nick@khadas.com
Subject: Re: [PATCH v4 4/5] wifi: brcmfmac: Add optional lpo clock enable support
Date: Mon, 29 Jul 2024 11:55:39 +0200 [thread overview]
Message-ID: <f21a111a-e4e1-45ee-b116-8e52c70777a8@broadcom.com> (raw)
In-Reply-To: <9f248b0e2645a29b83ee503701e04d57@manjaro.org>
On 7/29/2024 11:12 AM, Dragan Simic wrote:
> Hello Ondrej,
>
> On 2024-07-29 10:44, Ondřej Jirman wrote:
>> 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.
>
> Ah, I see now, thanks. There's also IS_ERR_OR_NULL, so the condition
> can actually be "!IS_ERR_OR_NULL(clk)".
++ best suggestion
>>> > + brcmf_dbg(INFO, "enabling 32kHz clock\n");
>>> > + clk_set_rate(clk, 32768);
>>> > + }
>>> > +
>>> > if (!np || !of_device_is_compatible(np, "brcm,bcm4329-fmac"))
>>> > return;
next prev parent reply other threads:[~2024-07-29 9:55 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-29 7:00 [PATCH v4 0/5] Add AP6275P wireless support Jacobe Zang
2024-07-29 7:00 ` [PATCH v4 1/5] dt-bindings: net: wireless: brcm4329-fmac: add pci14e4,449d Jacobe Zang
2024-07-29 7:00 ` [PATCH v4 2/5] dt-bindings: net: wireless: brcm4329-fmac: add clock description for AP6275P Wi-Fi device Jacobe Zang
2024-07-29 7:35 ` Krzysztof Kozlowski
2024-07-29 8:17 ` Jacobe Zang
2024-07-29 9:01 ` Arend van Spriel
2024-07-29 7:01 ` [PATCH v4 3/5] arm64: dts: rockchip: Add AP6275P wireless support to Khadas Edge 2 Jacobe Zang
2024-07-29 7:01 ` [PATCH v4 4/5] wifi: brcmfmac: Add optional lpo clock enable support Jacobe Zang
2024-07-29 7:12 ` Dragan Simic
2024-07-29 7:17 ` Jacobe Zang
2024-07-29 8:44 ` Ondřej Jirman
2024-07-29 9:12 ` Dragan Simic
2024-07-29 9:55 ` Arend van Spriel [this message]
2024-07-29 7:01 ` [PATCH v4 5/5] wifi: brcmfmac: add flag for random seed during firmware download Jacobe Zang
2024-07-29 8:11 ` Arend van Spriel
2024-07-29 8:19 ` Jacobe Zang
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=f21a111a-e4e1-45ee-b116-8e52c70777a8@broadcom.com \
--to=arend.vanspriel@broadcom.com \
--cc=arend@broadcom.com \
--cc=bhelgaas@google.com \
--cc=brcm80211-dev-list.pdl@broadcom.com \
--cc=brcm80211@lists.linux.dev \
--cc=conor+dt@kernel.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=dsimic@manjaro.org \
--cc=duoming@zju.edu.cn \
--cc=edumazet@google.com \
--cc=efectn@protonmail.com \
--cc=heiko@sntech.de \
--cc=jacobe.zang@wesion.com \
--cc=jagan@edgeble.ai \
--cc=krzk+dt@kernel.org \
--cc=kuba@kernel.org \
--cc=kvalo@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=linux-wireless@vger.kernel.org \
--cc=minipli@grsecurity.net \
--cc=netdev@vger.kernel.org \
--cc=nick@khadas.com \
--cc=pabeni@redhat.com \
--cc=robh@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