Skip to contentSkip to conversation

arch: arm: mach-k3: Delete tifs node in DT fixup

PATCH Superseded Udit Kumar 4 participants 16 messages Apr 19, 2023 – May 3, 2023

Subsystems (2)
lore
Share & tools
lore

Udit Kumar

author
#0 lore raw

PATCH 1/1 arch: arm: mach-k3: Delete tifs node in DT fixup

This patch deletes tifs DT node as part of fixup.

TISCI API reported msmc_size, does not include 64KB reserved size for tifs aka MSMC comms memory.

As part of fixup, original code uses TISCI API reported msmc_size as size for sram DT node.

tifs node is similar to l3-cache, which should hold address above msms_size, and should be deleted before passing control to OS.

Documentation
https://software-dl.ti.com/tisci/esd/latest/2_tisci_msgs/general/core.html?highlight=msmc#tisci-msg-query-msmc

---
 arch/arm/mach-k3/common.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
arch/arm/mach-k3/common.c +3 -1
index a2adb791f6..4651744821 100644
@@ -349,9 +349,11 @@ int fdt_fixup_msmc_ram(void *blob, char *parent_path, char *node_name)
 		size = fdt_read_number(sub_reg, 1);
 		debug("%s: subnode = %d, addr = 0x%x. size = 0x%x\n", __func__,
 		      subnode, addr, size);
