Re: [PATCH v3 4/4] arm64: dts: qcom: sdm630: assign adsp_mem region to ADSP FastRPC node

From: Nickolay Goppen

Date: Thu Apr 23 2026 - 11:04:33 EST



23.04.2026 17:39, Ekansh Gupta пишет:
On 23-04-2026 19:18, Nickolay Goppen wrote:
23.04.2026 16:08, Konrad Dybcio пишет:
On 4/23/26 3:06 PM, Nickolay Goppen wrote:
23.04.2026 14:05, Konrad Dybcio пишет:
On 4/22/26 5:39 PM, Nickolay Goppen wrote:
Downstream [1] ADSP FastRPC node has the adsp_mem region assigned, so
assign it to the ADSP FastRPC node.

[1]: https://github.com/xiaomi-sdm660/android_kernel_xiaomi_sdm660/
blob/11-EAS/arch/arm/boot/dts/qcom/sdm660.dtsi#L1693

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@xxxxxxxxxxxxxxxx>
Signed-off-by: Nickolay Goppen <setotau@xxxxxxxxxxxxxx>
---
   arch/arm64/boot/dts/qcom/sdm630.dtsi | 3 +++
   1 file changed, 3 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/sdm630.dtsi b/arch/arm64/
boot/dts/qcom/sdm630.dtsi
index 36b419dea153..af2bc29ccdad 100644
--- a/arch/arm64/boot/dts/qcom/sdm630.dtsi
+++ b/arch/arm64/boot/dts/qcom/sdm630.dtsi
@@ -2458,6 +2458,9 @@ fastrpc {
                       compatible = "qcom,fastrpc";
                       qcom,glink-channels = "fastrpcglink-apps-dsp";
                       label = "adsp";
+                    memory-region = <&adsp_mem>;
+                    qcom,vmids = <QCOM_SCM_VMID_LPASS
+                              QCOM_SCM_VMID_ADSP_HEAP>;
Please double-check that, the VMID used to be different on
older SoCs
Do you know how to check that?
The least painful way is probably to add debug prints to what downstream
calls hyp_assign_phys()
I've found in drivers/soc/qcom/qdsp6v2/msm_audio_ion.c the following vmids:

VMID_HLOS= 0x3
VMID_CP_ADSP_SHARED33
This VMID looks correct.

Just had a look at the downstream fastrpc driver code in the same tree.
The fastrpc node in DT[1] is adding a "qcom,fastrpc-vmid-heap-shared"
property. For this property, the VMID is getting set as
"VMID_CP_ADSP_SHARED" in the downstream fastrpc driver[2]. The
hyp_assign is happening during daemon attach call[3] with srcVM being
"VMID_HLOS".

Thanks Konrad for highlighting this difference in VMID.

[1]
https://github.com/xiaomi-sdm660/android_kernel_xiaomi_sdm660/blob/11-EAS/arch/arm/boot/dts/qcom/sdm660.dtsi#L1699
[2]
https://github.com/xiaomi-sdm660/android_kernel_xiaomi_sdm660/blob/11-EAS/drivers/char/adsprpc.c#L3602
[3]
https://github.com/xiaomi-sdm660/android_kernel_xiaomi_sdm660/blob/11-EAS/drivers/char/adsprpc.c#L1999
Didn't find the "VMID_CP_ADSP_SHARED 0x33" in the upstream bindings. Does it need to be added to the bindings?
Konrad

--
Best regards,
Nickolay