Skip to contentSkip to conversation

Add QOS support for J722S and AM62P

PATCH In review Jayesh Choudhary 3 participants 7 messages Nov 26, 2024 – Dec 13, 2024

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

v2 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

Changelog v1->v2:
- Rebased on the tip of next branch
- Corrected the commit message in patch 2/4

v1:
<https://lore.kernel.org/all/[email protected]/>

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 v2 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 v2 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.

DDR intensive software applications can overwhelm the DSS's access to the DDR because of their higher frequency DDR accesses. This can cause flickering in display with certain applications 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

PATCH v2 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 a3c13fedef..0f7cd4bf37 100644
@@ -89,6 +89,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
#4 lore raw

PATCH v2 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 a93c33c1d9..a0eaa128f4 100644
@@ -89,6 +89,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
Reviewed-by on the v2 series
#5 lore raw
In reply to Jayesh Choudhary
Quoted 9 lines · Jayesh Choudhary

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

Changelog v1->v2:
- Rebased on the tip of next branch
- Corrected the commit message in patch 2/4

Quoted 9 lines

v1:
<https://lore.kernel.org/all/[email protected]/>

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

For the series,

Regards
Devarsh

#6 lore raw
In reply to Jayesh Choudhary
Quoted 10 lines · Jayesh Choudhary

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

Changelog v1->v2:
- Rebased on the tip of next branch
- Corrected the commit message in patch 2/4

[...]

Applied to u-boot/next, thanks!

Signature · 1 line
Tom