+
 		if (addr + size > msmc_size ||
 		    !strncmp(fdt_get_name(blob, subnode, &len), "sysfw", 5) ||
-		    !strncmp(fdt_get_name(blob, subnode, &len), "l3cache", 7)) {
+		    !strncmp(fdt_get_name(blob, subnode, &len), "l3cache", 7) ||
+		    !strncmp(fdt_get_name(blob, subnode, &len), "tifs", 4)) {
 			fdt_del_node(blob, subnode);
 			debug("%s: deleting subnode %d\n", __func__, subnode);
 			if (!prev_node)
Signature · 1 line
2.34.1
#1 lore raw
Quoted 25 lines · Udit Kumar

This patch deletes tifs DT node as part of fixup.

TISCI API reported msmc_size, does not include 64KB reserved size for tifs aka MSMC comms memory.

As part of fixup, original code uses TISCI API reported msmc_size as size for sram DT node.

tifs node is similar to l3-cache, which should hold address above msms_size, and should be deleted before passing control to OS.

Documentation
https://software-dl.ti.com/tisci/esd/latest/2_tisci_msgs/general/core.html?highlight=msmc#tisci-msg-query-msmc

---
 arch/arm/mach-k3/common.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
arch/arm/mach-k3/common.c +0 -0
index a2adb791f6..4651744821 100644

arch/arm/mach-k3/common.c int fdt_fixup_msmc_ram(void *blob, char *parent_path, char *node_name) · line 356

Quoted 9 lines
arch/arm/mach-k3/common.c +3 -1
@@ -349,9 +349,11 @@ int fdt_fixup_msmc_ram(void *blob, char *parent_path, char *node_name)
 		size = fdt_read_number(sub_reg, 1);
 		debug("%s: subnode = %d, addr = 0x%x. size = 0x%x\n", __func__,
 		      subnode, addr, size);
+
 		if (addr + size > msmc_size ||
 		    !strncmp(fdt_get_name(blob, subnode, &len), "sysfw", 5) ||
-		    !strncmp(fdt_get_name(blob, subnode, &len), "l3cache", 7)) {
+		    !strncmp(fdt_get_name(blob, subnode, &len), "l3cache", 7) ||
+		    !strncmp(fdt_get_name(blob, subnode, &len), "tifs", 4)) {

I would probably move the tifs check above the l3cache check.

Quoted 6 lines
arch/arm/mach-k3/common.c +0 -0
 			fdt_del_node(blob, subnode);
 			debug("%s: deleting subnode %d\n", __func__, subnode);
 			if (!prev_node)
Signature · 1 line
2.34.1
Signature · 3 lines
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3  1A34 DDB5 849D 1736 249D
#2 lore raw

Thanks for review

Quoted 21 lines · Nishanth Menon
Quoted 20 lines · Udit Kumar

This patch deletes tifs DT node as part of fixup.

TISCI API reported msmc_size, does not include 64KB reserved size for tifs aka MSMC comms memory.

As part of fixup, original code uses TISCI API reported msmc_size as size for sram DT node.

tifs node is similar to l3-cache, which should hold address above msms_size, and should be deleted before passing control to OS.

Documentation
https://software-dl.ti.com/tisci/esd/latest/2_tisci_msgs/general/core.html?highlight=msmc#tisci-msg-query-msmc

---
  arch/arm/mach-k3/common.c | 4 +++-
  1 file changed, 3 insertions(+), 1 deletion(-)
Quoted 15 lines
Quoted 5 lines
arch/arm/mach-k3/common.c +0 -0
index a2adb791f6..4651744821 100644

arch/arm/mach-k3/common.c int fdt_fixup_msmc_ram(void *blob, char *parent_path, char *node_name) · line 356

Quoted 9 lines
arch/arm/mach-k3/common.c +3 -1
@@ -349,9 +349,11 @@ int fdt_fixup_msmc_ram(void *blob, char *parent_path, char *node_name)
  		size = fdt_read_number(sub_reg, 1);
  		debug("%s: subnode = %d, addr = 0x%x. size = 0x%x\n", __func__,
  		      subnode, addr, size);
+
  		if (addr + size > msmc_size ||
  		    !strncmp(fdt_get_name(blob, subnode, &len), "sysfw", 5) ||
-		    !strncmp(fdt_get_name(blob, subnode, &len), "l3cache", 7)) {
+		    !strncmp(fdt_get_name(blob, subnode, &len), "l3cache", 7) ||
+		    !strncmp(fdt_get_name(blob, subnode, &len), "tifs", 4)) {

I would probably move the tifs check above the l3cache check.

I will move this in v2.

you want to stay close to DT nodes order. or there is some other reason ?

Quoted 7 lines
Quoted 7 lines
arch/arm/mach-k3/common.c +0 -0
  			fdt_del_node(blob, subnode);
  			debug("%s: deleting subnode %d\n", __func__, subnode);
  			if (!prev_node)
Signature · 1 line
2.34.1
author
#3 lore raw

PATCH v2 1/1 arch: arm: mach-k3: Delete tifs node in DT fixup

In reply to Udit Kumar

This patch deletes tifs DT node as part of fixup.

TISCI API reported msmc_size, does not include 64KB reserved size for tifs aka MSMC comms memory.

As part of fixup, original code uses TISCI API reported msmc_size as size for sram DT node.

tifs node is similar to l3-cache, which should hold address above msms_size, and should be deleted before passing control to OS.

Documentation
https://software-dl.ti.com/tisci/esd/latest/2_tisci_msgs/general/core.html?highlight=msmc#tisci-msg-query-msmc

---
Changes since v1:
https://lore.kernel.org/all/[email protected]/
- moved tifs check above l3 as

 arch/arm/mach-k3/common.c | 1 +
 1 file changed, 1 insertion(+)
arch/arm/mach-k3/common.c +1 -0
index a2adb791f6..33b1f10d58 100644
@@ -351,6 +351,7 @@ int fdt_fixup_msmc_ram(void *blob, char *parent_path, char *node_name)
 		      subnode, addr, size);
 		if (addr + size > msmc_size ||
 		    !strncmp(fdt_get_name(blob, subnode, &len), "sysfw", 5) ||
+		    !strncmp(fdt_get_name(blob, subnode, &len), "tifs", 4)  ||
 		    !strncmp(fdt_get_name(blob, subnode, &len), "l3cache", 7)) {
 			fdt_del_node(blob, subnode);
 			debug("%s: deleting subnode %d\n", __func__, subnode);
Signature · 1 line
2.34.1
Reviewed-by on v2 1/1
#4 lore raw

Hi Udit

Quoted 29 lines · Udit Kumar

This patch deletes tifs DT node as part of fixup.

TISCI API reported msmc_size, does not include 64KB reserved size for tifs aka MSMC comms memory.

As part of fixup, original code uses TISCI API reported msmc_size as size for sram DT node.

tifs node is similar to l3-cache, which should hold address above msms_size, and should be deleted before passing control to OS.

Documentation
https://software-dl.ti.com/tisci/esd/latest/2_tisci_msgs/general/core.html?highlight=msmc#tisci-msg-query-msmc

---
Changes since v1:
https://lore.kernel.org/all/[email protected]/
- moved tifs check above l3 as

  arch/arm/mach-k3/common.c | 1 +
  1 file changed, 1 insertion(+)
arch/arm/mach-k3/common.c +0 -0
index a2adb791f6..33b1f10d58 100644

arch/arm/mach-k3/common.c int fdt_fixup_msmc_ram(void *blob, char *parent_path, char *node_name) · line 357

Quoted 7 lines
arch/arm/mach-k3/common.c +1 -0
@@ -351,6 +351,7 @@ int fdt_fixup_msmc_ram(void *blob, char *parent_path, char *node_name)
  		      subnode, addr, size);
  		if (addr + size > msmc_size ||
  		    !strncmp(fdt_get_name(blob, subnode, &len), "sysfw", 5) ||
+		    !strncmp(fdt_get_name(blob, subnode, &len), "tifs", 4)  ||
  		    !strncmp(fdt_get_name(blob, subnode, &len), "l3cache", 7)) {
  			fdt_del_node(blob, subnode);
  			debug("%s: deleting subnode %d\n", __func__, subnode);

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and am65) except j721s2?

Signature · 2 lines
Thanking You
Neha Malcom Francis
#5 lore raw

Hi Neha

Quoted 44 lines · Neha Malcom Francis

Hi Udit

Quoted 32 lines · Udit Kumar

This patch deletes tifs DT node as part of fixup.

TISCI API reported msmc_size, does not include 64KB reserved size for tifs aka MSMC comms memory.

As part of fixup, original code uses TISCI API reported msmc_size as size for sram DT node.

tifs node is similar to l3-cache, which should hold address above msms_size, and should be deleted before passing control to OS.

Documentation
https://software-dl.ti.com/tisci/esd/latest/2_tisci_msgs/general/core.html?highlight=msmc#tisci-msg-query-msmc

---
Changes since v1:
https://lore.kernel.org/all/[email protected]/
- moved tifs check above l3 as

  arch/arm/mach-k3/common.c | 1 +

  1 file changed, 1 insertion(+)
arch/arm/mach-k3/common.c +0 -0
index a2adb791f6..33b1f10d58 100644
@@ -351,6 +351,7 @@ int fdt_fixup_msmc_ram(void *blob, char 
 *parent_path, char *node_name)
                 subnode, addr, size);
Quoted 6 lines

          if (addr + size > msmc_size || !strncmp(fdt_get_name(blob, subnode, &len), "sysfw", 5) || +            !strncmp(fdt_get_name(blob, subnode, &len), "tifs", 4)  || !strncmp(fdt_get_name(blob, subnode, &len), "l3cache", 7)) { fdt_del_node(blob, subnode);
              debug("%s: deleting subnode %d\n", __func__, subnode);

Quoted 1 line

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and am65) except j721s2?

let me know, which source code you are referring to

I could see for j721s2 as well, in uboot[0] and Linux[1]

[0]

https://elixir.bootlin.com/linux/latest/source/arch/arm64/boot/dts/ti/k3-j721s2-main.dtsi#L16

[1]

https://elixir.bootlin.com/linux/latest/source/arch/arm64/boot/dts/ti/k3-j721s2-main.dtsi#L16

#6 lore raw

Hi Udit,

Quoted 46 lines · Udit

Hi Neha

Quoted 43 lines · Neha Malcom Francis

Hi Udit

Quoted 31 lines · Udit Kumar

This patch deletes tifs DT node as part of fixup.

TISCI API reported msmc_size, does not include 64KB reserved size for tifs aka MSMC comms memory.

As part of fixup, original code uses TISCI API reported msmc_size as size for sram DT node.

tifs node is similar to l3-cache, which should hold address above msms_size, and should be deleted before passing control to OS.

Documentation
https://software-dl.ti.com/tisci/esd/latest/2_tisci_msgs/general/core.html?highlight=msmc#tisci-msg-query-msmc

---
Changes since v1:
https://lore.kernel.org/all/[email protected]/
- moved tifs check above l3 as

  arch/arm/mach-k3/common.c | 1 +

  1 file changed, 1 insertion(+)
arch/arm/mach-k3/common.c +0 -0
index a2adb791f6..33b1f10d58 100644
@@ -351,6 +351,7 @@ int fdt_fixup_msmc_ram(void *blob, char 
 *parent_path, char *node_name)
                 subnode, addr, size);
