mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Ivan Pfarher via B4 Relay <devnull+ipfarher.gmail.com@kernel.org>
To: Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	 Conor Dooley <conor+dt@kernel.org>,
	Chen-Yu Tsai <wens@kernel.org>,
	 Jernej Skrabec <jernej.skrabec@gmail.com>,
	 Samuel Holland <samuel@sholland.org>
Cc: devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	 linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org,
	 Ivan Pfarher <ipfarher@gmail.com>
Subject: [PATCH v2 1/4] ARM: dts: allwinner: orangepi-zero-plus2: Add LPO clock for AP6212
Date: Thu, 03 Dec 2026 10:04:15 +0100	[thread overview]
Message-ID: <20261203-orangepi-zero-plus2-fixes-v2-1-286df6b782f4@gmail.com> (raw)
In-Reply-To: <20261203-orangepi-zero-plus2-fixes-v2-0-286df6b782f4@gmail.com>

From: Ivan Pfarher <ipfarher@gmail.com>

The H3 version of the Orange Pi Zero Plus2 is the same board as the H5
version, with the same AP6212 WiFi/BT module. Its LPO input is wired to
the RTC clock output (net AP-CK32KO from X32KFOUT in the schematic), but
nothing in the device tree references that clock, so it is disabled as
unused during late boot. Without the LPO, the Bluetooth ROM answers
HCI_Reset and nothing else, so the controller can never be brought up.

Reference the clock from the WiFi power sequence, as done for the H5
version.

Not tested on the H3 variant. The same change was tested on the H5
variant of the board (Linux 6.6.160), where it makes the Bluetooth
controller answer HCI commands. Build-tested only against current
mainline.

This problem was investigated, and the patch drafted, in an interactive
session with an AI coding assistant (Claude by Anthropic). The submitter
reviewed the change and ran the tests described above.

Fixes: cd3f03df13d4 ("ARM: dts: sun8i: Add initial Orangepi Zero Plus 2 H3 support")
Signed-off-by: Ivan Pfarher <ipfarher@gmail.com>
---
 arch/arm/boot/dts/allwinner/sun8i-h3-orangepi-zero-plus2.dts | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/arm/boot/dts/allwinner/sun8i-h3-orangepi-zero-plus2.dts b/arch/arm/boot/dts/allwinner/sun8i-h3-orangepi-zero-plus2.dts
index 97a3565ac..852723e94 100644
--- a/arch/arm/boot/dts/allwinner/sun8i-h3-orangepi-zero-plus2.dts
+++ b/arch/arm/boot/dts/allwinner/sun8i-h3-orangepi-zero-plus2.dts
@@ -45,6 +45,7 @@
 
 #include "sun8i-h3.dtsi"
 
+#include <dt-bindings/clock/sun6i-rtc.h>
 #include <dt-bindings/gpio/gpio.h>
 
 / {
@@ -94,6 +95,8 @@
 
 	wifi_pwrseq: pwrseq {
 		compatible = "mmc-pwrseq-simple";
+		clocks = <&rtc CLK_OSC32K_FANOUT>;
+		clock-names = "ext_clock";
 		reset-gpios = <&pio 0 9 GPIO_ACTIVE_LOW>; /* PA9 */
 		post-power-on-delay-ms = <200>;
 	};

-- 
2.43.0



  reply	other threads:[~2026-12-03  9:04 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-03  9:04 [PATCH v2 0/4] ARM: dts: allwinner: orangepi-zero-plus2: Fix Bluetooth and USB gadget Ivan Pfarher via B4 Relay
2026-12-03  9:04 ` Ivan Pfarher via B4 Relay [this message]
2026-12-03  9:04 ` [PATCH v2 2/4] ARM: dts: allwinner: orangepi-zero-plus2: Fix USB peripheral mode Ivan Pfarher via B4 Relay
2026-12-03  9:04 ` [PATCH v2 3/4] ARM: dts: allwinner: orangepi-zero-plus2: Share common board parts Ivan Pfarher via B4 Relay
2026-12-03  9:04 ` [PATCH v2 4/4] ARM: dts: allwinner: orangepi-zero-plus2: Add AP6212 Bluetooth Ivan Pfarher via B4 Relay
2026-12-03 10:35 ` [PATCH v2 0/4] ARM: dts: allwinner: orangepi-zero-plus2: Fix Bluetooth and USB gadget Chen-Yu Tsai

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=20261203-orangepi-zero-plus2-fixes-v2-1-286df6b782f4@gmail.com \
    --to=devnull+ipfarher.gmail.com@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=ipfarher@gmail.com \
    --cc=jernej.skrabec@gmail.com \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sunxi@lists.linux.dev \
    --cc=robh@kernel.org \
    --cc=samuel@sholland.org \
    --cc=wens@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

all inboxes | Powered by JetHome®