From: Wei Deng <wei.deng@oss.qualcomm.com>
To: konrad.dybcio@oss.qualcomm.com
Cc: manivannan.sadhasivam@oss.qualcomm.com, mani@kernel.org,
loic.poulain@oss.qualcomm.com, andersson@kernel.org,
konradybcio@kernel.org, robh@kernel.org, krzk+dt@kernel.org,
conor+dt@kernel.org, linux-bluetooth@vger.kernel.org,
linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org, quic_chezhou@quicinc.com,
cheng.jiang@oss.qualcomm.com, shuai.zhang@oss.qualcomm.com,
jinwang.li@oss.qualcomm.com, xiuzhuo.shang@oss.qualcomm.com,
mengshi.wu@oss.qualcomm.com
Subject: Re: [PATCH 2/2] arm64: dts: qcom: monaco-evk: Describe the PCIe M.2 Key E connector
Date: Tue, 25 Aug 2026 14:57:15 +0530 [thread overview]
Message-ID: <20260825092715.5794-1-wei.deng@oss.qualcomm.com> (raw)
In-Reply-To: <0303224f-4c2c-46ec-9866-5ea1fd0fb4a3@oss.qualcomm.com>
Hi Konrad,
On Wed, 19 Aug 2026 16:24:35 +0200, Konrad Dybcio wrote:
> On 8/19/26 4:13 PM, Wei Deng wrote:
> > On Wed, 29 Jul 2026 08:06:54 +0530, Wei Deng wrote:
> >> Fair point. I will move the port/endpoint anchors to monaco.dtsi in v2.
> >
> > After testing v2 on qcs8300-ride-sx, BT init broke. qcs8300-ride-sx has a
> > soldered WCN6855 and no M.2 Key E connector, but the pending series [1]
> > uses of_graph_is_present() to detect whether an M.2 connector is present.
> > Since of_graph_is_present() only checks for a 'port' child node, the empty
> > anchors in monaco.dtsi caused hci_qca to incorrectly enter the M.2 pwrseq
> > path on all monaco boards.
> >
> > v3 moves the port/endpoint nodes back to monaco-evk.dts. Please review.
> >
> > [1] https://lore.kernel.org/all/20260720-monza-wireless-v5-1-69ec6743543c@oss.qualcomm.com/
>
> The series should test of_graph_get_remote_endpoint() instead
>
> Konrad
Hi Konrad,
Tested: replacing of_graph_is_present() with of_graph_get_remote_endpoint()
in hci_qca.c works correctly. The M.2 pwrseq path is only entered when a
remote-endpoint is actually populated, so boards like qcs8300-ride (soldered
WCN6855, no M.2 connector) are no longer affected.
Hi Mani, Loic,
We are adding M.2 Key E connector support for monaco-evk [2]. Konrad
suggested moving the port/endpoint anchor nodes to the SoC DTSI
(monaco.dtsi) for clean DTS layering, so that board files only need to
fill in remote-endpoint for boards that actually have an M.2 connector.
However, when we did this, BT init broke on qcs8300-ride-sx, a monaco-based
board with a soldered WCN6855 and no M.2 connector. The root cause is that
of_graph_is_present() in hci_qca.c only checks for the presence of a 'port'
child node — it returns true even when the port/endpoint anchors in the DTSI
are empty (no remote-endpoint set). As a result, hci_qca incorrectly enters
the M.2 pwrseq path on all monaco boards.
Konrad suggested using of_graph_get_remote_endpoint() instead, which only
returns non-NULL when a remote-endpoint is actually populated. I tested this
on lemans and it works correctly.
Would it be acceptable to change the M.2 detection in hci_qca.c [1] from:
if (of_graph_is_present(dev_of_node(&serdev->ctrl->dev))) {
qcadev->bt_power->pwrseq = devm_pwrseq_get(&serdev->ctrl->dev,
"uart");
if (IS_ERR(qcadev->bt_power->pwrseq))
return PTR_ERR(qcadev->bt_power->pwrseq);
break;
}
to:
{
struct device_node *ep, *remote_ep;
ep = of_graph_get_next_endpoint(
dev_of_node(&serdev->ctrl->dev), NULL);
remote_ep = ep ? of_graph_get_remote_endpoint(ep) : NULL;
of_node_put(ep);
if (remote_ep) {
of_node_put(remote_ep);
qcadev->bt_power->pwrseq = devm_pwrseq_get(
&serdev->ctrl->dev, "uart");
if (IS_ERR(qcadev->bt_power->pwrseq))
return PTR_ERR(qcadev->bt_power->pwrseq);
break;
}
}
[1] https://lore.kernel.org/all/20260720-monza-wireless-v5-1-69ec6743543c@oss.qualcomm.com/
[2] https://lore.kernel.org/all/20260819141353.96467-1-wei.deng@oss.qualcomm.com/
--
Best Regards,
Wei Deng
next prev parent reply other threads:[~2026-08-25 9:27 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-28 3:39 [PATCH 2/2] arm64: dts: qcom: monaco-evk: Describe the PCIe M.2 Key E connector Wei Deng
2026-07-28 8:11 ` Konrad Dybcio
2026-07-29 2:36 ` Wei Deng
2026-08-19 14:13 ` Wei Deng
2026-08-19 14:24 ` Konrad Dybcio
2026-08-25 9:27 ` Wei Deng [this message]
2026-09-02 13:48 ` Manivannan Sadhasivam
2026-09-21 12:38 ` Konrad Dybcio
-- strict thread matches above, loose matches on Subject: below --
2026-07-27 14:16 [PATCH 0/2] arm64: dts: qcom: Describe the PCIe M.2 Key E connector for Monaco EVK Wei Deng
2026-07-27 14:16 ` [PATCH 2/2] arm64: dts: qcom: monaco-evk: Describe the PCIe M.2 Key E connector Wei Deng
2026-07-27 14:39 ` Dmitry Baryshkov
2026-07-27 14:43 ` Konrad Dybcio
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=20260825092715.5794-1-wei.deng@oss.qualcomm.com \
--to=wei.deng@oss.qualcomm.com \
--cc=andersson@kernel.org \
--cc=cheng.jiang@oss.qualcomm.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=jinwang.li@oss.qualcomm.com \
--cc=konrad.dybcio@oss.qualcomm.com \
--cc=konradybcio@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-bluetooth@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=loic.poulain@oss.qualcomm.com \
--cc=mani@kernel.org \
--cc=manivannan.sadhasivam@oss.qualcomm.com \
--cc=mengshi.wu@oss.qualcomm.com \
--cc=quic_chezhou@quicinc.com \
--cc=robh@kernel.org \
--cc=shuai.zhang@oss.qualcomm.com \
--cc=xiuzhuo.shang@oss.qualcomm.com \
/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