Quoted 6 lines

          if (addr + size > msmc_size || !strncmp(fdt_get_name(blob, subnode, &len), "sysfw", 5) || +            !strncmp(fdt_get_name(blob, subnode, &len), "tifs", 4)  || !strncmp(fdt_get_name(blob, subnode, &len), "l3cache", 7)) { fdt_del_node(blob, subnode);
              debug("%s: deleting subnode %d\n", __func__, subnode);

Quoted 4 lines
Quoted 1 line

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and am65) except j721s2?

let me know, which source code you are referring to

In U-Boot, for j721e, j7200 and am65; they *only* contain atf-sram?

Quoted 11 lines

I could see for j721s2 as well, in uboot[0] and Linux[1]

[0]

https://elixir.bootlin.com/linux/latest/source/arch/arm64/boot/dts/ti/k3-j721s2-main.dtsi#L16

[1]

https://elixir.bootlin.com/linux/latest/source/arch/arm64/boot/dts/ti/k3-j721s2-main.dtsi#L16

Signature · 2 lines
Thanking You
Neha Malcom Francis
#7 lore raw

Hi Neha,

Quoted 1 line

Hi Udit,

[..]

Quoted 8 lines
Quoted 6 lines
Quoted 3 lines

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and am65) except j721s2?

let me know, which source code you are referring to

