soc: qcom: apr: Don't use reg for domain id
Subsystems (4)
PATCH v2 1/1 soc: qcom: apr: Don't use reg for domain id
The reg property represents the address and size on the bus that a device lives, but for APR the parent is a rpmsg bus, which does not have numerical addresses. Simply defining #address/#size-cells to 1 and 0, respectively, to silence the compiler is not an appropriate solution.
Replace the use of "reg" with an APR specific property.
---
Changes since v1:
- Fixed example to match change
Documentation/devicetree/bindings/soc/qcom/qcom,apr.txt | 6 +++--- drivers/soc/qcom/apr.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-)
Documentation/devicetree/bindings/soc/qcom/qcom,apr.txt +3 -3
@@ -9,7 +9,7 @@ used for audio/voice services on the QDSP. Value type: <stringlist> Definition: must be "qcom,apr-v<VERSION-NUMBER>", example "qcom,apr-v2" -- reg +- qcom,apr-domain Usage: required Value type: <u32> Definition: Destination processor ID.
@@ -49,9 +49,9 @@ by the individual bindings for the specific service The following example represents a QDSP based sound card on a MSM8996 device which uses apr as communication between Apps and QDSP. - apr@4 { + apr { compatible = "qcom,apr-v2"; - reg = <APR_DOMAIN_ADSP>; + qcom,apr-domain = <APR_DOMAIN_ADSP>; q6core@3 { compatible = "qcom,q6core";
drivers/soc/qcom/apr.c +1 -1
@@ -276,7 +276,7 @@ static int apr_probe(struct rpmsg_device *rpdev)if (!apr)return -ENOMEM ; - ret =of_property_read_u32 (dev->of_node,"reg" , &apr->dest_domain_id); + ret =of_property_read_u32 (dev->of_node,"qcom,apr-domain" , &apr->dest_domain_id);if (ret) {dev_err (dev,"APR Domain ID not specified in DT\n" );return ret;
Signature · 1 line
2.18.0
Quoted 9 lines · Bjorn Andersson
The reg property represents the address and size on the bus that a device lives, but for APR the parent is a rpmsg bus, which does not have numerical addresses. Simply defining #address/#size-cells to 1 and 0, respectively, to silence the compiler is not an appropriate solution.
Replace the use of "reg" with an APR specific property.
Reviewed-by Srinivas Kandagatla <[email protected]>Signed-off-by Bjorn Andersson <[email protected]>
Quoted 9 lines
---
Changes since v1:
- Fixed example to match changeDocumentation/devicetree/bindings/soc/qcom/qcom,apr.txt | 6 +++--- drivers/soc/qcom/apr.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-)
Quoted 15 lines · Rob Herring
Quoted 14 lines · Bjorn Andersson
The reg property represents the address and size on the bus that a device lives, but for APR the parent is a rpmsg bus, which does not have numerical addresses. Simply defining #address/#size-cells to 1 and 0, respectively, to silence the compiler is not an appropriate solution.
Replace the use of "reg" with an APR specific property.
Reviewed-by Srinivas Kandagatla <[email protected]>Signed-off-by Bjorn Andersson <[email protected]>---
Changes since v1:
- Fixed example to match change
Quoted 6 lines
Quoted 4 lines
Documentation/devicetree/bindings/soc/qcom/qcom,apr.txt | 6 +++--- drivers/soc/qcom/apr.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-)Reviewed-by Rob Herring <[email protected]>
Thanks Rob, patch applied.
Regards,
Bjorn