[PATCH 1/2] dt-bindings: sound: qcom,q6apm-dai: add memory-region property
From: Ajay Kumar Nandam
Date: Thu Jun 18 2026 - 07:36:15 EST
Document the new memory-region property that allows one or more
reserved-memory carveout regions to be SCM-assigned to the VMIDs
listed in qcom,vmid.
- Add memory-region as an optional phandle-array (1-8 entries).
Each entry must point to a shared-dma-pool, no-map reserved-memory
node. Index 0 is the control-path buffer; subsequent entries are
data-path buffers.
- Enforce via dependentRequired that memory-region is only valid
when qcom,vmid is also present.
- Expand qcom,vmid description to mention carveout regions and the
qcom_scm_is_available() probe-defer requirement.
- Add a second example showing both properties in use with two
carveout regions and two destination VMIDs.
Signed-off-by: Ajay Kumar Nandam <ajay.nandam@xxxxxxxxxxxxxxxx>
---
.../bindings/sound/qcom,q6apm-dai.yaml | 38 +++++++++++++++++--
1 file changed, 35 insertions(+), 3 deletions(-)
diff --git a/Documentation/devicetree/bindings/sound/qcom,q6apm-dai.yaml b/Documentation/devicetree/bindings/sound/qcom,q6apm-dai.yaml
index b767625985a7..601055182da6 100644
--- a/Documentation/devicetree/bindings/sound/qcom,q6apm-dai.yaml
+++ b/Documentation/devicetree/bindings/sound/qcom,q6apm-dai.yaml
@@ -10,7 +10,11 @@ maintainers:
- Srinivas Kandagatla <srinivas.kandagatla@xxxxxxxxxx>
description: |
- This binding describes the Qualcomm APM DAIs in DSP
+ This binding describes the Qualcomm APM DAIs in DSP.
+ When qcom,vmid is present, the driver performs SCM memory
+ assignment for PCM DMA buffers and any reserved-memory regions
+ listed in memory-region, granting the specified VMIDs RW access
+ while retaining HLOS as a co-owner.
properties:
compatible:
@@ -20,9 +24,24 @@ properties:
minItems: 1
maxItems: 2
+ memory-region:
+ description:
+ List of phandles to reserved-memory regions (shared-dma-pool,
+ no-map) that must be SCM-assigned to the VMIDs in qcom,vmid.
+ The first entry is the control-path buffer; subsequent entries
+ are data-path buffers. Only meaningful when qcom,vmid is present.
+ $ref: /schemas/types.yaml#/definitions/phandle-array
+ items:
+ maxItems: 1
+ minItems: 1
+ maxItems: 8
+
qcom,vmid:
- description: Optional list of destination VMIDs to share PCM DMA buffers with.
- HLOS retains RW access as source owner and must not be listed.
+ description:
+ Optional list of destination VMIDs to grant RW access to PCM DMA
+ buffers and any memory-region carveouts. HLOS retains RW access
+ as source owner and must not be listed. When present,
+ qcom_scm_is_available() must return true at probe time.
$ref: /schemas/types.yaml#/definitions/uint32-array
items:
minimum: 1
@@ -34,6 +53,10 @@ required:
- compatible
- iommus
+dependentRequired:
+ memory-region:
+ - qcom,vmid
+
additionalProperties: false
examples:
@@ -42,3 +65,12 @@ examples:
compatible = "qcom,q6apm-dais";
iommus = <&apps_smmu 0x1801 0x0>;
};
+ - |
+ #include <dt-bindings/firmware/qcom,scm.h>
+ dais {
+ compatible = "qcom,q6apm-dais";
+ iommus = <&apps_smmu 0x0c01 0x0>;
+ /* index 0: control path, index 1: data path */
+ memory-region = <&audio_heap_mem &audio_mdsp_carveout_mem>;
+ qcom,vmid = <QCOM_SCM_VMID_MSS_MSA QCOM_SCM_VMID_LPASS>;
+ };
--
2.34.1