In U-Boot, for j721e, j7200 and am65; they *only* contain atf-sram?

For u-boot please see

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/dts/k3-j721s2-main.dtsi#L16

Quoted 1 line
Quoted 1 line

I could see for j721s2 as well, in uboot[0] and Linux[1]

[..]

Quoted 2 lines

Thanking You
Neha Malcom Francis

#8 lore raw

Hi Udit

Quoted 13 lines · Udit

Hi Neha,

Quoted 1 line

Hi Udit,

[..]

Quoted 7 lines
Quoted 6 lines
Quoted 3 lines

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and am65) except j721s2?

let me know, which source code you are referring to

Quoted 9 lines
Quoted 1 line

In U-Boot, for j721e, j7200 and am65; they *only* contain atf-sram?

For u-boot please see

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/dts/k3-j721s2-main.dtsi#L16

Quoted 1 line
Quoted 1 line

I could see for j721s2 as well, in uboot[0] and Linux[1]

[..]

What I mean to ask is, why aren't there tifs or l3cache subnodes in j721e, j7200 and am65?

Quoted 2 lines
Quoted 2 lines

Thanking You
Neha Malcom Francis

Signature · 2 lines
Thanking You
Neha Malcom Francis
#9 lore raw
Quoted 20 lines · Neha Malcom Francis

Hi Udit

Quoted 17 lines · Udit

Hi Neha,

Quoted 1 line

Hi Udit,

[..]

Quoted 8 lines
Quoted 6 lines
Quoted 3 lines

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and am65) except j721s2?

