[PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP

Nícolas F. R. A. Prado posted 4 patches 9 months ago
There is a newer version of this series
[PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP
Posted by Nícolas F. R. A. Prado 9 months ago
The SCP present on MT8188 does not have an L1TCM memory region, but the
binding incorrectly requires one for the dual-core description of the
MT8188 SCP. Remove that requirement. Also update the minimum number of
reg and reg-names to 1, since as this is a multi-core SCP with no
L1TCM memory, only the CFG memory region is present in the parent node.

Fixes: 91e0d560b9fd ("dt-bindings: remoteproc: mediatek: Support MT8188 dual-core SCP")
Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
---
 .../devicetree/bindings/remoteproc/mtk,scp.yaml       | 19 ++++++++++++++++---
 1 file changed, 16 insertions(+), 3 deletions(-)

diff --git a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
index ee33c233e44f3d51f0851b35697a24208c87f68a..04348cfcb0424dc78ff1ddd77665285a052925e9 100644
--- a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
+++ b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
@@ -28,11 +28,11 @@ properties:
     description:
       Should contain the address ranges for memory regions SRAM, CFG, and,
       on some platforms, L1TCM.
-    minItems: 2
+    minItems: 1
     maxItems: 3
 
   reg-names:
-    minItems: 2
+    minItems: 1
     maxItems: 3
 
   clocks:
@@ -171,6 +171,7 @@ allOf:
     then:
       properties:
         reg:
+          minItems: 2
           maxItems: 2
         reg-names:
           items:
@@ -196,16 +197,28 @@ allOf:
       properties:
         compatible:
           enum:
-            - mediatek,mt8188-scp-dual
             - mediatek,mt8195-scp-dual
     then:
       properties:
         reg:
+          minItems: 2
           maxItems: 2
         reg-names:
           items:
             - const: cfg
             - const: l1tcm
+  - if:
+      properties:
+        compatible:
+          enum:
+            - mediatek,mt8188-scp-dual
+    then:
+      properties:
+        reg:
+          maxItems: 1
+        reg-names:
+          items:
+            - const: cfg
 
 additionalProperties: false
 

-- 
2.49.0

Re: [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP
Posted by AngeloGioacchino Del Regno 9 months ago
Il 18/03/25 23:22, Nícolas F. R. A. Prado ha scritto:
> The SCP present on MT8188 does not have an L1TCM memory region, but the
> binding incorrectly requires one for the dual-core description of the
> MT8188 SCP. Remove that requirement. Also update the minimum number of
> reg and reg-names to 1, since as this is a multi-core SCP with no
> L1TCM memory, only the CFG memory region is present in the parent node.
> 
> Fixes: 91e0d560b9fd ("dt-bindings: remoteproc: mediatek: Support MT8188 dual-core SCP")
> Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>

As far as I know, the L1TCM is present on MT8188, and it's at 0x1070000 len 0x8000
exactly like MT8195.

Moudy, are you able to please confirm or deny that?

Cheers,
Angelo


Re: [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP
Posted by Moudy Ho (何宗原) 9 months ago
On Wed, 2025-03-19 at 10:34 +0100, AngeloGioacchino Del Regno wrote:
> 
> External email : Please do not click links or open attachments until
> you have verified the sender or the content.
> 
> 
> Il 18/03/25 23:22, Nícolas F. R. A. Prado ha scritto:
> > The SCP present on MT8188 does not have an L1TCM memory region, but
> > the
> > binding incorrectly requires one for the dual-core description of
> > the
> > MT8188 SCP. Remove that requirement. Also update the minimum number
> > of
> > reg and reg-names to 1, since as this is a multi-core SCP with no
> > L1TCM memory, only the CFG memory region is present in the parent
> > node.
> > 
> > Fixes: 91e0d560b9fd ("dt-bindings: remoteproc: mediatek: Support
> > MT8188 dual-core SCP")
> > Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
> 
> As far as I know, the L1TCM is present on MT8188, and it's at
> 0x1070000 len 0x8000
> exactly like MT8195.
> 
> Moudy, are you able to please confirm or deny that?
> 
> Cheers,
> Angelo
> 
> 

Hi Angelo,

Unfortunately, during the transition from MT8195 to MT8188, the SCP
removed the L1TCM, retaining only the SRAM and config register.
For detailed hardware changes, you can refer to Tinghan's previous
description at the following link.

ref:
https://lore.kernel.org/all/20220715051821.30707-3-tinghan.shen@mediatek.com/

Sincerely,
Moudy Ho

Re: [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP
Posted by AngeloGioacchino Del Regno 9 months ago
Il 20/03/25 02:28, Moudy Ho (何宗原) ha scritto:
> On Wed, 2025-03-19 at 10:34 +0100, AngeloGioacchino Del Regno wrote:
>>
>> External email : Please do not click links or open attachments until
>> you have verified the sender or the content.
>>
>>
>> Il 18/03/25 23:22, Nícolas F. R. A. Prado ha scritto:
>>> The SCP present on MT8188 does not have an L1TCM memory region, but
>>> the
>>> binding incorrectly requires one for the dual-core description of
>>> the
>>> MT8188 SCP. Remove that requirement. Also update the minimum number
>>> of
>>> reg and reg-names to 1, since as this is a multi-core SCP with no
>>> L1TCM memory, only the CFG memory region is present in the parent
>>> node.
>>>
>>> Fixes: 91e0d560b9fd ("dt-bindings: remoteproc: mediatek: Support
>>> MT8188 dual-core SCP")
>>> Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
>>
>> As far as I know, the L1TCM is present on MT8188, and it's at
>> 0x1070000 len 0x8000
>> exactly like MT8195.
>>
>> Moudy, are you able to please confirm or deny that?
>>
>> Cheers,
>> Angelo
>>
>>
> 
> Hi Angelo,
> 
> Unfortunately, during the transition from MT8195 to MT8188, the SCP
> removed the L1TCM, retaining only the SRAM and config register.
> For detailed hardware changes, you can refer to Tinghan's previous
> description at the following link.
> 
> ref:
> https://lore.kernel.org/all/20220715051821.30707-3-tinghan.shen@mediatek.com/
> 
Thanks Moudy!

Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Re: [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP
Posted by Krzysztof Kozlowski 9 months ago
On 18/03/2025 23:22, Nícolas F. R. A. Prado wrote:
> The SCP present on MT8188 does not have an L1TCM memory region, but the
> binding incorrectly requires one for the dual-core description of the
> MT8188 SCP. Remove that requirement. Also update the minimum number of
> reg and reg-names to 1, since as this is a multi-core SCP with no
> L1TCM memory, only the CFG memory region is present in the parent node.
> 
> Fixes: 91e0d560b9fd ("dt-bindings: remoteproc: mediatek: Support MT8188 dual-core SCP")
> Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

Best regards,
Krzysztof