Re: [PATCH 1/2] arm64: dts: rockchip: Fix the BT clock-names on rk3399-hugsun-x99

[email protected]
Newsgroups org.kernel.vger.linux-devicetree
Message-ID <[email protected]>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] Incorrect DT clock-name misrepresents a 32.768kHz LPO clock as a high-frequency txco clock, bypassing driver rate enforcement.
--

--- Patch [1]: [PATCH 1/2] arm64: dts: rockchip: Fix the BT clock-names on rk3399-hugsun-x99 ---
commit 9f58538cc4607e21e187cba8faf882820a368c05
Author: Fabio Estevam <[email protected]>

arm64: dts: rockchip: Fix the BT clock-names on rk3399-hugsun-x99

This commit updates the clock-names property for the Bluetooth node on
the rk3399-hugsun-x99 board to fix a dt-schema warning. It changes the
name from ext_clock to txco.

> diff --git a/arch/arm64/boot/dts/rockchip/rk3399-hugsun-x99.dts b/arch/arm64/boot/dts/rockchip/rk3399-hugsun-x99.dts
> --- a/arch/arm64/boot/dts/rockchip/rk3399-hugsun-x99.dts
> +++ b/arch/arm64/boot/dts/rockchip/rk3399-hugsun-x99.dts
> @@ -703,7 +703,7 @@ &uart0 {
>  	bluetooth {
>  		compatible = "brcm,bcm43438-bt";
>  		clocks = <&rk808 1>;
> -		clock-names = "ext_clock";
> +		clock-names = "txco";

[Severity: Low]
Should this clock be named lpo instead of txco?

The clock source <&rk808 1> is the PMIC's rtc_clko_wifi output, which
is a fixed 32.768kHz clock. According to the Bluetooth architecture and
brcm,bluetooth.yaml, a 32.768kHz clock represents the Low Power Oscillator
(lpo), while txco is typically reserved for high-frequency reference clocks
(like 26MHz or 37.4MHz).

If it is named txco, does the hci_bcm driver misclassify it and leave
its internal lpo_clk reference NULL? This would bypass the driver's
explicit 32kHz rate enforcement via clk_set_rate(dev->lpo_clk, 32768).

>  		device-wakeup-gpios = <&gpio2 RK_PD2 GPIO_ACTIVE_HIGH>;
>  		host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>;
>  		shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>;

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=1
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.