let me know, which source code you are referring to

In U-Boot, for j721e, j7200 and am65; they *only* contain atf-sram?

For u-boot please see

Quoted 9 lines
Quoted 5 lines

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/dts/k3-j721s2-main.dtsi#L16

Quoted 1 line
Quoted 1 line

I could see for j721s2 as well, in uboot[0] and Linux[1]

[..]

What I mean to ask is, why aren't there tifs or l3cache subnodes in j721e, j7200 and am65?

am65x has it
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/boot/dts/ti/k3-am65-main.dtsi#n17

J7200 and j721e is missing it
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/boot/dts/ti/k3-j721e-main.dtsi#n27
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/boot/dts/ti/k3-j7200-main.dtsi#n15

we need to fix it.

Signature · 3 lines
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3  1A34 DDB5 849D 1736 249D
#10 lore raw
In reply to Neha Malcom Francis

Hi Neha,

Quoted 20 lines · Neha Malcom Francis

Hi Udit

Quoted 17 lines · Udit

Hi Neha,

Quoted 1 line

Hi Udit,

[..]

Quoted 8 lines
Quoted 6 lines
Quoted 3 lines

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and am65) except j721s2?

let me know, which source code you are referring to

In U-Boot, for j721e, j7200 and am65; they *only* contain atf-sram?

For u-boot please see

Quoted 9 lines
Quoted 6 lines

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/dts/k3-j721s2-main.dtsi#L16

Quoted 1 line
Quoted 1 line

I could see for j721s2 as well, in uboot[0] and Linux[1]

[..]

What I mean to ask is, why aren't there tifs or l3cache subnodes in j721e, j7200 and am65?

I think,  above platform is doing in right way,

AFAIK,  if we have to provide then we can provide size of this.

l3-cache can not be addressable.

But in any case, u-boot removes this code before passing to OS.

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/mach-k3/common.c#L354

Quoted 3 lines
Quoted 2 lines
Quoted 2 lines

Thanking You
Neha Malcom Francis

#11 lore raw
Quoted 29 lines · Udit

Hi Neha,

Quoted 26 lines · Neha Malcom Francis

Hi Udit

Quoted 22 lines · Udit

Hi Neha,

Quoted 1 line

Hi Udit,

[..]

Quoted 8 lines
Quoted 6 lines
Quoted 3 lines

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and am65) except j721s2?

let me know, which source code you are referring to

In U-Boot, for j721e, j7200 and am65; they *only* contain atf-sram?

For u-boot please see

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/dts/k3-j721s2-main.dtsi#L16

Quoted 1 line
Quoted 1 line

I could see for j721s2 as well, in uboot[0] and Linux[1]

[..]

Quoted 8 lines
Quoted 2 lines

What I mean to ask is, why aren't there tifs or l3cache subnodes in j721e, j7200 and am65?

I think,  above platform is doing in right way,

AFAIK,  if we have to provide then we can provide size of this.

l3-cache can not be addressable.

So the history here is we used to have the SRAM node in DT sized to the actual size in hardware. L3 cache size can be set at boot time (in SYSFW board-config file), and that uses up some of the SRAM, so the end address moves in. We could represent this as a reserved node inside the full SRAM node, or by shrinking the SRAM node and hiding this. Same story for TIFS and ATF, they use some variable amount of the end of SRAM.

I'd prefer being explicit and keep these nodes.

Andrew

Quoted 7 lines

But in any case, u-boot removes this code before passing to OS.

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/mach-k3/common.c#L354

Quoted 3 lines
Quoted 2 lines
Quoted 2 lines

Thanking You
Neha Malcom Francis

#12 lore raw

Hi Andrew

Quoted 48 lines · Andrew Davis
Quoted 29 lines · Udit

Hi Neha,

Quoted 26 lines · Neha Malcom Francis

Hi Udit

Quoted 22 lines · Udit

Hi Neha,

Quoted 1 line

