Skip to contentSkip to conversation

Add QOS support for J722S and AM62P

PATCH Superseded Jayesh Choudhary 1 participant 6 messages Nov 6, 2024

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

cover Add QOS support for J722S and AM62P

Add QOS support for DSS in TI K3 SoC to route the DSS traffic through RT queue by setting orderID as 15:
- J722S
- AM62P

Jayesh Choudhary (4):
arm: mach-k3: j722s: Add QoS support for DSS
arm: mach-k3: am62p: Add QoS support for DSS
configs: j722s_evm_r5_defconfig: Enable CONFIG_K3_QOS
configs: am62p_evm_r5_defconfig: Enable CONFIG_K3_QOS

 arch/arm/mach-k3/am62px/am62p5_init.c        |  2 +
 arch/arm/mach-k3/j722s/j722s_init.c          |  1 +
 arch/arm/mach-k3/r5/am62px/Makefile          |  1 +
 arch/arm/mach-k3/r5/am62px/am62p_qos.h       | 42 ++++++++++++++
 arch/arm/mach-k3/r5/am62px/am62p_qos_uboot.c | 58 ++++++++++++++++++++
 arch/arm/mach-k3/r5/j722s/Makefile           |  1 +
 arch/arm/mach-k3/r5/j722s/j722s_qos.h        | 51 +++++++++++++++++
 arch/arm/mach-k3/r5/j722s/j722s_qos_uboot.c  | 58 ++++++++++++++++++++
 configs/am62px_evm_r5_defconfig              |  1 +
 configs/j722s_evm_r5_defconfig               |  1 +
 10 files changed, 216 insertions(+)
 create mode 100644 arch/arm/mach-k3/r5/am62px/am62p_qos.h
 create mode 100644 arch/arm/mach-k3/r5/am62px/am62p_qos_uboot.c
 create mode 100644 arch/arm/mach-k3/r5/j722s/j722s_qos.h
 create mode 100644 arch/arm/mach-k3/r5/j722s/j722s_qos_uboot.c
Signature · 1 line
2.34.1
#1 lore raw

PATCH 1/4 arm: mach-k3: j722s: Add QoS support for DSS

Enable Quality of Service (QoS) blocks for Display SubSystem (DSS), by servicing the DSS - DDR traffic from the Real-Time (RT) queue. This is done by setting the DSS DMA orderID to greater than 7.

The C7x and VPAC can overwhelm the DSS's access to the DDR because of their higher frequency DDR accesses. This can cause flickering in display with certain edgeAI models running parallely if the DSS traffic is being serviced through non-RT queue.

---
 arch/arm/mach-k3/j722s/j722s_init.c         |  1 +
 arch/arm/mach-k3/r5/j722s/Makefile          |  1 +
 arch/arm/mach-k3/r5/j722s/j722s_qos.h       | 51 ++++++++++++++++++
 arch/arm/mach-k3/r5/j722s/j722s_qos_uboot.c | 58 +++++++++++++++++++++
 4 files changed, 111 insertions(+)
 create mode 100644 arch/arm/mach-k3/r5/j722s/j722s_qos.h
 create mode 100644 arch/arm/mach-k3/r5/j722s/j722s_qos_uboot.c
arch/arm/mach-k3/j722s/j722s_init.c +1 -0
index 01b00681f6..0313e1148b 100644
@@ -165,6 +165,7 @@ void board_init_f(ulong dummy)
 {
 	k3_spl_init();
 	k3_mem_init();
+	setup_qos();
 }
 
 static u32 __get_backup_bootmedia(u32 devstat)
arch/arm/mach-k3/r5/j722s/Makefile +1 -0
index 2a0dbf5f5a..2f0b35a41e 100644
@@ -4,3 +4,4 @@
 
 obj-y += clk-data.o
 obj-y += dev-data.o
+obj-y += j722s_qos_uboot.o
arch/arm/mach-k3/r5/j722s/j722s_qos.h new file +51 -0

51 lines not on this page · raw message

arch/arm/mach-k3/r5/j722s/j722s_qos_uboot.c new file +58 -0

58 lines not on this page · raw message

Signature · 1 line
2.34.1
#2 lore raw

PATCH 2/4 arm: mach-k3: am62p: Add QoS support for DSS

In reply to Jayesh Choudhary

Enable Quality of Service (QoS) blocks for Display SubSystem (DSS), by servicing the DSS - DDR traffic from the Real-Time (RT) queue. This is done by setting the DSS DMA orderID to greater than 7.

