* [PATCH 1/4] dt-bindings: remoteproc: mediatek: Add missing minItems for 8192/8195
2025-03-18 22:22 [PATCH 0/4] Describe MT8188's SCP as dual-core Nícolas F. R. A. Prado
@ 2025-03-18 22:22 ` Nícolas F. R. A. Prado
2025-03-19 7:16 ` Krzysztof Kozlowski
2025-03-18 22:22 ` [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP Nícolas F. R. A. Prado
` (2 subsequent siblings)
3 siblings, 1 reply; 13+ messages in thread
From: Nícolas F. R. A. Prado @ 2025-03-18 22:22 UTC (permalink / raw)
To: Bjorn Andersson, Mathieu Poirier, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
AngeloGioacchino Del Regno, Tinghan Shen, Olivia Wen
Cc: kernel, linux-remoteproc, devicetree, linux-kernel,
linux-arm-kernel, linux-mediatek, Krzysztof Kozlowski,
Nícolas F. R. A. Prado
Both MT8192 and MT8195 have an L1TCM memory, so it should be described
in reg, and therefore reg's minItems should be 3, as is already implicit
by reg-names. Override minItems to 3 for MT8192 and MT8195.
Fixes: 6b55b1e2fd7f ("dt-bindings: remoteproc: mediatek: Support MT8195 dual-core SCP")
Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
---
Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
index adc6b3f36fde49eb3fa7ed3f08b0fa9e7f331162..ee33c233e44f3d51f0851b35697a24208c87f68a 100644
--- a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
+++ b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
@@ -185,6 +185,7 @@ allOf:
then:
properties:
reg:
+ minItems: 3
maxItems: 3
reg-names:
items:
--
2.49.0
^ permalink raw reply related [flat|nested] 13+ messages in thread* Re: [PATCH 1/4] dt-bindings: remoteproc: mediatek: Add missing minItems for 8192/8195
2025-03-18 22:22 ` [PATCH 1/4] dt-bindings: remoteproc: mediatek: Add missing minItems for 8192/8195 Nícolas F. R. A. Prado
@ 2025-03-19 7:16 ` Krzysztof Kozlowski
2025-03-19 14:25 ` Nícolas F. R. A. Prado
0 siblings, 1 reply; 13+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-19 7:16 UTC (permalink / raw)
To: Nícolas F. R. A. Prado, Bjorn Andersson, Mathieu Poirier,
Rob Herring, Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
AngeloGioacchino Del Regno, Tinghan Shen, Olivia Wen
Cc: kernel, linux-remoteproc, devicetree, linux-kernel,
linux-arm-kernel, linux-mediatek
On 18/03/2025 23:22, Nícolas F. R. A. Prado wrote:
> Both MT8192 and MT8195 have an L1TCM memory, so it should be described
> in reg, and therefore reg's minItems should be 3, as is already implicit
> by reg-names. Override minItems to 3 for MT8192 and MT8195.
I think that was the original intention already, because reg-names are
expecting min 3 items. Basically you just correct the missing lower
constraint.
>
> Fixes: 6b55b1e2fd7f ("dt-bindings: remoteproc: mediatek: Support MT8195 dual-core SCP")
> Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
> ---
> Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
> index adc6b3f36fde49eb3fa7ed3f08b0fa9e7f331162..ee33c233e44f3d51f0851b35697a24208c87f68a 100644
> --- a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
> +++ b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
> @@ -185,6 +185,7 @@ allOf:
> then:
> properties:
> reg:
> + minItems: 3
> maxItems: 3
maxItems can be dropped.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 13+ messages in thread* Re: [PATCH 1/4] dt-bindings: remoteproc: mediatek: Add missing minItems for 8192/8195
2025-03-19 7:16 ` Krzysztof Kozlowski
@ 2025-03-19 14:25 ` Nícolas F. R. A. Prado
2025-04-18 8:43 ` AngeloGioacchino Del Regno
0 siblings, 1 reply; 13+ messages in thread
From: Nícolas F. R. A. Prado @ 2025-03-19 14:25 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Bjorn Andersson, Mathieu Poirier, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
AngeloGioacchino Del Regno, Tinghan Shen, Olivia Wen, kernel,
linux-remoteproc, devicetree, linux-kernel, linux-arm-kernel,
linux-mediatek
On Wed, Mar 19, 2025 at 08:16:37AM +0100, Krzysztof Kozlowski wrote:
> On 18/03/2025 23:22, Nícolas F. R. A. Prado wrote:
> > Both MT8192 and MT8195 have an L1TCM memory, so it should be described
> > in reg, and therefore reg's minItems should be 3, as is already implicit
> > by reg-names. Override minItems to 3 for MT8192 and MT8195.
>
> I think that was the original intention already, because reg-names are
> expecting min 3 items. Basically you just correct the missing lower
> constraint.
Yes, exactly, that's what I meant by "is already implicit by reg-names".
>
> >
> > Fixes: 6b55b1e2fd7f ("dt-bindings: remoteproc: mediatek: Support MT8195 dual-core SCP")
> > Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
> > ---
> > Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
> > index adc6b3f36fde49eb3fa7ed3f08b0fa9e7f331162..ee33c233e44f3d51f0851b35697a24208c87f68a 100644
> > --- a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
> > +++ b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
> > @@ -185,6 +185,7 @@ allOf:
> > then:
> > properties:
> > reg:
> > + minItems: 3
> > maxItems: 3
>
> maxItems can be dropped.
Sure, I can send a patch for that in the next version.
Thanks,
Nícolas
^ permalink raw reply [flat|nested] 13+ messages in thread* Re: [PATCH 1/4] dt-bindings: remoteproc: mediatek: Add missing minItems for 8192/8195
2025-03-19 14:25 ` Nícolas F. R. A. Prado
@ 2025-04-18 8:43 ` AngeloGioacchino Del Regno
0 siblings, 0 replies; 13+ messages in thread
From: AngeloGioacchino Del Regno @ 2025-04-18 8:43 UTC (permalink / raw)
To: Nícolas F. R. A. Prado, Krzysztof Kozlowski
Cc: Bjorn Andersson, Mathieu Poirier, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Matthias Brugger, Tinghan Shen,
Olivia Wen, kernel, linux-remoteproc, devicetree, linux-kernel,
linux-arm-kernel, linux-mediatek
Il 19/03/25 15:25, Nícolas F. R. A. Prado ha scritto:
> On Wed, Mar 19, 2025 at 08:16:37AM +0100, Krzysztof Kozlowski wrote:
>> On 18/03/2025 23:22, Nícolas F. R. A. Prado wrote:
>>> Both MT8192 and MT8195 have an L1TCM memory, so it should be described
>>> in reg, and therefore reg's minItems should be 3, as is already implicit
>>> by reg-names. Override minItems to 3 for MT8192 and MT8195.
>>
>> I think that was the original intention already, because reg-names are
>> expecting min 3 items. Basically you just correct the missing lower
>> constraint.
>
> Yes, exactly, that's what I meant by "is already implicit by reg-names".
>
Nicolas, any way you can respin this patch so that we can get SCP for MT8188
in this merge window, please?
If you cannot do that, I can respin it on my own, no problem.
Thanks,
Angelo
>>
>>>
>>> Fixes: 6b55b1e2fd7f ("dt-bindings: remoteproc: mediatek: Support MT8195 dual-core SCP")
>>> Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
>>> ---
>>> Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml | 1 +
>>> 1 file changed, 1 insertion(+)
>>>
>>> diff --git a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
>>> index adc6b3f36fde49eb3fa7ed3f08b0fa9e7f331162..ee33c233e44f3d51f0851b35697a24208c87f68a 100644
>>> --- a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
>>> +++ b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
>>> @@ -185,6 +185,7 @@ allOf:
>>> then:
>>> properties:
>>> reg:
>>> + minItems: 3
>>> maxItems: 3
>>
>> maxItems can be dropped.
>
> Sure, I can send a patch for that in the next version.
>
> Thanks,
> Nícolas
^ permalink raw reply [flat|nested] 13+ messages in thread
* [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP
2025-03-18 22:22 [PATCH 0/4] Describe MT8188's SCP as dual-core Nícolas F. R. A. Prado
2025-03-18 22:22 ` [PATCH 1/4] dt-bindings: remoteproc: mediatek: Add missing minItems for 8192/8195 Nícolas F. R. A. Prado
@ 2025-03-18 22:22 ` Nícolas F. R. A. Prado
2025-03-19 7:18 ` Krzysztof Kozlowski
2025-03-19 9:34 ` AngeloGioacchino Del Regno
2025-03-18 22:22 ` [PATCH 3/4] arm64: dts: mediatek: mt8188: Describe SCP as a cluster with two cores Nícolas F. R. A. Prado
2025-03-18 22:22 ` [PATCH 4/4] arm64: dts: mediatek: mt8390-genio-common: Add firmware-name for scp0 Nícolas F. R. A. Prado
3 siblings, 2 replies; 13+ messages in thread
From: Nícolas F. R. A. Prado @ 2025-03-18 22:22 UTC (permalink / raw)
To: Bjorn Andersson, Mathieu Poirier, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
AngeloGioacchino Del Regno, Tinghan Shen, Olivia Wen
Cc: kernel, linux-remoteproc, devicetree, linux-kernel,
linux-arm-kernel, linux-mediatek, Krzysztof Kozlowski,
Nícolas F. R. A. Prado
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
^ permalink raw reply related [flat|nested] 13+ messages in thread* Re: [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP
2025-03-18 22:22 ` [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP Nícolas F. R. A. Prado
@ 2025-03-19 7:18 ` Krzysztof Kozlowski
2025-03-19 9:34 ` AngeloGioacchino Del Regno
1 sibling, 0 replies; 13+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-19 7:18 UTC (permalink / raw)
To: Nícolas F. R. A. Prado, Bjorn Andersson, Mathieu Poirier,
Rob Herring, Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
AngeloGioacchino Del Regno, Tinghan Shen, Olivia Wen
Cc: kernel, linux-remoteproc, devicetree, linux-kernel,
linux-arm-kernel, linux-mediatek
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
^ permalink raw reply [flat|nested] 13+ messages in thread* Re: [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP
2025-03-18 22:22 ` [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP Nícolas F. R. A. Prado
2025-03-19 7:18 ` Krzysztof Kozlowski
@ 2025-03-19 9:34 ` AngeloGioacchino Del Regno
2025-03-20 1:28 ` Moudy Ho (何宗原)
1 sibling, 1 reply; 13+ messages in thread
From: AngeloGioacchino Del Regno @ 2025-03-19 9:34 UTC (permalink / raw)
To: Nícolas F. R. A. Prado, Bjorn Andersson, Mathieu Poirier,
Rob Herring, Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
Tinghan Shen, Olivia Wen, Moudy Ho
Cc: kernel, linux-remoteproc, devicetree, linux-kernel,
linux-arm-kernel, linux-mediatek, Krzysztof Kozlowski
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
^ permalink raw reply [flat|nested] 13+ messages in thread* Re: [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP
2025-03-19 9:34 ` AngeloGioacchino Del Regno
@ 2025-03-20 1:28 ` Moudy Ho (何宗原)
2025-03-20 10:33 ` AngeloGioacchino Del Regno
0 siblings, 1 reply; 13+ messages in thread
From: Moudy Ho (何宗原) @ 2025-03-20 1:28 UTC (permalink / raw)
To: AngeloGioacchino Del Regno, robh@kernel.org, andersson@kernel.org,
krzk+dt@kernel.org, TingHan Shen (沈廷翰),
mathieu.poirier@linaro.org, matthias.bgg@gmail.com, Nicolas Prado,
Olivia Wen (温倩苓), conor+dt@kernel.org
Cc: linux-remoteproc@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-mediatek@lists.infradead.org, devicetree@vger.kernel.org,
kernel@collabora.com, linux-kernel@vger.kernel.org,
krzysztof.kozlowski@linaro.org
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
^ permalink raw reply [flat|nested] 13+ messages in thread* Re: [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP
2025-03-20 1:28 ` Moudy Ho (何宗原)
@ 2025-03-20 10:33 ` AngeloGioacchino Del Regno
0 siblings, 0 replies; 13+ messages in thread
From: AngeloGioacchino Del Regno @ 2025-03-20 10:33 UTC (permalink / raw)
To: Moudy Ho (何宗原), robh@kernel.org,
andersson@kernel.org, krzk+dt@kernel.org,
TingHan Shen (沈廷翰),
mathieu.poirier@linaro.org, matthias.bgg@gmail.com, Nicolas Prado,
Olivia Wen (温倩苓), conor+dt@kernel.org
Cc: linux-remoteproc@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-mediatek@lists.infradead.org, devicetree@vger.kernel.org,
kernel@collabora.com, linux-kernel@vger.kernel.org,
krzysztof.kozlowski@linaro.org
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>
^ permalink raw reply [flat|nested] 13+ messages in thread
* [PATCH 3/4] arm64: dts: mediatek: mt8188: Describe SCP as a cluster with two cores
2025-03-18 22:22 [PATCH 0/4] Describe MT8188's SCP as dual-core Nícolas F. R. A. Prado
2025-03-18 22:22 ` [PATCH 1/4] dt-bindings: remoteproc: mediatek: Add missing minItems for 8192/8195 Nícolas F. R. A. Prado
2025-03-18 22:22 ` [PATCH 2/4] dt-bindings: remoteproc: mediatek: Remove l1tcm for dual-core MT8188 SCP Nícolas F. R. A. Prado
@ 2025-03-18 22:22 ` Nícolas F. R. A. Prado
2025-03-18 22:22 ` [PATCH 4/4] arm64: dts: mediatek: mt8390-genio-common: Add firmware-name for scp0 Nícolas F. R. A. Prado
3 siblings, 0 replies; 13+ messages in thread
From: Nícolas F. R. A. Prado @ 2025-03-18 22:22 UTC (permalink / raw)
To: Bjorn Andersson, Mathieu Poirier, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
AngeloGioacchino Del Regno, Tinghan Shen, Olivia Wen
Cc: kernel, linux-remoteproc, devicetree, linux-kernel,
linux-arm-kernel, linux-mediatek, Krzysztof Kozlowski,
Nícolas F. R. A. Prado, Jason Chen
The SCP is currently described in the Devicetree as a single-core
processor, but really it is a cluster with two cores. Describe the full
cluster but enable only core0 on the current mt8188 platforms since
that's the only one usable with the upstream firmware.
Co-developed-by: Tinghan Shen <tinghan.shen@mediatek.com>
Signed-off-by: Tinghan Shen <tinghan.shen@mediatek.com>
Co-developed-by: Jason Chen <jason-ch.chen@mediatek.corp-partner.google.com>
Signed-off-by: Jason Chen <jason-ch.chen@mediatek.corp-partner.google.com>
Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
---
arch/arm64/boot/dts/mediatek/mt8188-evb.dts | 6 +++-
arch/arm64/boot/dts/mediatek/mt8188.dtsi | 36 ++++++++++++++++------
.../boot/dts/mediatek/mt8390-genio-common.dtsi | 6 +++-
3 files changed, 37 insertions(+), 11 deletions(-)
diff --git a/arch/arm64/boot/dts/mediatek/mt8188-evb.dts b/arch/arm64/boot/dts/mediatek/mt8188-evb.dts
index f89835ac36f36f86e2054ae0c332172be97b049a..f4c207d65b877e1eefaa26540446c3c06369ca21 100644
--- a/arch/arm64/boot/dts/mediatek/mt8188-evb.dts
+++ b/arch/arm64/boot/dts/mediatek/mt8188-evb.dts
@@ -331,7 +331,11 @@ &pmic {
interrupts-extended = <&pio 222 IRQ_TYPE_LEVEL_HIGH>;
};
-&scp {
+&scp_cluster {
+ status = "okay";
+};
+
+&scp_c0 {
memory-region = <&scp_mem_reserved>;
status = "okay";
};
diff --git a/arch/arm64/boot/dts/mediatek/mt8188.dtsi b/arch/arm64/boot/dts/mediatek/mt8188.dtsi
index 4437b1820f2685281c3a373bf626f72b53503e62..bea3cee9b8e8f0dc656edd85e63f4f6f6645607f 100644
--- a/arch/arm64/boot/dts/mediatek/mt8188.dtsi
+++ b/arch/arm64/boot/dts/mediatek/mt8188.dtsi
@@ -1382,12 +1382,30 @@ gce1: mailbox@10330000 {
clocks = <&infracfg_ao CLK_INFRA_AO_GCE2>;
};
- scp: scp@10500000 {
- compatible = "mediatek,mt8188-scp";
- reg = <0 0x10500000 0 0x100000>,
- <0 0x10720000 0 0xe0000>;
- reg-names = "sram", "cfg";
- interrupts = <GIC_SPI 462 IRQ_TYPE_LEVEL_HIGH 0>;
+ scp_cluster: scp@10720000 {
+ compatible = "mediatek,mt8188-scp-dual";
+ reg = <0 0x10720000 0 0xe0000>;
+ reg-names = "cfg";
+ #address-cells = <1>;
+ #size-cells = <1>;
+ ranges = <0 0 0x10500000 0x100000>;
+ status = "disabled";
+
+ scp_c0: scp@0 {
+ compatible = "mediatek,scp-core";
+ reg = <0x0 0xd0000>;
+ reg-names = "sram";
+ interrupts = <GIC_SPI 462 IRQ_TYPE_LEVEL_HIGH 0>;
+ status = "disabled";
+ };
+
+ scp_c1: scp@d0000 {
+ compatible = "mediatek,scp-core";
+ reg = <0xd0000 0x2f000>;
+ reg-names = "sram";
+ interrupts = <GIC_SPI 463 IRQ_TYPE_LEVEL_HIGH 0>;
+ status = "disabled";
+ };
};
afe: audio-controller@10b10000 {
@@ -2249,7 +2267,7 @@ dma-controller@14001000 {
mediatek,gce-client-reg = <&gce1 SUBSYS_1400XXXX 0x1000 0x1000>;
mediatek,gce-events = <CMDQ_EVENT_VPP0_MDP_RDMA_SOF>,
<CMDQ_EVENT_VPP0_MDP_RDMA_FRAME_DONE>;
- mediatek,scp = <&scp>;
+ mediatek,scp = <&scp_c0>;
};
display@14002000 {
@@ -2704,7 +2722,7 @@ video_decoder: video-decoder@18000000 {
iommus = <&vpp_iommu M4U_PORT_L23_HW_VDEC_UFO_ENC_EXT>;
#address-cells = <2>;
#size-cells = <2>;
- mediatek,scp = <&scp>;
+ mediatek,scp = <&scp_c0>;
video-codec@10000 {
compatible = "mediatek,mtk-vcodec-lat";
@@ -2828,7 +2846,7 @@ video_encoder: video-encoder@1a020000 {
<&vdo_iommu M4U_PORT_L19_VENC_SUB_W_LUMA>,
<&vdo_iommu M4U_PORT_L19_VENC_SUB_R_LUMA>;
power-domains = <&spm MT8188_POWER_DOMAIN_VENC>;
- mediatek,scp = <&scp>;
+ mediatek,scp = <&scp_c0>;
};
jpeg_encoder: jpeg-encoder@1a030000 {
diff --git a/arch/arm64/boot/dts/mediatek/mt8390-genio-common.dtsi b/arch/arm64/boot/dts/mediatek/mt8390-genio-common.dtsi
index 60139e6dffd8e0e326690d922f3360d829ed026b..65952bcf5d03e3b22984dd3e997e7107e74dac72 100644
--- a/arch/arm64/boot/dts/mediatek/mt8390-genio-common.dtsi
+++ b/arch/arm64/boot/dts/mediatek/mt8390-genio-common.dtsi
@@ -1055,7 +1055,11 @@ power-key {
};
};
-&scp {
+&scp_cluster {
+ status = "okay";
+};
+
+&scp_c0 {
memory-region = <&scp_mem>;
status = "okay";
};
--
2.49.0
^ permalink raw reply related [flat|nested] 13+ messages in thread* [PATCH 4/4] arm64: dts: mediatek: mt8390-genio-common: Add firmware-name for scp0
2025-03-18 22:22 [PATCH 0/4] Describe MT8188's SCP as dual-core Nícolas F. R. A. Prado
` (2 preceding siblings ...)
2025-03-18 22:22 ` [PATCH 3/4] arm64: dts: mediatek: mt8188: Describe SCP as a cluster with two cores Nícolas F. R. A. Prado
@ 2025-03-18 22:22 ` Nícolas F. R. A. Prado
2025-03-19 9:34 ` AngeloGioacchino Del Regno
3 siblings, 1 reply; 13+ messages in thread
From: Nícolas F. R. A. Prado @ 2025-03-18 22:22 UTC (permalink / raw)
To: Bjorn Andersson, Mathieu Poirier, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
AngeloGioacchino Del Regno, Tinghan Shen, Olivia Wen
Cc: kernel, linux-remoteproc, devicetree, linux-kernel,
linux-arm-kernel, linux-mediatek, Krzysztof Kozlowski,
Nícolas F. R. A. Prado
Add the firmware-name property for SCP core0 so the firmware can be
loaded from its canonical location in the linux-firmware repository.
Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
---
arch/arm64/boot/dts/mediatek/mt8390-genio-common.dtsi | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch/arm64/boot/dts/mediatek/mt8390-genio-common.dtsi b/arch/arm64/boot/dts/mediatek/mt8390-genio-common.dtsi
index 65952bcf5d03e3b22984dd3e997e7107e74dac72..53951817df468ee27d20db1f1028c21a1832b880 100644
--- a/arch/arm64/boot/dts/mediatek/mt8390-genio-common.dtsi
+++ b/arch/arm64/boot/dts/mediatek/mt8390-genio-common.dtsi
@@ -1060,6 +1060,7 @@ &scp_cluster {
};
&scp_c0 {
+ firmware-name = "mediatek/mt8188/scp.img";
memory-region = <&scp_mem>;
status = "okay";
};
--
2.49.0
^ permalink raw reply related [flat|nested] 13+ messages in thread* Re: [PATCH 4/4] arm64: dts: mediatek: mt8390-genio-common: Add firmware-name for scp0
2025-03-18 22:22 ` [PATCH 4/4] arm64: dts: mediatek: mt8390-genio-common: Add firmware-name for scp0 Nícolas F. R. A. Prado
@ 2025-03-19 9:34 ` AngeloGioacchino Del Regno
0 siblings, 0 replies; 13+ messages in thread
From: AngeloGioacchino Del Regno @ 2025-03-19 9:34 UTC (permalink / raw)
To: Nícolas F. R. A. Prado, Bjorn Andersson, Mathieu Poirier,
Rob Herring, Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
Tinghan Shen, Olivia Wen
Cc: kernel, linux-remoteproc, devicetree, linux-kernel,
linux-arm-kernel, linux-mediatek, Krzysztof Kozlowski
Il 18/03/25 23:22, Nícolas F. R. A. Prado ha scritto:
> Add the firmware-name property for SCP core0 so the firmware can be
> loaded from its canonical location in the linux-firmware repository.
>
> Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
^ permalink raw reply [flat|nested] 13+ messages in thread