Hi Udit,

[..]

Quoted 8 lines
Quoted 6 lines
Quoted 3 lines

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and am65) except j721s2?

let me know, which source code you are referring to

In U-Boot, for j721e, j7200 and am65; they *only* contain atf-sram?

For u-boot please see

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/dts/k3-j721s2-main.dtsi#L16

Quoted 1 line
Quoted 1 line

I could see for j721s2 as well, in uboot[0] and Linux[1]

[..]

Quoted 8 lines
Quoted 2 lines

What I mean to ask is, why aren't there tifs or l3cache subnodes in j721e, j7200 and am65?

I think,  above platform is doing in right way,

AFAIK,  if we have to provide then we can provide size of this.

l3-cache can not be addressable.

So the history here is we used to have the SRAM node in DT sized to the actual size in hardware. L3 cache size can be set at boot time (in SYSFW board-config file), and that uses up some of the SRAM, so the end address moves in. We could represent this as a reserved node inside the full SRAM node, or by shrinking the SRAM node and hiding this. Same story for TIFS and ATF, they use some variable amount of the end of SRAM.

Quoted 4 lines

I'd prefer being explicit and keep these nodes.

Andrew

Thanks for the explanation, it does seem better to keep these nodes giving the complete description.

Quoted 8 lines
Quoted 8 lines

But in any case, u-boot removes this code before passing to OS.

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/mach-k3/common.c#L354

Quoted 3 lines
Quoted 2 lines
Quoted 2 lines

Thanking You
Neha Malcom Francis

Signature · 2 lines
Thanking You
Neha Malcom Francis
#13 lore raw
In reply to Andrew Davis
Quoted 41 lines · Andrew Davis
Quoted 30 lines · Udit

Hi Neha,

Quoted 27 lines · Neha Malcom Francis

Hi Udit

Quoted 23 lines · Udit

Hi Neha,

Quoted 1 line

Hi Udit,

[..]

Quoted 8 lines
Quoted 6 lines
Quoted 3 lines

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and am65) except j721s2?

let me know, which source code you are referring to

In U-Boot, for j721e, j7200 and am65; they *only* contain atf-sram?

For u-boot please see

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/dts/k3-j721s2-main.dtsi#L16

Quoted 1 line
Quoted 1 line

I could see for j721s2 as well, in uboot[0] and Linux[1]

[..]

Quoted 8 lines
Quoted 2 lines

What I mean to ask is, why aren't there tifs or l3cache subnodes in j721e, j7200 and am65?

I think,  above platform is doing in right way,

AFAIK,  if we have to provide then we can provide size of this.

l3-cache can not be addressable.

Quoted 8 lines

So the history here is we used to have the SRAM node in DT sized to the actual size in hardware. L3 cache size can be set at boot time (in SYSFW board-config file), and that uses up some of the SRAM, so the end address moves in. We could represent this as a reserved node inside the full SRAM node, or by shrinking the SRAM node and hiding this. Same story for TIFS and ATF, they use some variable amount of the end of SRAM.

Ah, I have other view.

We shrunk SRAM size already, having reserved node on top of SRAM

is good as removing this.

Quoted 13 lines

I'd prefer being explicit and keep these nodes.

Andrew

Quoted 8 lines

But in any case, u-boot removes this code before passing to OS.

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/mach-k3/common.c#L354

Quoted 3 lines
Quoted 2 lines
Quoted 2 lines

Thanking You
Neha Malcom Francis

#14 lore raw
Quoted 53 lines · Udit
Quoted 43 lines · Andrew Davis
Quoted 31 lines · Udit

Hi Neha,

Quoted 28 lines · Neha Malcom Francis

Hi Udit

Quoted 24 lines · Udit

Hi Neha,

Quoted 1 line

Hi Udit,

[..]

Quoted 9 lines
Quoted 7 lines
Quoted 4 lines

I do have a general doubt; why do we have only atf-sram sub-node in msmc_sram in all other devices (j721e, j7200 and
am65) except j721s2?