The C7x and VPAC can overwhelm the DSS's access to the DDR because of their higher frequency DDR accesses. This can cause flickering in display with certain edgeAI models running parallely if the DSS traffic is being serviced through non-RT queue.

---
 arch/arm/mach-k3/am62px/am62p5_init.c        |  2 +
 arch/arm/mach-k3/r5/am62px/Makefile          |  1 +
 arch/arm/mach-k3/r5/am62px/am62p_qos.h       | 42 ++++++++++++++
 arch/arm/mach-k3/r5/am62px/am62p_qos_uboot.c | 58 ++++++++++++++++++++
 4 files changed, 103 insertions(+)
 create mode 100644 arch/arm/mach-k3/r5/am62px/am62p_qos.h
 create mode 100644 arch/arm/mach-k3/r5/am62px/am62p_qos_uboot.c
arch/arm/mach-k3/am62px/am62p5_init.c +2 -0
index 34ed01cd78..2d35a7ce77 100644
@@ -159,6 +159,8 @@ void board_init_f(ulong dummy)
 	}
 
 	spl_enable_cache();
+
+	setup_qos();
 	debug("am62px_init: %s done\n", __func__);
 }
 
arch/arm/mach-k3/r5/am62px/Makefile +1 -0
index 091d4fa5b4..066c3cef8d 100644
@@ -4,3 +4,4 @@
 
 obj-y += clk-data.o
 obj-y += dev-data.o
+obj-y += am62p_qos_uboot.o
arch/arm/mach-k3/r5/am62px/am62p_qos.h new file +42 -0

42 lines not on this page · raw message

arch/arm/mach-k3/r5/am62px/am62p_qos_uboot.c new file +58 -0

58 lines not on this page · raw message

Signature · 1 line
2.34.1
#3 lore raw

Re: [PATCH 2/4] arm: mach-k3: am62p: Add QoS support for DSS

Hello All,

Quoted 5 lines · Jayesh Choudhary

Enable Quality of Service (QoS) blocks for Display SubSystem (DSS), by servicing the DSS - DDR traffic from the Real-Time (RT) queue. This is done by setting the DSS DMA orderID to greater than 7.

The C7x and VPAC can overwhelm the DSS's access to the DDR because of

This part here is wrong as AM62P does not have C7x core. So I will fix the commit message in the next revision appropriately. Sorry about that!

(I will re-roll after sometime to see if there are any more comments)

Quoted 6 lines

their higher frequency DDR accesses. This can cause flickering in display with certain edgeAI models running parallely if the DSS traffic is being serviced through non-RT queue.

---

[...]

Thanks,
Jayesh

#4 lore raw

PATCH 3/4 configs: j722s_evm_r5_defconfig: Enable CONFIG_K3_QOS

In reply to Jayesh Choudhary

Enable CONFIG_K3_QOS to set QoS registers in R5 boot stage.

---
 configs/j722s_evm_r5_defconfig | 1 +
 1 file changed, 1 insertion(+)
configs/j722s_evm_r5_defconfig +1 -0
index e574be9e19..d119e46ff1 100644
@@ -91,6 +91,7 @@ CONFIG_TI_SCI_PROTOCOL=y
 CONFIG_DM_I2C=y
 CONFIG_SYS_I2C_OMAP24XX=y
 CONFIG_DM_MAILBOX=y
+CONFIG_K3_QOS=y
 CONFIG_K3_SEC_PROXY=y
 CONFIG_MMC_HS400_SUPPORT=y
 CONFIG_MMC_SDHCI=y
Signature · 1 line
2.34.1
#5 lore raw

PATCH 4/4 configs: am62p_evm_r5_defconfig: Enable CONFIG_K3_QOS

In reply to Jayesh Choudhary

Enable CONFIG_K3_QOS to set QoS registers in R5 boot stage.

---
 configs/am62px_evm_r5_defconfig | 1 +
 1 file changed, 1 insertion(+)
configs/am62px_evm_r5_defconfig +1 -0
index 4f7be44cfb..edff75de74 100644
@@ -91,6 +91,7 @@ CONFIG_TI_SCI_PROTOCOL=y
 CONFIG_DM_I2C=y
 CONFIG_SYS_I2C_OMAP24XX=y
 CONFIG_DM_MAILBOX=y
+CONFIG_K3_QOS=y
 CONFIG_K3_SEC_PROXY=y
 CONFIG_MMC_HS400_SUPPORT=y
 CONFIG_MMC_SDHCI=y
Signature · 1 line
2.34.1