let me know, which source code you are referring to

In U-Boot, for j721e, j7200 and am65; they *only* contain atf-sram?

For u-boot please see

https://elixir.bootlin.com/u-boot/latest/source/arch/arm/dts/k3-j721s2-main.dtsi#L16

Quoted 1 line
Quoted 1 line

I could see for j721s2 as well, in uboot[0] and Linux[1]

[..]

Quoted 9 lines
Quoted 3 lines

What I mean to ask is, why aren't there tifs or l3cache subnodes in j721e, j7200 and am65?

I think,  above platform is doing in right way,

AFAIK,  if we have to provide then we can provide size of this.

l3-cache can not be addressable.

Quoted 8 lines

So the history here is we used to have the SRAM node in DT sized to the actual size in hardware. L3 cache size can be set at boot time (in SYSFW board-config file), and that uses up some of the SRAM, so the end address moves in. We could represent this as a reserved node inside the full SRAM node, or by shrinking the SRAM node and hiding this. Same story for TIFS and ATF, they use some variable amount of the end of SRAM.

Quoted 5 lines

Ah, I have other view.

We shrunk SRAM size already, having reserved node on top of SRAM

is good as removing this.

How about we do this:
a) Start by discussing in k.org with a patch as to how we think it should be and what the rationale is.

b) SRAM size fixup is a consequence of firmware being flexible.. Since, the tifs reserved sram etc, base description exists even after "hardware reconfiguration", u-boot may adjust, but not delete such nodes. "reserved" is part of complete description and indication that this specific OS is not supposed to use this region. That region is protected by firewall and mechanisms to make such access fail, but that is the point of "reserved" nodes.

c) Standardize this across the SoCs that use MSMC (WITHOUT BREAKING FORWARD AND BACKWARD COMPATIBILITY of u-boot vs dtb).

Signature · 3 lines
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3  1A34 DDB5 849D 1736 249D
#15 lore raw

Hi Nishanth,

Quoted 33 lines · Nishanth Menon
Quoted 32 lines · Udit
Quoted 31 lines · Andrew Davis
Quoted 12 lines · Udit

Hi Neha,

Quoted 9 lines · Neha Malcom Francis

Hi Udit

Quoted 6 lines · Udit

Hi Neha,

Quoted 1 line

Hi Udit,

[..]
[..]

Quoted 9 lines
Quoted 3 lines

What I mean to ask is, why aren't there tifs or l3cache subnodes in j721e, j7200 and am65?

I think,  above platform is doing in right way,

AFAIK,  if we have to provide then we can provide size of this.

l3-cache can not be addressable.

So the history here is we used to have the SRAM node in DT sized to the actual size in hardware. L3 cache size can be set at boot time (in SYSFW board-config file), and that uses up some of the SRAM, so the end address moves in. We could represent this as a reserved node inside the full SRAM node, or by shrinking the SRAM node and hiding this. Same story for TIFS and ATF, they use some variable amount of the end of SRAM.

Quoted 8 lines
Quoted 5 lines

Ah, I have other view.

We shrunk SRAM size already, having reserved node on top of SRAM

is good as removing this.

How about we do this:
a) Start by discussing in k.org with a patch as to how we think it should be and what the rationale is.

ok

Quoted 7 lines

b) SRAM size fixup is a consequence of firmware being flexible.. Since, the tifs reserved sram etc, base description exists even after "hardware reconfiguration", u-boot may adjust, but not delete such nodes. "reserved" is part of complete description and indication that this specific OS is not supposed to use this region. That region is protected by firewall and mechanisms to make such access fail, but that is the point of "reserved" nodes.

you mean , keep full view of SRAM and update size of reserved node.

BTW, L3-cache and tifs will be reserved by default.

Quoted 3 lines

c) Standardize this across the SoCs that use MSMC (WITHOUT BREAKING FORWARD AND BACKWARD COMPATIBILITY of u-boot vs dtb).