Date   

Re: [master][PATCH 1/4] meta-ti: rename j7-evm to j721e-evm

Ryan Eatmon
 

On 3/28/2022 11:49 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 01:41:48PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
In many places we use "j7" the family when we should be using a
specific SoC or EVM and vice-versa. For instance when including
graphics drivers we add for all "j7" family, but what we really
want is only for some specific j7 SoC.

First step in untangling this is to make it clear that there is
no SoC called j7. There is a SoC called j721e with a j721e-evm.

Fix up this naming here.

Signed-off-by: Andrew Davis <afd@...>
Tested-by: Denys Dmytriyenko <denys@...>
Appled patch to master.

--
Ryan Eatmon reatmon@...
-----------------------------------------
Texas Instruments, Inc. - LCPD - MGTS


Re: [dunfell][PATCH v4] machine: Add am62xx evm configuration

Ryan Eatmon
 

On 3/29/2022 12:41 AM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 04:06:32PM -0500, Ryan Eatmon via lists.yoctoproject.org wrote:
From: Nishanth Menon <nm@...>

Lets add the basic AM62xx-evm configuration.
- Add configurations.
- Add firmware overrides.
- Add u-boot overrides.
That's the result of squashing. The five various development commits touched the files in varying ways. So they ended up as a single patch.

The only other option would be for me to make the edits by hand (by copying each aggregated file to a new copy of the repository) and then doing new commits of the "clean" file. Which is preferable?


Everything in one patch?

Signed-off-by: Nishanth Menon <nm@...>
Signed-off-by: Hari Nagalla <hnagalla@...>
Signed-off-by: Ryan Eatmon <reatmon@...>
---
v2: Removed ti-graphics patch, and removed lpm-demo patches.
v3: Squashed and cleaned up the previous patches.
v4: Removed tabs that made their way into some of the files, and added
more to the commit message.

conf/machine/am62xx-evm-k3r5.conf | 11 +++++++
conf/machine/am62xx-evm.conf | 13 ++++++++
conf/machine/include/am62xx.inc | 17 ++++++++++
recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb | 18 ++++++++++
recipes-bsp/u-boot/u-boot-ti.inc | 7 ++++
recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb | 38 +++++++++++++++++++---
6 files changed, 99 insertions(+), 5 deletions(-)
create mode 100644 conf/machine/am62xx-evm-k3r5.conf
create mode 100644 conf/machine/am62xx-evm.conf
create mode 100644 conf/machine/include/am62xx.inc

diff --git a/conf/machine/am62xx-evm-k3r5.conf b/conf/machine/am62xx-evm-k3r5.conf
new file mode 100644
index 00000000..724a8d4a
--- /dev/null
+++ b/conf/machine/am62xx-evm-k3r5.conf
@@ -0,0 +1,11 @@
+#@TYPE: Machine
+#@NAME: AM62XX EVM (R5F)
+#@DESCRIPTION: Machine configuration for the TI AM62xx EVM (R5F core)
+
+require conf/machine/include/k3r5.inc
+
+SYSFW_SOC = "am62x"
+SYSFW_CONFIG = "evm"
+SYSFW_SUFFIX = "gp"
+
+UBOOT_MACHINE = "am62x_evm_r5_defconfig"
diff --git a/conf/machine/am62xx-evm.conf b/conf/machine/am62xx-evm.conf
new file mode 100644
index 00000000..600abb58
--- /dev/null
+++ b/conf/machine/am62xx-evm.conf
@@ -0,0 +1,13 @@
+#@TYPE: Machine
+#@NAME: AM62XX EVM
+#@DESCRIPTION: Machine configuration for the TI AM62XX EVM
+
+require conf/machine/include/am62xx.inc
+
+KERNEL_DEVICETREE = " \
+ ti/k3-am625-sk.dtb \
+ ti/k3-am625-sk-lpmdemo.dtb \
+ ti/k3-am625-minimal.dtb \
+"
+
+UBOOT_MACHINE = "am62x_evm_a53_defconfig"
diff --git a/conf/machine/include/am62xx.inc b/conf/machine/include/am62xx.inc
new file mode 100644
index 00000000..e8823dd2
--- /dev/null
+++ b/conf/machine/include/am62xx.inc
@@ -0,0 +1,17 @@
+require conf/machine/include/k3.inc
+SOC_FAMILY_append = ":am62xx"
+
+MACHINE_FEATURES += "screen touchscreen"
+
+SERIAL_CONSOLES = "115200;ttyS2"
+SERIAL_CONSOLES_CHECK = "${SERIAL_CONSOLES}"
+
+# AM62 supports multi-certificate images, use the same
+IMAGE_BOOT_FILES = "${IMAGE_BOOT_FILES_MULTI_CERT}"
+
+do_image_wic[mcdepends] = "mc::k3r5:ti-sci-fw:do_deploy"
+do_image_tar[mcdepends] = "mc::k3r5:ti-sci-fw:do_deploy"
+
+TFA_BOARD = "lite"
+OPTEEMACHINE = "k3-am65x"
+OPTEEOUTPUTMACHINE = "k3"
diff --git a/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb b/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb
index 646833a7..099473b4 100644
--- a/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb
+++ b/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb
@@ -6,6 +6,7 @@ DEPENDS_append_j7200-hs-evm-k3r5 = " virtual/bootloader"
DEPENDS_append_j721s2-evm-k3r5 = " virtual/bootloader"
DEPENDS_append_am64xx-evm-k3r5 = " virtual/bootloader"
DEPENDS_append_am64xx-hs-evm-k3r5 = " virtual/bootloader"
+DEPENDS_append_am62xx-evm-k3r5 = " virtual/bootloader"
CLEANBROKEN = "1"
PR = "${INC_PR}.2"
@@ -29,6 +30,7 @@ SYSFW_PREFIX_j7-hs-evm-k3r5-sr1-1 = "ti-fs-firmware"
SYSFW_PREFIX_j7200-evm-k3r5 = "ti-fs-firmware"
SYSFW_PREFIX_j7200-hs-evm-k3r5 = "ti-fs-firmware"
SYSFW_PREFIX_j721s2-evm-k3r5 = "ti-fs-firmware"
+SYSFW_PREFIX_am62xx-evm-k3r5 = "ti-fs-firmware"
SYSFW_SUFFIX ?= "unknown"
@@ -63,6 +65,7 @@ EXTRA_OEMAKE_append_j7200-hs-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-s
EXTRA_OEMAKE_append_j721s2-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""
EXTRA_OEMAKE_append_am64xx-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""
EXTRA_OEMAKE_append_am64xx-hs-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""
+EXTRA_OEMAKE_append_am62xx-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""
do_compile() {
cd ${WORKDIR}/imggen/
@@ -170,4 +173,19 @@ do_deploy_am64xx-hs-evm-k3r5() {
install -m 644 ${SYSFW_TISCI} ${DEPLOYDIR}/
}
+do_install_am62xx-evm-k3r5() {
+ install -d ${D}/boot
+ install -m 644 ${WORKDIR}/imggen/${UBOOT_BINARY} ${D}/boot/${UBOOT_IMAGE}
+ ln -sf ${UBOOT_IMAGE} ${D}/boot/${UBOOT_SYMLINK}
+ ln -sf ${UBOOT_IMAGE} ${D}/boot/${UBOOT_BINARY}
+}
+
+do_deploy_am62xx-evm-k3r5() {
+ install -d ${DEPLOYDIR}
+ install -m 644 ${WORKDIR}/imggen/${UBOOT_BINARY} ${DEPLOYDIR}/${UBOOT_IMAGE}
+ ln -sf ${UBOOT_IMAGE} ${DEPLOYDIR}/${UBOOT_SYMLINK}
+ ln -sf ${UBOOT_IMAGE} ${DEPLOYDIR}/${UBOOT_BINARY}
+ install -m 644 ${SYSFW_TISCI} ${DEPLOYDIR}/
+}
+
addtask deploy before do_build after do_compile
diff --git a/recipes-bsp/u-boot/u-boot-ti.inc b/recipes-bsp/u-boot/u-boot-ti.inc
index 7ed6c5b4..231b7647 100644
--- a/recipes-bsp/u-boot/u-boot-ti.inc
+++ b/recipes-bsp/u-boot/u-boot-ti.inc
@@ -41,6 +41,7 @@ PACKAGECONFIG[dm] = "DM=${STAGING_DIR_HOST}${nonarch_base_libdir}/firmware/pdk-i
PACKAGECONFIG_append_aarch64 = " atf optee"
PACKAGECONFIG_append_j7 = " dm"
+PACKAGECONFIG_append_am62xx = " dm"
COMPATIBLE_MACHINE = "(ti-soc)"
@@ -69,6 +70,7 @@ SPL_UART_BINARY_j7200-hs-evm-k3r5 = "u-boot-spl.bin"
SPL_UART_BINARY_j721s2-evm-k3r5 = "u-boot-spl.bin"
SPL_UART_BINARY_am64xx-evm-k3r5 = "u-boot-spl.bin"
SPL_UART_BINARY_am64xx-hs-evm-k3r5 = "u-boot-spl.bin"
+SPL_UART_BINARY_am62xx-evm-k3r5 = "u-boot-spl.bin"
SPL_UART_IMAGE ?= "${SPL_UART_BINARY}-${MACHINE}-${PV}-${PR}"
SPL_UART_SYMLINK ?= "${SPL_UART_BINARY}-${MACHINE}"
@@ -419,4 +421,9 @@ do_deploy_append_am64xx-hs-evm-k3r5 () {
mv ${DEPLOYDIR}/u-boot-spl.bin ${DEPLOYDIR}/u-boot-spl-r5spl.bin || true
}
+do_deploy_append_am62xx-evm-k3r5 () {
+ mv ${DEPLOYDIR}/tiboot3.bin ${DEPLOYDIR}/tiboot3-r5spl.bin || true
+ mv ${DEPLOYDIR}/u-boot-spl.bin ${DEPLOYDIR}/u-boot-spl-r5spl.bin || true
+}
+
TOOLCHAIN = "gcc"
diff --git a/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb b/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb
index c5852dbd..02e5d665 100644
--- a/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb
+++ b/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb
@@ -19,6 +19,7 @@ PLAT_SFX_j7200-hs-evm = "j7200"
PLAT_SFX_j721s2-evm = "j721s2"
PLAT_SFX_am65xx = "am65xx"
PLAT_SFX_am64xx = "am64xx"
+PLAT_SFX_am62xx = "am62x"
FILESEXTRAPATHS_prepend := "${METATIBASE}/recipes-bsp/ti-sci-fw/files/:"
require recipes-bsp/ti-linux-fw/ti-linux-fw.inc
@@ -50,11 +51,11 @@ DM_FIRMWARE = "ipc_echo_testb_mcu1_0_release_strip.xer5f"
# J7 HS support
do_install_prepend_j7-hs-evm() {
- export TI_SECURE_DEV_PKG=${TI_SECURE_DEV_PKG}
- ( cd ${RTOS_DM_FW_DIR}; \
- mv ${DM_FIRMWARE} ${DM_FIRMWARE}.unsigned; \
- ${TI_SECURE_DEV_PKG}/scripts/secure-binary-image.sh ${DM_FIRMWARE}.unsigned ${DM_FIRMWARE}; \
- )
+ export TI_SECURE_DEV_PKG=${TI_SECURE_DEV_PKG}
+ ( cd ${RTOS_DM_FW_DIR}; \
+ mv ${DM_FIRMWARE} ${DM_FIRMWARE}.unsigned; \
+ ${TI_SECURE_DEV_PKG}/scripts/secure-binary-image.sh ${DM_FIRMWARE}.unsigned ${DM_FIRMWARE}; \
+ )
}
# J7 HS support
@@ -77,6 +78,13 @@ do_install_prepend_am64xx() {
)
}
+# Update the am62xx ipc binaries to be consistent with other platforms
+do_install_prepend_am62xx() {
+ ( cd ${RTOS_IPC_FW_DIR}; \
+ mv am62-mcu-m4f0_0-fw ipc_echo_baremetal_test_mcu2_0_release_strip.xer5f; \
+ )
+}
+
#Install all R5 & DSP ipc echo test binaries in lib/firmware/pdk-ipc, with softlinks up a level
do_install() {
@@ -154,6 +162,13 @@ do_install_am64xx() {
install -m 0644 ${RTOS_IPC_FW_DIR}/ipc_echo_baremetal_test_mcu3_0_release_strip.xer5f ${LEGACY_IPC_FW_DIR}
}
+do_install_am62xx() {
+ install -d ${LEGACY_IPC_FW_DIR}
+ install -m 0644 ${RTOS_IPC_FW_DIR}/ipc_echo_baremetal_test_mcu2_0_release_strip.xer5f ${LEGACY_IPC_FW_DIR}
+ # DM Firmware
+ install -m 0644 ${RTOS_DM_FW_DIR}/ipc_echo_testb_mcu1_0_release_strip.xer5f ${LEGACY_DM_FW_DIR}
+}
+
# Set up names for the firmwares
ALTERNATIVE_${PN}_am65xx = "\
am65x-mcu-r5f0_0-fw \
@@ -167,6 +182,10 @@ ALTERNATIVE_${PN}_am64xx = "\
am64-main-r5f1_1-fw \
am64-mcu-m4f0_0-fw \
"
+ALTERNATIVE_${PN}_am62xx = "\
+ am62-mcu-m4f0_0-fw \
+ am62-main-r5f0_0-fw \
+ "
ALTERNATIVE_${PN}_j7 = "\
j7-mcu-r5f0_0-fw \
@@ -216,6 +235,9 @@ TARGET_MAIN_R5FSS1_0_am64xx = "am64-main-r5f1_0-fw"
TARGET_MAIN_R5FSS1_1_am64xx = "am64-main-r5f1_1-fw"
TARGET_MCU_M4FSS0_0_am64xx = "am64-mcu-m4f0_0-fw"
+TARGET_MAIN_R5FSS0_0_am62xx = "am62-main-r5f0_0-fw"
+TARGET_MCU_M4FSS0_0_am62xx = "am62-mcu-m4f0_0-fw"
+
TARGET_MCU_R5FSS0_0_j7 = "j7-mcu-r5f0_0-fw"
TARGET_MCU_R5FSS0_1_j7 = "j7-mcu-r5f0_1-fw"
TARGET_MAIN_R5FSS0_0_j7 = "j7-main-r5f0_0-fw"
@@ -254,6 +276,9 @@ ALTERNATIVE_LINK_NAME[am64-main-r5f1_0-fw] = "${base_libdir}/firmware/${TARGET_M
ALTERNATIVE_LINK_NAME[am64-main-r5f1_1-fw] = "${base_libdir}/firmware/${TARGET_MAIN_R5FSS1_1}"
ALTERNATIVE_LINK_NAME[am64-mcu-m4f0_0-fw] = "${base_libdir}/firmware/${TARGET_MCU_M4FSS0_0}"
+ALTERNATIVE_LINK_NAME[am62-main-r5f0_0-fw] = "${base_libdir}/firmware/${TARGET_MAIN_R5FSS0_0}"
+ALTERNATIVE_LINK_NAME[am62-mcu-m4f0_0-fw] = "${base_libdir}/firmware/${TARGET_MCU_M4FSS0_0}"
+
ALTERNATIVE_LINK_NAME[j7-mcu-r5f0_0-fw] = "${base_libdir}/firmware/${TARGET_MCU_R5FSS0_0}"
ALTERNATIVE_LINK_NAME[j7-mcu-r5f0_1-fw] = "${base_libdir}/firmware/${TARGET_MCU_R5FSS0_1}"
ALTERNATIVE_LINK_NAME[j7-main-r5f0_0-fw] = "${base_libdir}/firmware/${TARGET_MAIN_R5FSS0_0}"
@@ -289,6 +314,9 @@ ALTERNATIVE_TARGET[am64-main-r5f1_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_e
ALTERNATIVE_TARGET[am64-main-r5f1_1-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_baremetal_test_mcu2_1_release_strip.xer5f"
ALTERNATIVE_TARGET[am64-mcu-m4f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_baremetal_test_mcu3_0_release_strip.xer5f"
+ALTERNATIVE_TARGET[am62-main-r5f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_testb_mcu1_0_release_strip.xer5f"
+ALTERNATIVE_TARGET[am62-mcu-m4f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_baremetal_test_mcu2_0_release_strip.xer5f"
+
ALTERNATIVE_TARGET[j7-mcu-r5f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_testb_mcu1_0_release_strip.xer5f"
ALTERNATIVE_TARGET[j7-mcu-r5f0_1-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_test_mcu1_1_release_strip.xer5f"
ALTERNATIVE_TARGET[j7-main-r5f0_0-fw] = "${base_libdir}/firmware/ethfw/app_remoteswitchcfg_server_strip.xer5f"
--
2.17.1
--
Ryan Eatmon Texas Instruments, Inc. reatmon@...
--------------------------------------------------------
Analog EDA - Simulation Development - MGTS


Re: [dunfell][PATCH v4] machine: Add am62xx evm configuration

Denys Dmytriyenko
 

On Fri, Mar 25, 2022 at 04:06:32PM -0500, Ryan Eatmon via lists.yoctoproject.org wrote:
From: Nishanth Menon <nm@...>

Lets add the basic AM62xx-evm configuration.
- Add configurations.
- Add firmware overrides.
- Add u-boot overrides.
Everything in one patch?


Signed-off-by: Nishanth Menon <nm@...>
Signed-off-by: Hari Nagalla <hnagalla@...>
Signed-off-by: Ryan Eatmon <reatmon@...>
---
v2: Removed ti-graphics patch, and removed lpm-demo patches.
v3: Squashed and cleaned up the previous patches.
v4: Removed tabs that made their way into some of the files, and added
more to the commit message.

conf/machine/am62xx-evm-k3r5.conf | 11 +++++++
conf/machine/am62xx-evm.conf | 13 ++++++++
conf/machine/include/am62xx.inc | 17 ++++++++++
recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb | 18 ++++++++++
recipes-bsp/u-boot/u-boot-ti.inc | 7 ++++
recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb | 38 +++++++++++++++++++---
6 files changed, 99 insertions(+), 5 deletions(-)
create mode 100644 conf/machine/am62xx-evm-k3r5.conf
create mode 100644 conf/machine/am62xx-evm.conf
create mode 100644 conf/machine/include/am62xx.inc

diff --git a/conf/machine/am62xx-evm-k3r5.conf b/conf/machine/am62xx-evm-k3r5.conf
new file mode 100644
index 00000000..724a8d4a
--- /dev/null
+++ b/conf/machine/am62xx-evm-k3r5.conf
@@ -0,0 +1,11 @@
+#@TYPE: Machine
+#@NAME: AM62XX EVM (R5F)
+#@DESCRIPTION: Machine configuration for the TI AM62xx EVM (R5F core)
+
+require conf/machine/include/k3r5.inc
+
+SYSFW_SOC = "am62x"
+SYSFW_CONFIG = "evm"
+SYSFW_SUFFIX = "gp"
+
+UBOOT_MACHINE = "am62x_evm_r5_defconfig"
diff --git a/conf/machine/am62xx-evm.conf b/conf/machine/am62xx-evm.conf
new file mode 100644
index 00000000..600abb58
--- /dev/null
+++ b/conf/machine/am62xx-evm.conf
@@ -0,0 +1,13 @@
+#@TYPE: Machine
+#@NAME: AM62XX EVM
+#@DESCRIPTION: Machine configuration for the TI AM62XX EVM
+
+require conf/machine/include/am62xx.inc
+
+KERNEL_DEVICETREE = " \
+ ti/k3-am625-sk.dtb \
+ ti/k3-am625-sk-lpmdemo.dtb \
+ ti/k3-am625-minimal.dtb \
+"
+
+UBOOT_MACHINE = "am62x_evm_a53_defconfig"
diff --git a/conf/machine/include/am62xx.inc b/conf/machine/include/am62xx.inc
new file mode 100644
index 00000000..e8823dd2
--- /dev/null
+++ b/conf/machine/include/am62xx.inc
@@ -0,0 +1,17 @@
+require conf/machine/include/k3.inc
+SOC_FAMILY_append = ":am62xx"
+
+MACHINE_FEATURES += "screen touchscreen"
+
+SERIAL_CONSOLES = "115200;ttyS2"
+SERIAL_CONSOLES_CHECK = "${SERIAL_CONSOLES}"
+
+# AM62 supports multi-certificate images, use the same
+IMAGE_BOOT_FILES = "${IMAGE_BOOT_FILES_MULTI_CERT}"
+
+do_image_wic[mcdepends] = "mc::k3r5:ti-sci-fw:do_deploy"
+do_image_tar[mcdepends] = "mc::k3r5:ti-sci-fw:do_deploy"
+
+TFA_BOARD = "lite"
+OPTEEMACHINE = "k3-am65x"
+OPTEEOUTPUTMACHINE = "k3"
diff --git a/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb b/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb
index 646833a7..099473b4 100644
--- a/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb
+++ b/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb
@@ -6,6 +6,7 @@ DEPENDS_append_j7200-hs-evm-k3r5 = " virtual/bootloader"
DEPENDS_append_j721s2-evm-k3r5 = " virtual/bootloader"
DEPENDS_append_am64xx-evm-k3r5 = " virtual/bootloader"
DEPENDS_append_am64xx-hs-evm-k3r5 = " virtual/bootloader"
+DEPENDS_append_am62xx-evm-k3r5 = " virtual/bootloader"

CLEANBROKEN = "1"
PR = "${INC_PR}.2"
@@ -29,6 +30,7 @@ SYSFW_PREFIX_j7-hs-evm-k3r5-sr1-1 = "ti-fs-firmware"
SYSFW_PREFIX_j7200-evm-k3r5 = "ti-fs-firmware"
SYSFW_PREFIX_j7200-hs-evm-k3r5 = "ti-fs-firmware"
SYSFW_PREFIX_j721s2-evm-k3r5 = "ti-fs-firmware"
+SYSFW_PREFIX_am62xx-evm-k3r5 = "ti-fs-firmware"

SYSFW_SUFFIX ?= "unknown"

@@ -63,6 +65,7 @@ EXTRA_OEMAKE_append_j7200-hs-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-s
EXTRA_OEMAKE_append_j721s2-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""
EXTRA_OEMAKE_append_am64xx-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""
EXTRA_OEMAKE_append_am64xx-hs-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""
+EXTRA_OEMAKE_append_am62xx-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""

do_compile() {
cd ${WORKDIR}/imggen/
@@ -170,4 +173,19 @@ do_deploy_am64xx-hs-evm-k3r5() {
install -m 644 ${SYSFW_TISCI} ${DEPLOYDIR}/
}

+do_install_am62xx-evm-k3r5() {
+ install -d ${D}/boot
+ install -m 644 ${WORKDIR}/imggen/${UBOOT_BINARY} ${D}/boot/${UBOOT_IMAGE}
+ ln -sf ${UBOOT_IMAGE} ${D}/boot/${UBOOT_SYMLINK}
+ ln -sf ${UBOOT_IMAGE} ${D}/boot/${UBOOT_BINARY}
+}
+
+do_deploy_am62xx-evm-k3r5() {
+ install -d ${DEPLOYDIR}
+ install -m 644 ${WORKDIR}/imggen/${UBOOT_BINARY} ${DEPLOYDIR}/${UBOOT_IMAGE}
+ ln -sf ${UBOOT_IMAGE} ${DEPLOYDIR}/${UBOOT_SYMLINK}
+ ln -sf ${UBOOT_IMAGE} ${DEPLOYDIR}/${UBOOT_BINARY}
+ install -m 644 ${SYSFW_TISCI} ${DEPLOYDIR}/
+}
+
addtask deploy before do_build after do_compile
diff --git a/recipes-bsp/u-boot/u-boot-ti.inc b/recipes-bsp/u-boot/u-boot-ti.inc
index 7ed6c5b4..231b7647 100644
--- a/recipes-bsp/u-boot/u-boot-ti.inc
+++ b/recipes-bsp/u-boot/u-boot-ti.inc
@@ -41,6 +41,7 @@ PACKAGECONFIG[dm] = "DM=${STAGING_DIR_HOST}${nonarch_base_libdir}/firmware/pdk-i

PACKAGECONFIG_append_aarch64 = " atf optee"
PACKAGECONFIG_append_j7 = " dm"
+PACKAGECONFIG_append_am62xx = " dm"

COMPATIBLE_MACHINE = "(ti-soc)"

@@ -69,6 +70,7 @@ SPL_UART_BINARY_j7200-hs-evm-k3r5 = "u-boot-spl.bin"
SPL_UART_BINARY_j721s2-evm-k3r5 = "u-boot-spl.bin"
SPL_UART_BINARY_am64xx-evm-k3r5 = "u-boot-spl.bin"
SPL_UART_BINARY_am64xx-hs-evm-k3r5 = "u-boot-spl.bin"
+SPL_UART_BINARY_am62xx-evm-k3r5 = "u-boot-spl.bin"

SPL_UART_IMAGE ?= "${SPL_UART_BINARY}-${MACHINE}-${PV}-${PR}"
SPL_UART_SYMLINK ?= "${SPL_UART_BINARY}-${MACHINE}"
@@ -419,4 +421,9 @@ do_deploy_append_am64xx-hs-evm-k3r5 () {
mv ${DEPLOYDIR}/u-boot-spl.bin ${DEPLOYDIR}/u-boot-spl-r5spl.bin || true
}

+do_deploy_append_am62xx-evm-k3r5 () {
+ mv ${DEPLOYDIR}/tiboot3.bin ${DEPLOYDIR}/tiboot3-r5spl.bin || true
+ mv ${DEPLOYDIR}/u-boot-spl.bin ${DEPLOYDIR}/u-boot-spl-r5spl.bin || true
+}
+
TOOLCHAIN = "gcc"
diff --git a/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb b/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb
index c5852dbd..02e5d665 100644
--- a/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb
+++ b/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb
@@ -19,6 +19,7 @@ PLAT_SFX_j7200-hs-evm = "j7200"
PLAT_SFX_j721s2-evm = "j721s2"
PLAT_SFX_am65xx = "am65xx"
PLAT_SFX_am64xx = "am64xx"
+PLAT_SFX_am62xx = "am62x"

FILESEXTRAPATHS_prepend := "${METATIBASE}/recipes-bsp/ti-sci-fw/files/:"
require recipes-bsp/ti-linux-fw/ti-linux-fw.inc
@@ -50,11 +51,11 @@ DM_FIRMWARE = "ipc_echo_testb_mcu1_0_release_strip.xer5f"

# J7 HS support
do_install_prepend_j7-hs-evm() {
- export TI_SECURE_DEV_PKG=${TI_SECURE_DEV_PKG}
- ( cd ${RTOS_DM_FW_DIR}; \
- mv ${DM_FIRMWARE} ${DM_FIRMWARE}.unsigned; \
- ${TI_SECURE_DEV_PKG}/scripts/secure-binary-image.sh ${DM_FIRMWARE}.unsigned ${DM_FIRMWARE}; \
- )
+ export TI_SECURE_DEV_PKG=${TI_SECURE_DEV_PKG}
+ ( cd ${RTOS_DM_FW_DIR}; \
+ mv ${DM_FIRMWARE} ${DM_FIRMWARE}.unsigned; \
+ ${TI_SECURE_DEV_PKG}/scripts/secure-binary-image.sh ${DM_FIRMWARE}.unsigned ${DM_FIRMWARE}; \
+ )
}

# J7 HS support
@@ -77,6 +78,13 @@ do_install_prepend_am64xx() {
)
}

+# Update the am62xx ipc binaries to be consistent with other platforms
+do_install_prepend_am62xx() {
+ ( cd ${RTOS_IPC_FW_DIR}; \
+ mv am62-mcu-m4f0_0-fw ipc_echo_baremetal_test_mcu2_0_release_strip.xer5f; \
+ )
+}
+
#Install all R5 & DSP ipc echo test binaries in lib/firmware/pdk-ipc, with softlinks up a level
do_install() {

@@ -154,6 +162,13 @@ do_install_am64xx() {
install -m 0644 ${RTOS_IPC_FW_DIR}/ipc_echo_baremetal_test_mcu3_0_release_strip.xer5f ${LEGACY_IPC_FW_DIR}
}

+do_install_am62xx() {
+ install -d ${LEGACY_IPC_FW_DIR}
+ install -m 0644 ${RTOS_IPC_FW_DIR}/ipc_echo_baremetal_test_mcu2_0_release_strip.xer5f ${LEGACY_IPC_FW_DIR}
+ # DM Firmware
+ install -m 0644 ${RTOS_DM_FW_DIR}/ipc_echo_testb_mcu1_0_release_strip.xer5f ${LEGACY_DM_FW_DIR}
+}
+
# Set up names for the firmwares
ALTERNATIVE_${PN}_am65xx = "\
am65x-mcu-r5f0_0-fw \
@@ -167,6 +182,10 @@ ALTERNATIVE_${PN}_am64xx = "\
am64-main-r5f1_1-fw \
am64-mcu-m4f0_0-fw \
"
+ALTERNATIVE_${PN}_am62xx = "\
+ am62-mcu-m4f0_0-fw \
+ am62-main-r5f0_0-fw \
+ "

ALTERNATIVE_${PN}_j7 = "\
j7-mcu-r5f0_0-fw \
@@ -216,6 +235,9 @@ TARGET_MAIN_R5FSS1_0_am64xx = "am64-main-r5f1_0-fw"
TARGET_MAIN_R5FSS1_1_am64xx = "am64-main-r5f1_1-fw"
TARGET_MCU_M4FSS0_0_am64xx = "am64-mcu-m4f0_0-fw"

+TARGET_MAIN_R5FSS0_0_am62xx = "am62-main-r5f0_0-fw"
+TARGET_MCU_M4FSS0_0_am62xx = "am62-mcu-m4f0_0-fw"
+
TARGET_MCU_R5FSS0_0_j7 = "j7-mcu-r5f0_0-fw"
TARGET_MCU_R5FSS0_1_j7 = "j7-mcu-r5f0_1-fw"
TARGET_MAIN_R5FSS0_0_j7 = "j7-main-r5f0_0-fw"
@@ -254,6 +276,9 @@ ALTERNATIVE_LINK_NAME[am64-main-r5f1_0-fw] = "${base_libdir}/firmware/${TARGET_M
ALTERNATIVE_LINK_NAME[am64-main-r5f1_1-fw] = "${base_libdir}/firmware/${TARGET_MAIN_R5FSS1_1}"
ALTERNATIVE_LINK_NAME[am64-mcu-m4f0_0-fw] = "${base_libdir}/firmware/${TARGET_MCU_M4FSS0_0}"

+ALTERNATIVE_LINK_NAME[am62-main-r5f0_0-fw] = "${base_libdir}/firmware/${TARGET_MAIN_R5FSS0_0}"
+ALTERNATIVE_LINK_NAME[am62-mcu-m4f0_0-fw] = "${base_libdir}/firmware/${TARGET_MCU_M4FSS0_0}"
+
ALTERNATIVE_LINK_NAME[j7-mcu-r5f0_0-fw] = "${base_libdir}/firmware/${TARGET_MCU_R5FSS0_0}"
ALTERNATIVE_LINK_NAME[j7-mcu-r5f0_1-fw] = "${base_libdir}/firmware/${TARGET_MCU_R5FSS0_1}"
ALTERNATIVE_LINK_NAME[j7-main-r5f0_0-fw] = "${base_libdir}/firmware/${TARGET_MAIN_R5FSS0_0}"
@@ -289,6 +314,9 @@ ALTERNATIVE_TARGET[am64-main-r5f1_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_e
ALTERNATIVE_TARGET[am64-main-r5f1_1-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_baremetal_test_mcu2_1_release_strip.xer5f"
ALTERNATIVE_TARGET[am64-mcu-m4f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_baremetal_test_mcu3_0_release_strip.xer5f"

+ALTERNATIVE_TARGET[am62-main-r5f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_testb_mcu1_0_release_strip.xer5f"
+ALTERNATIVE_TARGET[am62-mcu-m4f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_baremetal_test_mcu2_0_release_strip.xer5f"
+
ALTERNATIVE_TARGET[j7-mcu-r5f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_testb_mcu1_0_release_strip.xer5f"
ALTERNATIVE_TARGET[j7-mcu-r5f0_1-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_test_mcu1_1_release_strip.xer5f"
ALTERNATIVE_TARGET[j7-main-r5f0_0-fw] = "${base_libdir}/firmware/ethfw/app_remoteswitchcfg_server_strip.xer5f"
--
2.17.1


Re: [dunfell][PATCH v2] ti-graphics: gpu enable and move all platforms to ddk 1.15

Denys Dmytriyenko
 

On Fri, Mar 25, 2022 at 05:36:47PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
On 3/25/22 5:30 PM, Andrew F. Davis via lists.yoctoproject.org wrote:
On 3/25/22 5:06 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 04:54:56PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
On 3/25/22 4:38 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 04:21:38PM -0500, Andrew Davis wrote:
On 3/25/22 3:10 PM, Denys Dmytriyenko wrote:
On Wed, Mar 23, 2022 at 02:37:07PM -0500, Darren Etheridge wrote:
Enable the GPU for am62xx and j721s2 and use IMG DDK 1.15

Migrate Imagination DDK 1.13 to DDK 1.15 for J721e
Overall looks good, please see inline below.
Yeah, I think keeping each series of GPU (SGX, Rogue, Albiorix) in their own
separate recipes would be fine. Or are you suggesting splitting even further
into separate recipes for SGX530 vs SGX540, etc?

I'm suggesting even further. The driver/package for SGX530 is not compatible
and conflicts with the driver package for SGX540. So lets not have a single named
package (ti-sgx-ddk-um) that can have very different contents, that's just confusing.

Oh, and not separate recipes, separate packages, they can all be provided
by the same one or two recipes.

ti-sgx-530-um
ti-sgx-544-um
ti-axe1-16m-um
etc..

Then:

PREFERRED_PROVIDER_virtual/libgles2:am62xx = "ti-axe1-16m-um"
PREFERRED_PROVIDER specifies the build-time dependency, i.e. a recipe.

--
Denys


Re: [dunfell][PATCH v2] ti-graphics: gpu enable and move all platforms to ddk 1.15

Denys Dmytriyenko
 

On Fri, Mar 25, 2022 at 04:54:56PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
On 3/25/22 4:38 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 04:21:38PM -0500, Andrew Davis wrote:
On 3/25/22 3:10 PM, Denys Dmytriyenko wrote:
On Wed, Mar 23, 2022 at 02:37:07PM -0500, Darren Etheridge wrote:
Enable the GPU for am62xx and j721s2 and use IMG DDK 1.15

Migrate Imagination DDK 1.13 to DDK 1.15 for J721e
Overall looks good, please see inline below.

Thinking on this, the mapping between SoC family and the internal names
like "RGX_BVNC" and "TARGET_PRODUCT" are specific to the version of this
driver. For instance in the next DDK I may want the target name to
go from "am62_linux" to "axb_128_linux", I would have to
change things here (update the SRCREV) AND in the machine config.
1. I totally agree that "axb_128_linux" makes more sense than "am62_linux".
2. Changes like that happen very rarely.
3. You can call it PVR_MODEL or PVR_PRODUCT if you want, instead of PVR_SOC.


Mapping here feels like the right spot to me. I'd even argue the same
for OPTEEMACHINE and the like, should go in the optee.bbappends with the
rest of our platform specific recipe fixups, etc.
The number of overrides in the recipe will keep on growing, as each new
platform will need to add own config. That's the whole point of the machine
configuration file to have those defined centrally.

The goal is to have a recipe as machine-agnostic and clean, as possible. Do
not overwhelm it with tons of conditionals like that - any machine-specific
configuration should be set in the machine config file.

Having all the fixups related to a package inside that package's definition sounds
more central to me, and easier to reason about. But I can see the argument both
ways.
Think of it from another perspective - if you keep all machine overrides for
one varibale in the same recipe, a minor change to one specific override there
will make the recipe as "modified" for all platforms and all builds would have
to be redone.

But if that one variable is set in the machine config to a specific value,
changing it for one platform won't affect other platforms and you'd only need
to rebuild that changed platform.

For example - let's add a new .dtbo for am65xx-evm...

In first case you would modify an override in the kernel recipe:
recipes-kernel/linux/linux-ti-staging_5.10.bb:

KERNEL_DEVICETREE_am64xx-evm = "..."
-KERNEL_DEVICETREE_am65xx-evm = "devtree.dtb overlay1.dtbo"
+KERNEL_DEVICETREE_am65xx-evm = "devtree.dtb overlay1.dtbo overlay2.dtbo"
KERNEL_DEVICETREE_j721e-evm = "..."

So, you modified the kernel recipes, so now all platforms would have to
rebuild the kernel and everything that depends on it. With all the variants
(RT, non-RT, debug), brands and configs (nightly, RC, etc), that ends up in
a lot of rebuilds in the farm (could be hundreds of rebuilds, if you count
all permutations)!

In the second case, the .dtbo is added in the machine config:
conf/machine/am65xx-evm.conf:
-KERNEL_DEVICETREE = "devtree.dtb overlay1.dtbo"
+KERNEL_DEVICETREE = "devtree.dtb overlay1.dtbo overlay2.dtbo"

And the kernel recipe wasn't touched, so only am65xx-evm needs to be rebuilt.
Even with permutations, it's just several rebuilds of the same platform.

The other point is that changes to the same variable more often happen one
platform at a time (add a .dtbo, change defconfig or add a config fragment,
even add a new platform), instead of changing globally for all platforms at
the same time...


PS. There are some advanced Yocto techniques to remedy the above rebuilding
of dependency tree to some extent, such as hash equivalence and such, but
that's still a bit cutting edge, somewhat unstable and might not be ready for
production yet.

--
Denys


Re: [master][PATCH 4/4] ti-sgx-ddk-um: only the am65xx member of the k3 family is supported

Denys Dmytriyenko
 

On Fri, Mar 25, 2022 at 01:41:51PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
The AM65xx is the only member of the K3 family with an SGX GPU.
Be specific here to avoid confusion.

Signed-off-by: Andrew Davis <afd@...>
Tested-by: Denys Dmytriyenko <denys@...>


Re: [master][PATCH 3/4] ti-img-rogue-umlibs: only the j721e SoC is currently supported

Denys Dmytriyenko
 

On Fri, Mar 25, 2022 at 01:41:50PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
There are now three SoCs in the J7 family, but only the j721e variant
is currently supported. Be specific here.

Signed-off-by: Andrew Davis <afd@...>
Tested-by: Denys Dmytriyenko <denys@...>


Re: [master][PATCH 2/4] meta-ti-bsp: add SoC families for the J7 SoCs

Denys Dmytriyenko
 

On Fri, Mar 25, 2022 at 01:41:49PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
This allows us to be more specific around what SoCs we support and
lets us add features based on the SoC family not just at the EVM or
whole J7family level.

Signed-off-by: Andrew Davis <afd@...>
Tested-by: Denys Dmytriyenko <denys@...>


Re: [master][PATCH 1/4] meta-ti: rename j7-evm to j721e-evm

Denys Dmytriyenko
 

On Fri, Mar 25, 2022 at 01:41:48PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
In many places we use "j7" the family when we should be using a
specific SoC or EVM and vice-versa. For instance when including
graphics drivers we add for all "j7" family, but what we really
want is only for some specific j7 SoC.

First step in untangling this is to make it clear that there is
no SoC called j7. There is a SoC called j721e with a j721e-evm.

Fix up this naming here.

Signed-off-by: Andrew Davis <afd@...>
Tested-by: Denys Dmytriyenko <denys@...>


Re: [master][PATCH 1/4] meta-ti: rename j7-evm to j721e-evm

Denys Dmytriyenko
 

On Fri, Mar 25, 2022 at 02:38:55PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
On 3/25/22 2:23 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 01:41:48PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
In many places we use "j7" the family when we should be using a
specific SoC or EVM and vice-versa. For instance when including
graphics drivers we add for all "j7" family, but what we really
want is only for some specific j7 SoC.

First step in untangling this is to make it clear that there is
no SoC called j7. There is a SoC called j721e with a j721e-evm.

Fix up this naming here.
Heh, I was actually thinking of finally making such change myself lately! :)

My main concern was about breaking downstream users of meta-ti who builds on
top of j7-evm platform. But it is probably a good time to get it into master
now, as recent layer restructuring already required downstream changes and
adjustments.
There are also some external docs on this that need updated but I
can take a lead on that.


Signed-off-by: Andrew Davis <afd@...>
I looked over the changes in both patchsets and they seem fine.
I'm going to do a quick test locally though.
Thanks, that would be good, I have to admit my setup is not all the
way back together yet so my testing here was very limited..
Ok, I was finally able to build all K3 platforms and couple legacy platforms
with these patches aplied locally - everything seems fine!

--
Regards,
Denys Dmytriyenko <denis@...>
PGP: 0x420902729A92C964 - https://denix.org/0x420902729A92C964
Fingerprint: 25FC E4A5 8A72 2F69 1186 6D76 4209 0272 9A92 C964


Re: [dunfell][PATCH v2] ti-graphics: gpu enable and move all platforms to ddk 1.15

Andrew Davis
 

On 3/25/22 5:30 PM, Andrew F. Davis via lists.yoctoproject.org wrote:
On 3/25/22 5:06 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 04:54:56PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
On 3/25/22 4:38 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 04:21:38PM -0500, Andrew Davis wrote:
On 3/25/22 3:10 PM, Denys Dmytriyenko wrote:
On Wed, Mar 23, 2022 at 02:37:07PM -0500, Darren Etheridge wrote:
Enable the GPU for am62xx and j721s2 and use IMG DDK 1.15

Migrate Imagination DDK 1.13 to DDK 1.15 for J721e
Overall looks good, please see inline below.


Signed-off-by: Darren Etheridge <detheridge@...>
---

rename from recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
rename to recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
index a05de0f2..fbff6c51 100644
--- a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
+++ b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
@@ -7,17 +7,17 @@ inherit module features_check
  REQUIRED_MACHINE_FEATURES = "gpu"
-MACHINE_KERNEL_PR_append = "b"
+MACHINE_KERNEL_PR_append = "a"
  PR = "${MACHINE_KERNEL_PR}"
  PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"
  DEPENDS = "virtual/kernel"
  PROVIDES = "virtual/gpudriver"
-BRANCH = "1.13-5776728/linux-k5.10"
+BRANCH = "linuxws/dunfell/k5.10/${PV}"
  SRC_URI = " \
      git://git.ti.com/graphics/ti-img-rogue-driver.git;branch=${BRANCH} \
@@ -26,15 +26,19 @@ SRC_URI = " \
  S = "${WORKDIR}/git"
-SRCREV = "35a25875ae8738f82c7cabc6b077ef992b0cca84"
+SRCREV = "ee0674adccac16f5b2f7cb8d5d05948706080cb5"
-PVR_SOC = "j721e_linux"
I was actually thinking of keeping PVR_SOC variable and moving it to
corresponding machine configs.

PVR_SOC is a bit of a legacy name, especially since PVR is now IMG.
PVR or PowerVR name is still used as an overall umbrella for all of
Imagination's graphics, vision and AI chips, including SGX and Rogue/RGX:
https://en.wikipedia.org/wiki/PowerVR

On the wiki page:

These GPUs are no longer called PowerVR, they are called IMG.[58]
For their next gen GPUs they are distancing themselves from the PVR name,
the GPU in AM62xx is one such next gen GPU, so it's already not correct here
as is.
So, then why AM62xx is being added to Rogue driver/DDK? Should there be a
separate Albiorix driver and DDK then?
We asked IMG very nicely to not fork the DDK for each new gen of device (like
what happened with SGX -> Rogue), so now we have he same driver code base
supporting multiple generations of GPU. The name "Rogue" just stuck around.
We should probably rename some of this stuff to also be more generic.


Thinking on this, the mapping between SoC family and the internal names
like "RGX_BVNC" and "TARGET_PRODUCT" are specific to the version of this
driver. For instance in the next DDK I may want the target name to
go from "am62_linux" to "axb_128_linux", I would have to
change things here (update the SRCREV) AND in the machine config.
1. I totally agree that "axb_128_linux" makes more sense than "am62_linux".
2. Changes like that happen very rarely.
3. You can call it PVR_MODEL or PVR_PRODUCT if you want, instead of PVR_SOC.


Mapping here feels like the right spot to me. I'd even argue the same
for OPTEEMACHINE and the like, should go in the optee.bbappends with the
rest of our platform specific recipe fixups, etc.
The number of overrides in the recipe will keep on growing, as each new
platform will need to add own config. That's the whole point of the machine
configuration file to have those defined centrally.

The goal is to have a recipe as machine-agnostic and clean, as possible. Do
not overwhelm it with tons of conditionals like that - any machine-specific
configuration should be set in the machine config file.

Having all the fixups related to a package inside that package's definition sounds
more central to me, and easier to reason about. But I can see the argument both
ways.

Maybe the better solution would be to splitup this(and the SGX) recipe. So we
get a package per GPU type. It's already how the bins are organized/shipped. Then
we just pick the right GPU package for our SoC in arago-prefs.inc. (again like
we already do to select between SGX/RGX)
Yeah, I think keeping each series of GPU (SGX, Rogue, Albiorix) in their own
separate recipes would be fine. Or are you suggesting splitting even further
into separate recipes for SGX530 vs SGX540, etc?
I'm suggesting even further. The driver/package for SGX530 is not compatible
and conflicts with the driver package for SGX540. So lets not have a single named
package (ti-sgx-ddk-um) that can have very different contents, that's just confusing.

Oh, and not separate recipes, separate packages, they can all be provided
by the same one or two recipes.

ti-sgx-530-um
ti-sgx-544-um
ti-axe1-16m-um
etc..

Then:

PREFERRED_PROVIDER_virtual/libgles2:am62xx = "ti-axe1-16m-um"
...

Andrew


Andrew


Re: [dunfell][PATCH v2] ti-graphics: gpu enable and move all platforms to ddk 1.15

Andrew Davis
 

On 3/25/22 5:06 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 04:54:56PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
On 3/25/22 4:38 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 04:21:38PM -0500, Andrew Davis wrote:
On 3/25/22 3:10 PM, Denys Dmytriyenko wrote:
On Wed, Mar 23, 2022 at 02:37:07PM -0500, Darren Etheridge wrote:
Enable the GPU for am62xx and j721s2 and use IMG DDK 1.15

Migrate Imagination DDK 1.13 to DDK 1.15 for J721e
Overall looks good, please see inline below.


Signed-off-by: Darren Etheridge <detheridge@...>
---

rename from recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
rename to recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
index a05de0f2..fbff6c51 100644
--- a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
+++ b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
@@ -7,17 +7,17 @@ inherit module features_check
REQUIRED_MACHINE_FEATURES = "gpu"
-MACHINE_KERNEL_PR_append = "b"
+MACHINE_KERNEL_PR_append = "a"
PR = "${MACHINE_KERNEL_PR}"
PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"
DEPENDS = "virtual/kernel"
PROVIDES = "virtual/gpudriver"
-BRANCH = "1.13-5776728/linux-k5.10"
+BRANCH = "linuxws/dunfell/k5.10/${PV}"
SRC_URI = " \
git://git.ti.com/graphics/ti-img-rogue-driver.git;branch=${BRANCH} \
@@ -26,15 +26,19 @@ SRC_URI = " \
S = "${WORKDIR}/git"
-SRCREV = "35a25875ae8738f82c7cabc6b077ef992b0cca84"
+SRCREV = "ee0674adccac16f5b2f7cb8d5d05948706080cb5"
-PVR_SOC = "j721e_linux"
I was actually thinking of keeping PVR_SOC variable and moving it to
corresponding machine configs.

PVR_SOC is a bit of a legacy name, especially since PVR is now IMG.
PVR or PowerVR name is still used as an overall umbrella for all of
Imagination's graphics, vision and AI chips, including SGX and Rogue/RGX:
https://en.wikipedia.org/wiki/PowerVR

On the wiki page:

These GPUs are no longer called PowerVR, they are called IMG.[58]
For their next gen GPUs they are distancing themselves from the PVR name,
the GPU in AM62xx is one such next gen GPU, so it's already not correct here
as is.
So, then why AM62xx is being added to Rogue driver/DDK? Should there be a
separate Albiorix driver and DDK then?

We asked IMG very nicely to not fork the DDK for each new gen of device (like
what happened with SGX -> Rogue), so now we have he same driver code base
supporting multiple generations of GPU. The name "Rogue" just stuck around.
We should probably rename some of this stuff to also be more generic.



Thinking on this, the mapping between SoC family and the internal names
like "RGX_BVNC" and "TARGET_PRODUCT" are specific to the version of this
driver. For instance in the next DDK I may want the target name to
go from "am62_linux" to "axb_128_linux", I would have to
change things here (update the SRCREV) AND in the machine config.
1. I totally agree that "axb_128_linux" makes more sense than "am62_linux".
2. Changes like that happen very rarely.
3. You can call it PVR_MODEL or PVR_PRODUCT if you want, instead of PVR_SOC.


Mapping here feels like the right spot to me. I'd even argue the same
for OPTEEMACHINE and the like, should go in the optee.bbappends with the
rest of our platform specific recipe fixups, etc.
The number of overrides in the recipe will keep on growing, as each new
platform will need to add own config. That's the whole point of the machine
configuration file to have those defined centrally.

The goal is to have a recipe as machine-agnostic and clean, as possible. Do
not overwhelm it with tons of conditionals like that - any machine-specific
configuration should be set in the machine config file.

Having all the fixups related to a package inside that package's definition sounds
more central to me, and easier to reason about. But I can see the argument both
ways.

Maybe the better solution would be to splitup this(and the SGX) recipe. So we
get a package per GPU type. It's already how the bins are organized/shipped. Then
we just pick the right GPU package for our SoC in arago-prefs.inc. (again like
we already do to select between SGX/RGX)
Yeah, I think keeping each series of GPU (SGX, Rogue, Albiorix) in their own
separate recipes would be fine. Or are you suggesting splitting even further
into separate recipes for SGX530 vs SGX540, etc?

I'm suggesting even further. The driver/package for SGX530 is not compatible
and conflicts with the driver package for SGX540. So lets not have a single named
package (ti-sgx-ddk-um) that can have very different contents, that's just confusing.

Andrew


Re: [dunfell][PATCH v2] ti-graphics: gpu enable and move all platforms to ddk 1.15

Denys Dmytriyenko
 

On Fri, Mar 25, 2022 at 04:54:56PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
On 3/25/22 4:38 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 04:21:38PM -0500, Andrew Davis wrote:
On 3/25/22 3:10 PM, Denys Dmytriyenko wrote:
On Wed, Mar 23, 2022 at 02:37:07PM -0500, Darren Etheridge wrote:
Enable the GPU for am62xx and j721s2 and use IMG DDK 1.15

Migrate Imagination DDK 1.13 to DDK 1.15 for J721e
Overall looks good, please see inline below.


Signed-off-by: Darren Etheridge <detheridge@...>
---

rename from recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
rename to recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
index a05de0f2..fbff6c51 100644
--- a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
+++ b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
@@ -7,17 +7,17 @@ inherit module features_check
REQUIRED_MACHINE_FEATURES = "gpu"
-MACHINE_KERNEL_PR_append = "b"
+MACHINE_KERNEL_PR_append = "a"
PR = "${MACHINE_KERNEL_PR}"
PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"
DEPENDS = "virtual/kernel"
PROVIDES = "virtual/gpudriver"
-BRANCH = "1.13-5776728/linux-k5.10"
+BRANCH = "linuxws/dunfell/k5.10/${PV}"
SRC_URI = " \
git://git.ti.com/graphics/ti-img-rogue-driver.git;branch=${BRANCH} \
@@ -26,15 +26,19 @@ SRC_URI = " \
S = "${WORKDIR}/git"
-SRCREV = "35a25875ae8738f82c7cabc6b077ef992b0cca84"
+SRCREV = "ee0674adccac16f5b2f7cb8d5d05948706080cb5"
-PVR_SOC = "j721e_linux"
I was actually thinking of keeping PVR_SOC variable and moving it to
corresponding machine configs.

PVR_SOC is a bit of a legacy name, especially since PVR is now IMG.
PVR or PowerVR name is still used as an overall umbrella for all of
Imagination's graphics, vision and AI chips, including SGX and Rogue/RGX:
https://en.wikipedia.org/wiki/PowerVR

On the wiki page:

These GPUs are no longer called PowerVR, they are called IMG.[58]
For their next gen GPUs they are distancing themselves from the PVR name,
the GPU in AM62xx is one such next gen GPU, so it's already not correct here
as is.
So, then why AM62xx is being added to Rogue driver/DDK? Should there be a
separate Albiorix driver and DDK then?


Thinking on this, the mapping between SoC family and the internal names
like "RGX_BVNC" and "TARGET_PRODUCT" are specific to the version of this
driver. For instance in the next DDK I may want the target name to
go from "am62_linux" to "axb_128_linux", I would have to
change things here (update the SRCREV) AND in the machine config.
1. I totally agree that "axb_128_linux" makes more sense than "am62_linux".
2. Changes like that happen very rarely.
3. You can call it PVR_MODEL or PVR_PRODUCT if you want, instead of PVR_SOC.


Mapping here feels like the right spot to me. I'd even argue the same
for OPTEEMACHINE and the like, should go in the optee.bbappends with the
rest of our platform specific recipe fixups, etc.
The number of overrides in the recipe will keep on growing, as each new
platform will need to add own config. That's the whole point of the machine
configuration file to have those defined centrally.

The goal is to have a recipe as machine-agnostic and clean, as possible. Do
not overwhelm it with tons of conditionals like that - any machine-specific
configuration should be set in the machine config file.

Having all the fixups related to a package inside that package's definition sounds
more central to me, and easier to reason about. But I can see the argument both
ways.

Maybe the better solution would be to splitup this(and the SGX) recipe. So we
get a package per GPU type. It's already how the bins are organized/shipped. Then
we just pick the right GPU package for our SoC in arago-prefs.inc. (again like
we already do to select between SGX/RGX)
Yeah, I think keeping each series of GPU (SGX, Rogue, Albiorix) in their own
separate recipes would be fine. Or are you suggesting splitting even further
into separate recipes for SGX530 vs SGX540, etc?

--
Regards,
Denys Dmytriyenko <denis@...>
PGP: 0x420902729A92C964 - https://denix.org/0x420902729A92C964
Fingerprint: 25FC E4A5 8A72 2F69 1186 6D76 4209 0272 9A92 C964


Re: [dunfell][PATCH v2] ti-graphics: gpu enable and move all platforms to ddk 1.15

Andrew Davis
 

On 3/25/22 4:38 PM, Denys Dmytriyenko wrote:
On Fri, Mar 25, 2022 at 04:21:38PM -0500, Andrew Davis wrote:
On 3/25/22 3:10 PM, Denys Dmytriyenko wrote:
On Wed, Mar 23, 2022 at 02:37:07PM -0500, Darren Etheridge wrote:
Enable the GPU for am62xx and j721s2 and use IMG DDK 1.15

Migrate Imagination DDK 1.13 to DDK 1.15 for J721e
Overall looks good, please see inline below.


Signed-off-by: Darren Etheridge <detheridge@...>
---

No changes in the content of the patch, however I regenerated it with the
similarity threshold reduced as requested by Denys.

conf/machine/am62xx-evm.conf | 2 ++
conf/machine/j721s2-evm.conf | 2 ++
...bb => ti-img-rogue-driver_1.15.6133109.bb} | 20 +++++++++++--------
...bb => ti-img-rogue-umlibs_1.15.6133109.bb} | 13 ++++++------
4 files changed, 23 insertions(+), 14 deletions(-)
rename recipes-bsp/powervr-drivers/{ti-img-rogue-driver_1.13.5776728.bb => ti-img-rogue-driver_1.15.6133109.bb} (48%)
rename recipes-graphics/libgles/{ti-img-rogue-umlibs_1.13.5776728.bb => ti-img-rogue-umlibs_1.15.6133109.bb} (84%)

diff --git a/conf/machine/am62xx-evm.conf b/conf/machine/am62xx-evm.conf
index 600abb58..086e40e4 100644
--- a/conf/machine/am62xx-evm.conf
+++ b/conf/machine/am62xx-evm.conf
@@ -4,6 +4,8 @@
require conf/machine/include/am62xx.inc
+MACHINE_FEATURES += "gpu"
+
KERNEL_DEVICETREE = " \
ti/k3-am625-sk.dtb \
ti/k3-am625-sk-lpmdemo.dtb \
diff --git a/conf/machine/j721s2-evm.conf b/conf/machine/j721s2-evm.conf
index 82fd33da..e5ed0b73 100644
--- a/conf/machine/j721s2-evm.conf
+++ b/conf/machine/j721s2-evm.conf
@@ -4,6 +4,8 @@
require conf/machine/include/j7.inc
+MACHINE_FEATURES += "gpu"
+
SERIAL_CONSOLES = "115200;ttyS10"
SERIAL_CONSOLES_CHECK = "${SERIAL_CONSOLES}"
TFA_K3_USART = "0x8"
diff --git a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
similarity index 48%
rename from recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
rename to recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
index a05de0f2..fbff6c51 100644
--- a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
+++ b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
@@ -7,17 +7,17 @@ inherit module features_check
REQUIRED_MACHINE_FEATURES = "gpu"
-MACHINE_KERNEL_PR_append = "b"
+MACHINE_KERNEL_PR_append = "a"
PR = "${MACHINE_KERNEL_PR}"
PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"
DEPENDS = "virtual/kernel"
PROVIDES = "virtual/gpudriver"
-BRANCH = "1.13-5776728/linux-k5.10"
+BRANCH = "linuxws/dunfell/k5.10/${PV}"
SRC_URI = " \
git://git.ti.com/graphics/ti-img-rogue-driver.git;branch=${BRANCH} \
@@ -26,15 +26,19 @@ SRC_URI = " \
S = "${WORKDIR}/git"
-SRCREV = "35a25875ae8738f82c7cabc6b077ef992b0cca84"
+SRCREV = "ee0674adccac16f5b2f7cb8d5d05948706080cb5"
-PVR_SOC = "j721e_linux"
I was actually thinking of keeping PVR_SOC variable and moving it to
corresponding machine configs.

PVR_SOC is a bit of a legacy name, especially since PVR is now IMG.
PVR or PowerVR name is still used as an overall umbrella for all of
Imagination's graphics, vision and AI chips, including SGX and Rogue/RGX:
https://en.wikipedia.org/wiki/PowerVR

On the wiki page:

These GPUs are no longer called PowerVR, they are called IMG.[58]
For their next gen GPUs they are distancing themselves from the PVR name,
the GPU in AM62xx is one such next gen GPU, so it's already not correct here
as is.



Thinking on this, the mapping between SoC family and the internal names
like "RGX_BVNC" and "TARGET_PRODUCT" are specific to the version of this
driver. For instance in the next DDK I may want the target name to
go from "am62_linux" to "axb_128_linux", I would have to
change things here (update the SRCREV) AND in the machine config.
1. I totally agree that "axb_128_linux" makes more sense than "am62_linux".
2. Changes like that happen very rarely.
3. You can call it PVR_MODEL or PVR_PRODUCT if you want, instead of PVR_SOC.

Mapping here feels like the right spot to me. I'd even argue the same
for OPTEEMACHINE and the like, should go in the optee.bbappends with the
rest of our platform specific recipe fixups, etc.
The number of overrides in the recipe will keep on growing, as each new
platform will need to add own config. That's the whole point of the machine
configuration file to have those defined centrally.
The goal is to have a recipe as machine-agnostic and clean, as possible. Do
not overwhelm it with tons of conditionals like that - any machine-specific
configuration should be set in the machine config file.

Having all the fixups related to a package inside that package's definition sounds
more central to me, and easier to reason about. But I can see the argument both
ways.

Maybe the better solution would be to splitup this(and the SGX) recipe. So we
get a package per GPU type. It's already how the bins are organized/shipped. Then
we just pick the right GPU package for our SoC in arago-prefs.inc. (again like
we already do to select between SGX/RGX)

Andrew



-PVR_BVNC = "22.104.208.318"
+TARGET_PRODUCT_j7-evm = "j721e_linux"
+TARGET_PRODUCT_j721s2-evm = "j721s2_linux"

The driver depends on the SoC, not the EVM. s/j721s2-evm/j721s2
I know you cant do that in dunfell but if my other series gets into
main it should be fixed there, where we have a SOC_FAMILY for these
SoCs.

Andrew


+TARGET_PRODUCT_am62xx = "am62_linux"
E.g. instead of these 3 overrides in the recipe, those 3 machines will be
setting their respective PVR_SOC variables, which is more descriptive than
TARGET_PRODUCT.

Similar to how machine configs already set KERNEL_DEVICETREE, UBOOT_MACHINE,
TFA_PLATFORM or OPTEEMACHINE.

I know SGX been using TARGET_PRODUCT historically, but outside of the recipe
it won't make much sense.

But it may be too disruptive for Dunfell at this point. I can do such change
in master when porting this patch over on top of Andrew's changes.


+TARGET_BVNC_j7-evm = "22.104.208.318"
+TARGET_BVNC_j721s2-evm = "36.53.104.796"
+TARGET_BVNC_am62xx = "33.15.11.3"
PVR_BUILD = "release"
PVR_WS = "wayland"
-EXTRA_OEMAKE += 'KERNELDIR="${STAGING_KERNEL_DIR}" RGX_BVNC=${PVR_BVNC} BUILD=${PVR_BUILD} PVR_BUILD_DIR=${PVR_SOC} WINDOW_SYSTEM=${PVR_WS}'
+EXTRA_OEMAKE += 'KERNELDIR="${STAGING_KERNEL_DIR}" RGX_BVNC=${TARGET_BVNC} BUILD=${PVR_BUILD} PVR_BUILD_DIR=${TARGET_PRODUCT} WINDOW_SYSTEM=${PVR_WS}'
do_install() {
- make -C ${STAGING_KERNEL_DIR} M=${B}/binary_${PVR_SOC}_${PVR_WS}_${PVR_BUILD}/target_aarch64/kbuild INSTALL_MOD_PATH=${D}${root_prefix} PREFIX=${STAGING_DIR_HOST} modules_install
+ make -C ${STAGING_KERNEL_DIR} M=${B}/binary_${TARGET_PRODUCT}_${PVR_WS}_${PVR_BUILD}/target_aarch64/kbuild INSTALL_MOD_PATH=${D}${root_prefix} PREFIX=${STAGING_DIR_HOST} modules_install
}
diff --git a/recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb b/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
similarity index 84%
rename from recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb
rename to recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
index 5194015e..e00dce99 100644
--- a/recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb
+++ b/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
@@ -8,17 +8,18 @@ inherit features_check
REQUIRED_MACHINE_FEATURES = "gpu"
PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"
-PR = "r3"
+PR = "r1"
BRANCH = "linuxws/dunfell/k5.10/${PV}"
SRC_URI = "git://git.ti.com/graphics/ti-img-rogue-umlibs.git;branch=${BRANCH}"
+SRCREV = "47c3ffc44f2881397d45c8a2b5dfa7d6c58b79fb"
-SRCREV = "5ef38353c38d921a65ea6df75c7b6ce710b66034"
-
-PVR_SOC ?= "j721e_linux"
+TARGET_PRODUCT_j7-evm = "j721e_linux"
+TARGET_PRODUCT_j721s2-evm = "j721s2_linux"
+TARGET_PRODUCT_am62xx = "am62_linux"
Same here.


PVR_BUILD ?= "release"
PVR_WS = "wayland"
@@ -50,7 +51,7 @@ RRECOMMENDS_${PN} += "ti-img-rogue-driver"
S = "${WORKDIR}/git"
do_install () {
- oe_runmake install DESTDIR=${D} TARGET_PRODUCT=${PVR_SOC} BUILD=${PVR_BUILD} WINDOW_SYSTEM=${PVR_WS}
+ oe_runmake install DESTDIR=${D} TARGET_PRODUCT=${TARGET_PRODUCT} BUILD=${PVR_BUILD} WINDOW_SYSTEM=${PVR_WS}
chown -R root:root ${D}
}
--
2.17.1


Re: [dunfell][PATCH v2] ti-graphics: gpu enable and move all platforms to ddk 1.15

Denys Dmytriyenko
 

On Fri, Mar 25, 2022 at 04:21:38PM -0500, Andrew Davis wrote:
On 3/25/22 3:10 PM, Denys Dmytriyenko wrote:
On Wed, Mar 23, 2022 at 02:37:07PM -0500, Darren Etheridge wrote:
Enable the GPU for am62xx and j721s2 and use IMG DDK 1.15

Migrate Imagination DDK 1.13 to DDK 1.15 for J721e
Overall looks good, please see inline below.


Signed-off-by: Darren Etheridge <detheridge@...>
---

No changes in the content of the patch, however I regenerated it with the
similarity threshold reduced as requested by Denys.

conf/machine/am62xx-evm.conf | 2 ++
conf/machine/j721s2-evm.conf | 2 ++
...bb => ti-img-rogue-driver_1.15.6133109.bb} | 20 +++++++++++--------
...bb => ti-img-rogue-umlibs_1.15.6133109.bb} | 13 ++++++------
4 files changed, 23 insertions(+), 14 deletions(-)
rename recipes-bsp/powervr-drivers/{ti-img-rogue-driver_1.13.5776728.bb => ti-img-rogue-driver_1.15.6133109.bb} (48%)
rename recipes-graphics/libgles/{ti-img-rogue-umlibs_1.13.5776728.bb => ti-img-rogue-umlibs_1.15.6133109.bb} (84%)

diff --git a/conf/machine/am62xx-evm.conf b/conf/machine/am62xx-evm.conf
index 600abb58..086e40e4 100644
--- a/conf/machine/am62xx-evm.conf
+++ b/conf/machine/am62xx-evm.conf
@@ -4,6 +4,8 @@
require conf/machine/include/am62xx.inc
+MACHINE_FEATURES += "gpu"
+
KERNEL_DEVICETREE = " \
ti/k3-am625-sk.dtb \
ti/k3-am625-sk-lpmdemo.dtb \
diff --git a/conf/machine/j721s2-evm.conf b/conf/machine/j721s2-evm.conf
index 82fd33da..e5ed0b73 100644
--- a/conf/machine/j721s2-evm.conf
+++ b/conf/machine/j721s2-evm.conf
@@ -4,6 +4,8 @@
require conf/machine/include/j7.inc
+MACHINE_FEATURES += "gpu"
+
SERIAL_CONSOLES = "115200;ttyS10"
SERIAL_CONSOLES_CHECK = "${SERIAL_CONSOLES}"
TFA_K3_USART = "0x8"
diff --git a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
similarity index 48%
rename from recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
rename to recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
index a05de0f2..fbff6c51 100644
--- a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
+++ b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
@@ -7,17 +7,17 @@ inherit module features_check
REQUIRED_MACHINE_FEATURES = "gpu"
-MACHINE_KERNEL_PR_append = "b"
+MACHINE_KERNEL_PR_append = "a"
PR = "${MACHINE_KERNEL_PR}"
PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"
DEPENDS = "virtual/kernel"
PROVIDES = "virtual/gpudriver"
-BRANCH = "1.13-5776728/linux-k5.10"
+BRANCH = "linuxws/dunfell/k5.10/${PV}"
SRC_URI = " \
git://git.ti.com/graphics/ti-img-rogue-driver.git;branch=${BRANCH} \
@@ -26,15 +26,19 @@ SRC_URI = " \
S = "${WORKDIR}/git"
-SRCREV = "35a25875ae8738f82c7cabc6b077ef992b0cca84"
+SRCREV = "ee0674adccac16f5b2f7cb8d5d05948706080cb5"
-PVR_SOC = "j721e_linux"
I was actually thinking of keeping PVR_SOC variable and moving it to
corresponding machine configs.

PVR_SOC is a bit of a legacy name, especially since PVR is now IMG.
PVR or PowerVR name is still used as an overall umbrella for all of
Imagination's graphics, vision and AI chips, including SGX and Rogue/RGX:
https://en.wikipedia.org/wiki/PowerVR


Thinking on this, the mapping between SoC family and the internal names
like "RGX_BVNC" and "TARGET_PRODUCT" are specific to the version of this
driver. For instance in the next DDK I may want the target name to
go from "am62_linux" to "axb_128_linux", I would have to
change things here (update the SRCREV) AND in the machine config.
1. I totally agree that "axb_128_linux" makes more sense than "am62_linux".
2. Changes like that happen very rarely.
3. You can call it PVR_MODEL or PVR_PRODUCT if you want, instead of PVR_SOC.


Mapping here feels like the right spot to me. I'd even argue the same
for OPTEEMACHINE and the like, should go in the optee.bbappends with the
rest of our platform specific recipe fixups, etc.
The number of overrides in the recipe will keep on growing, as each new
platform will need to add own config. That's the whole point of the machine
configuration file to have those defined centrally.

The goal is to have a recipe as machine-agnostic and clean, as possible. Do
not overwhelm it with tons of conditionals like that - any machine-specific
configuration should be set in the machine config file.


-PVR_BVNC = "22.104.208.318"
+TARGET_PRODUCT_j7-evm = "j721e_linux"
+TARGET_PRODUCT_j721s2-evm = "j721s2_linux"

The driver depends on the SoC, not the EVM. s/j721s2-evm/j721s2
I know you cant do that in dunfell but if my other series gets into
main it should be fixed there, where we have a SOC_FAMILY for these
SoCs.

Andrew


+TARGET_PRODUCT_am62xx = "am62_linux"
E.g. instead of these 3 overrides in the recipe, those 3 machines will be
setting their respective PVR_SOC variables, which is more descriptive than
TARGET_PRODUCT.

Similar to how machine configs already set KERNEL_DEVICETREE, UBOOT_MACHINE,
TFA_PLATFORM or OPTEEMACHINE.

I know SGX been using TARGET_PRODUCT historically, but outside of the recipe
it won't make much sense.

But it may be too disruptive for Dunfell at this point. I can do such change
in master when porting this patch over on top of Andrew's changes.


+TARGET_BVNC_j7-evm = "22.104.208.318"
+TARGET_BVNC_j721s2-evm = "36.53.104.796"
+TARGET_BVNC_am62xx = "33.15.11.3"
PVR_BUILD = "release"
PVR_WS = "wayland"
-EXTRA_OEMAKE += 'KERNELDIR="${STAGING_KERNEL_DIR}" RGX_BVNC=${PVR_BVNC} BUILD=${PVR_BUILD} PVR_BUILD_DIR=${PVR_SOC} WINDOW_SYSTEM=${PVR_WS}'
+EXTRA_OEMAKE += 'KERNELDIR="${STAGING_KERNEL_DIR}" RGX_BVNC=${TARGET_BVNC} BUILD=${PVR_BUILD} PVR_BUILD_DIR=${TARGET_PRODUCT} WINDOW_SYSTEM=${PVR_WS}'
do_install() {
- make -C ${STAGING_KERNEL_DIR} M=${B}/binary_${PVR_SOC}_${PVR_WS}_${PVR_BUILD}/target_aarch64/kbuild INSTALL_MOD_PATH=${D}${root_prefix} PREFIX=${STAGING_DIR_HOST} modules_install
+ make -C ${STAGING_KERNEL_DIR} M=${B}/binary_${TARGET_PRODUCT}_${PVR_WS}_${PVR_BUILD}/target_aarch64/kbuild INSTALL_MOD_PATH=${D}${root_prefix} PREFIX=${STAGING_DIR_HOST} modules_install
}
diff --git a/recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb b/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
similarity index 84%
rename from recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb
rename to recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
index 5194015e..e00dce99 100644
--- a/recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb
+++ b/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
@@ -8,17 +8,18 @@ inherit features_check
REQUIRED_MACHINE_FEATURES = "gpu"
PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"
-PR = "r3"
+PR = "r1"
BRANCH = "linuxws/dunfell/k5.10/${PV}"
SRC_URI = "git://git.ti.com/graphics/ti-img-rogue-umlibs.git;branch=${BRANCH}"
+SRCREV = "47c3ffc44f2881397d45c8a2b5dfa7d6c58b79fb"
-SRCREV = "5ef38353c38d921a65ea6df75c7b6ce710b66034"
-
-PVR_SOC ?= "j721e_linux"
+TARGET_PRODUCT_j7-evm = "j721e_linux"
+TARGET_PRODUCT_j721s2-evm = "j721s2_linux"
+TARGET_PRODUCT_am62xx = "am62_linux"
Same here.


PVR_BUILD ?= "release"
PVR_WS = "wayland"
@@ -50,7 +51,7 @@ RRECOMMENDS_${PN} += "ti-img-rogue-driver"
S = "${WORKDIR}/git"
do_install () {
- oe_runmake install DESTDIR=${D} TARGET_PRODUCT=${PVR_SOC} BUILD=${PVR_BUILD} WINDOW_SYSTEM=${PVR_WS}
+ oe_runmake install DESTDIR=${D} TARGET_PRODUCT=${TARGET_PRODUCT} BUILD=${PVR_BUILD} WINDOW_SYSTEM=${PVR_WS}
chown -R root:root ${D}
}
--
2.17.1
--
Regards,
Denys Dmytriyenko <denis@...>
PGP: 0x420902729A92C964 - https://denix.org/0x420902729A92C964
Fingerprint: 25FC E4A5 8A72 2F69 1186 6D76 4209 0272 9A92 C964


Re: [dunfell][PATCH v2] ti-graphics: gpu enable and move all platforms to ddk 1.15

Andrew Davis
 

On 3/25/22 3:10 PM, Denys Dmytriyenko wrote:
On Wed, Mar 23, 2022 at 02:37:07PM -0500, Darren Etheridge wrote:
Enable the GPU for am62xx and j721s2 and use IMG DDK 1.15

Migrate Imagination DDK 1.13 to DDK 1.15 for J721e
Overall looks good, please see inline below.

Signed-off-by: Darren Etheridge <detheridge@...>
---

No changes in the content of the patch, however I regenerated it with the
similarity threshold reduced as requested by Denys.

conf/machine/am62xx-evm.conf | 2 ++
conf/machine/j721s2-evm.conf | 2 ++
...bb => ti-img-rogue-driver_1.15.6133109.bb} | 20 +++++++++++--------
...bb => ti-img-rogue-umlibs_1.15.6133109.bb} | 13 ++++++------
4 files changed, 23 insertions(+), 14 deletions(-)
rename recipes-bsp/powervr-drivers/{ti-img-rogue-driver_1.13.5776728.bb => ti-img-rogue-driver_1.15.6133109.bb} (48%)
rename recipes-graphics/libgles/{ti-img-rogue-umlibs_1.13.5776728.bb => ti-img-rogue-umlibs_1.15.6133109.bb} (84%)

diff --git a/conf/machine/am62xx-evm.conf b/conf/machine/am62xx-evm.conf
index 600abb58..086e40e4 100644
--- a/conf/machine/am62xx-evm.conf
+++ b/conf/machine/am62xx-evm.conf
@@ -4,6 +4,8 @@
require conf/machine/include/am62xx.inc
+MACHINE_FEATURES += "gpu"
+
KERNEL_DEVICETREE = " \
ti/k3-am625-sk.dtb \
ti/k3-am625-sk-lpmdemo.dtb \
diff --git a/conf/machine/j721s2-evm.conf b/conf/machine/j721s2-evm.conf
index 82fd33da..e5ed0b73 100644
--- a/conf/machine/j721s2-evm.conf
+++ b/conf/machine/j721s2-evm.conf
@@ -4,6 +4,8 @@
require conf/machine/include/j7.inc
+MACHINE_FEATURES += "gpu"
+
SERIAL_CONSOLES = "115200;ttyS10"
SERIAL_CONSOLES_CHECK = "${SERIAL_CONSOLES}"
TFA_K3_USART = "0x8"
diff --git a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
similarity index 48%
rename from recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
rename to recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
index a05de0f2..fbff6c51 100644
--- a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
+++ b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
@@ -7,17 +7,17 @@ inherit module features_check
REQUIRED_MACHINE_FEATURES = "gpu"
-MACHINE_KERNEL_PR_append = "b"
+MACHINE_KERNEL_PR_append = "a"
PR = "${MACHINE_KERNEL_PR}"
PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"
DEPENDS = "virtual/kernel"
PROVIDES = "virtual/gpudriver"
-BRANCH = "1.13-5776728/linux-k5.10"
+BRANCH = "linuxws/dunfell/k5.10/${PV}"
SRC_URI = " \
git://git.ti.com/graphics/ti-img-rogue-driver.git;branch=${BRANCH} \
@@ -26,15 +26,19 @@ SRC_URI = " \
S = "${WORKDIR}/git"
-SRCREV = "35a25875ae8738f82c7cabc6b077ef992b0cca84"
+SRCREV = "ee0674adccac16f5b2f7cb8d5d05948706080cb5"
-PVR_SOC = "j721e_linux"
I was actually thinking of keeping PVR_SOC variable and moving it to
corresponding machine configs.

PVR_SOC is a bit of a legacy name, especially since PVR is now IMG.

Thinking on this, the mapping between SoC family and the internal names
like "RGX_BVNC" and "TARGET_PRODUCT" are specific to the version of this
driver. For instance in the next DDK I may want the target name to
go from "am62_linux" to "axb_128_linux", I would have to
change things here (update the SRCREV) AND in the machine config.

Mapping here feels like the right spot to me. I'd even argue the same
for OPTEEMACHINE and the like, should go in the optee.bbappends with the
rest of our platform specific recipe fixups, etc.



-PVR_BVNC = "22.104.208.318"
+TARGET_PRODUCT_j7-evm = "j721e_linux"
+TARGET_PRODUCT_j721s2-evm = "j721s2_linux"

The driver depends on the SoC, not the EVM. s/j721s2-evm/j721s2
I know you cant do that in dunfell but if my other series gets into
main it should be fixed there, where we have a SOC_FAMILY for these
SoCs.

Andrew


+TARGET_PRODUCT_am62xx = "am62_linux"
E.g. instead of these 3 overrides in the recipe, those 3 machines will be
setting their respective PVR_SOC variables, which is more descriptive than
TARGET_PRODUCT.
Similar to how machine configs already set KERNEL_DEVICETREE, UBOOT_MACHINE,
TFA_PLATFORM or OPTEEMACHINE.
I know SGX been using TARGET_PRODUCT historically, but outside of the recipe
it won't make much sense.
But it may be too disruptive for Dunfell at this point. I can do such change
in master when porting this patch over on top of Andrew's changes.

+TARGET_BVNC_j7-evm = "22.104.208.318"
+TARGET_BVNC_j721s2-evm = "36.53.104.796"
+TARGET_BVNC_am62xx = "33.15.11.3"
PVR_BUILD = "release"
PVR_WS = "wayland"
-EXTRA_OEMAKE += 'KERNELDIR="${STAGING_KERNEL_DIR}" RGX_BVNC=${PVR_BVNC} BUILD=${PVR_BUILD} PVR_BUILD_DIR=${PVR_SOC} WINDOW_SYSTEM=${PVR_WS}'
+EXTRA_OEMAKE += 'KERNELDIR="${STAGING_KERNEL_DIR}" RGX_BVNC=${TARGET_BVNC} BUILD=${PVR_BUILD} PVR_BUILD_DIR=${TARGET_PRODUCT} WINDOW_SYSTEM=${PVR_WS}'
do_install() {
- make -C ${STAGING_KERNEL_DIR} M=${B}/binary_${PVR_SOC}_${PVR_WS}_${PVR_BUILD}/target_aarch64/kbuild INSTALL_MOD_PATH=${D}${root_prefix} PREFIX=${STAGING_DIR_HOST} modules_install
+ make -C ${STAGING_KERNEL_DIR} M=${B}/binary_${TARGET_PRODUCT}_${PVR_WS}_${PVR_BUILD}/target_aarch64/kbuild INSTALL_MOD_PATH=${D}${root_prefix} PREFIX=${STAGING_DIR_HOST} modules_install
}
diff --git a/recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb b/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
similarity index 84%
rename from recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb
rename to recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
index 5194015e..e00dce99 100644
--- a/recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb
+++ b/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
@@ -8,17 +8,18 @@ inherit features_check
REQUIRED_MACHINE_FEATURES = "gpu"
PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"
-PR = "r3"
+PR = "r1"
BRANCH = "linuxws/dunfell/k5.10/${PV}"
SRC_URI = "git://git.ti.com/graphics/ti-img-rogue-umlibs.git;branch=${BRANCH}"
+SRCREV = "47c3ffc44f2881397d45c8a2b5dfa7d6c58b79fb"
-SRCREV = "5ef38353c38d921a65ea6df75c7b6ce710b66034"
-
-PVR_SOC ?= "j721e_linux"
+TARGET_PRODUCT_j7-evm = "j721e_linux"
+TARGET_PRODUCT_j721s2-evm = "j721s2_linux"
+TARGET_PRODUCT_am62xx = "am62_linux"
Same here.

PVR_BUILD ?= "release"
PVR_WS = "wayland"
@@ -50,7 +51,7 @@ RRECOMMENDS_${PN} += "ti-img-rogue-driver"
S = "${WORKDIR}/git"
do_install () {
- oe_runmake install DESTDIR=${D} TARGET_PRODUCT=${PVR_SOC} BUILD=${PVR_BUILD} WINDOW_SYSTEM=${PVR_WS}
+ oe_runmake install DESTDIR=${D} TARGET_PRODUCT=${TARGET_PRODUCT} BUILD=${PVR_BUILD} WINDOW_SYSTEM=${PVR_WS}
chown -R root:root ${D}
}
--
2.17.1


[dunfell][PATCH v4] machine: Add am62xx evm configuration

Ryan Eatmon
 

From: Nishanth Menon <nm@...>

Lets add the basic AM62xx-evm configuration.
- Add configurations.
- Add firmware overrides.
- Add u-boot overrides.

Signed-off-by: Nishanth Menon <nm@...>
Signed-off-by: Hari Nagalla <hnagalla@...>
Signed-off-by: Ryan Eatmon <reatmon@...>
---
v2: Removed ti-graphics patch, and removed lpm-demo patches.
v3: Squashed and cleaned up the previous patches.
v4: Removed tabs that made their way into some of the files, and added
more to the commit message.

conf/machine/am62xx-evm-k3r5.conf | 11 +++++++
conf/machine/am62xx-evm.conf | 13 ++++++++
conf/machine/include/am62xx.inc | 17 ++++++++++
recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb | 18 ++++++++++
recipes-bsp/u-boot/u-boot-ti.inc | 7 ++++
recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb | 38 +++++++++++++++++++---
6 files changed, 99 insertions(+), 5 deletions(-)
create mode 100644 conf/machine/am62xx-evm-k3r5.conf
create mode 100644 conf/machine/am62xx-evm.conf
create mode 100644 conf/machine/include/am62xx.inc

diff --git a/conf/machine/am62xx-evm-k3r5.conf b/conf/machine/am62xx-evm-k3r5.conf
new file mode 100644
index 00000000..724a8d4a
--- /dev/null
+++ b/conf/machine/am62xx-evm-k3r5.conf
@@ -0,0 +1,11 @@
+#@TYPE: Machine
+#@NAME: AM62XX EVM (R5F)
+#@DESCRIPTION: Machine configuration for the TI AM62xx EVM (R5F core)
+
+require conf/machine/include/k3r5.inc
+
+SYSFW_SOC = "am62x"
+SYSFW_CONFIG = "evm"
+SYSFW_SUFFIX = "gp"
+
+UBOOT_MACHINE = "am62x_evm_r5_defconfig"
diff --git a/conf/machine/am62xx-evm.conf b/conf/machine/am62xx-evm.conf
new file mode 100644
index 00000000..600abb58
--- /dev/null
+++ b/conf/machine/am62xx-evm.conf
@@ -0,0 +1,13 @@
+#@TYPE: Machine
+#@NAME: AM62XX EVM
+#@DESCRIPTION: Machine configuration for the TI AM62XX EVM
+
+require conf/machine/include/am62xx.inc
+
+KERNEL_DEVICETREE = " \
+ ti/k3-am625-sk.dtb \
+ ti/k3-am625-sk-lpmdemo.dtb \
+ ti/k3-am625-minimal.dtb \
+"
+
+UBOOT_MACHINE = "am62x_evm_a53_defconfig"
diff --git a/conf/machine/include/am62xx.inc b/conf/machine/include/am62xx.inc
new file mode 100644
index 00000000..e8823dd2
--- /dev/null
+++ b/conf/machine/include/am62xx.inc
@@ -0,0 +1,17 @@
+require conf/machine/include/k3.inc
+SOC_FAMILY_append = ":am62xx"
+
+MACHINE_FEATURES += "screen touchscreen"
+
+SERIAL_CONSOLES = "115200;ttyS2"
+SERIAL_CONSOLES_CHECK = "${SERIAL_CONSOLES}"
+
+# AM62 supports multi-certificate images, use the same
+IMAGE_BOOT_FILES = "${IMAGE_BOOT_FILES_MULTI_CERT}"
+
+do_image_wic[mcdepends] = "mc::k3r5:ti-sci-fw:do_deploy"
+do_image_tar[mcdepends] = "mc::k3r5:ti-sci-fw:do_deploy"
+
+TFA_BOARD = "lite"
+OPTEEMACHINE = "k3-am65x"
+OPTEEOUTPUTMACHINE = "k3"
diff --git a/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb b/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb
index 646833a7..099473b4 100644
--- a/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb
+++ b/recipes-bsp/ti-sci-fw/ti-sci-fw_git.bb
@@ -6,6 +6,7 @@ DEPENDS_append_j7200-hs-evm-k3r5 = " virtual/bootloader"
DEPENDS_append_j721s2-evm-k3r5 = " virtual/bootloader"
DEPENDS_append_am64xx-evm-k3r5 = " virtual/bootloader"
DEPENDS_append_am64xx-hs-evm-k3r5 = " virtual/bootloader"
+DEPENDS_append_am62xx-evm-k3r5 = " virtual/bootloader"

CLEANBROKEN = "1"
PR = "${INC_PR}.2"
@@ -29,6 +30,7 @@ SYSFW_PREFIX_j7-hs-evm-k3r5-sr1-1 = "ti-fs-firmware"
SYSFW_PREFIX_j7200-evm-k3r5 = "ti-fs-firmware"
SYSFW_PREFIX_j7200-hs-evm-k3r5 = "ti-fs-firmware"
SYSFW_PREFIX_j721s2-evm-k3r5 = "ti-fs-firmware"
+SYSFW_PREFIX_am62xx-evm-k3r5 = "ti-fs-firmware"

SYSFW_SUFFIX ?= "unknown"

@@ -63,6 +65,7 @@ EXTRA_OEMAKE_append_j7200-hs-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-s
EXTRA_OEMAKE_append_j721s2-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""
EXTRA_OEMAKE_append_am64xx-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""
EXTRA_OEMAKE_append_am64xx-hs-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""
+EXTRA_OEMAKE_append_am62xx-evm-k3r5 = " SBL="${STAGING_DIR_HOST}/boot/u-boot-spl.bin""

do_compile() {
cd ${WORKDIR}/imggen/
@@ -170,4 +173,19 @@ do_deploy_am64xx-hs-evm-k3r5() {
install -m 644 ${SYSFW_TISCI} ${DEPLOYDIR}/
}

+do_install_am62xx-evm-k3r5() {
+ install -d ${D}/boot
+ install -m 644 ${WORKDIR}/imggen/${UBOOT_BINARY} ${D}/boot/${UBOOT_IMAGE}
+ ln -sf ${UBOOT_IMAGE} ${D}/boot/${UBOOT_SYMLINK}
+ ln -sf ${UBOOT_IMAGE} ${D}/boot/${UBOOT_BINARY}
+}
+
+do_deploy_am62xx-evm-k3r5() {
+ install -d ${DEPLOYDIR}
+ install -m 644 ${WORKDIR}/imggen/${UBOOT_BINARY} ${DEPLOYDIR}/${UBOOT_IMAGE}
+ ln -sf ${UBOOT_IMAGE} ${DEPLOYDIR}/${UBOOT_SYMLINK}
+ ln -sf ${UBOOT_IMAGE} ${DEPLOYDIR}/${UBOOT_BINARY}
+ install -m 644 ${SYSFW_TISCI} ${DEPLOYDIR}/
+}
+
addtask deploy before do_build after do_compile
diff --git a/recipes-bsp/u-boot/u-boot-ti.inc b/recipes-bsp/u-boot/u-boot-ti.inc
index 7ed6c5b4..231b7647 100644
--- a/recipes-bsp/u-boot/u-boot-ti.inc
+++ b/recipes-bsp/u-boot/u-boot-ti.inc
@@ -41,6 +41,7 @@ PACKAGECONFIG[dm] = "DM=${STAGING_DIR_HOST}${nonarch_base_libdir}/firmware/pdk-i

PACKAGECONFIG_append_aarch64 = " atf optee"
PACKAGECONFIG_append_j7 = " dm"
+PACKAGECONFIG_append_am62xx = " dm"

COMPATIBLE_MACHINE = "(ti-soc)"

@@ -69,6 +70,7 @@ SPL_UART_BINARY_j7200-hs-evm-k3r5 = "u-boot-spl.bin"
SPL_UART_BINARY_j721s2-evm-k3r5 = "u-boot-spl.bin"
SPL_UART_BINARY_am64xx-evm-k3r5 = "u-boot-spl.bin"
SPL_UART_BINARY_am64xx-hs-evm-k3r5 = "u-boot-spl.bin"
+SPL_UART_BINARY_am62xx-evm-k3r5 = "u-boot-spl.bin"

SPL_UART_IMAGE ?= "${SPL_UART_BINARY}-${MACHINE}-${PV}-${PR}"
SPL_UART_SYMLINK ?= "${SPL_UART_BINARY}-${MACHINE}"
@@ -419,4 +421,9 @@ do_deploy_append_am64xx-hs-evm-k3r5 () {
mv ${DEPLOYDIR}/u-boot-spl.bin ${DEPLOYDIR}/u-boot-spl-r5spl.bin || true
}

+do_deploy_append_am62xx-evm-k3r5 () {
+ mv ${DEPLOYDIR}/tiboot3.bin ${DEPLOYDIR}/tiboot3-r5spl.bin || true
+ mv ${DEPLOYDIR}/u-boot-spl.bin ${DEPLOYDIR}/u-boot-spl-r5spl.bin || true
+}
+
TOOLCHAIN = "gcc"
diff --git a/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb b/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb
index c5852dbd..02e5d665 100644
--- a/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb
+++ b/recipes-ti/ti-rtos-bin/ti-rtos-firmware.bb
@@ -19,6 +19,7 @@ PLAT_SFX_j7200-hs-evm = "j7200"
PLAT_SFX_j721s2-evm = "j721s2"
PLAT_SFX_am65xx = "am65xx"
PLAT_SFX_am64xx = "am64xx"
+PLAT_SFX_am62xx = "am62x"

FILESEXTRAPATHS_prepend := "${METATIBASE}/recipes-bsp/ti-sci-fw/files/:"
require recipes-bsp/ti-linux-fw/ti-linux-fw.inc
@@ -50,11 +51,11 @@ DM_FIRMWARE = "ipc_echo_testb_mcu1_0_release_strip.xer5f"

# J7 HS support
do_install_prepend_j7-hs-evm() {
- export TI_SECURE_DEV_PKG=${TI_SECURE_DEV_PKG}
- ( cd ${RTOS_DM_FW_DIR}; \
- mv ${DM_FIRMWARE} ${DM_FIRMWARE}.unsigned; \
- ${TI_SECURE_DEV_PKG}/scripts/secure-binary-image.sh ${DM_FIRMWARE}.unsigned ${DM_FIRMWARE}; \
- )
+ export TI_SECURE_DEV_PKG=${TI_SECURE_DEV_PKG}
+ ( cd ${RTOS_DM_FW_DIR}; \
+ mv ${DM_FIRMWARE} ${DM_FIRMWARE}.unsigned; \
+ ${TI_SECURE_DEV_PKG}/scripts/secure-binary-image.sh ${DM_FIRMWARE}.unsigned ${DM_FIRMWARE}; \
+ )
}

# J7 HS support
@@ -77,6 +78,13 @@ do_install_prepend_am64xx() {
)
}

+# Update the am62xx ipc binaries to be consistent with other platforms
+do_install_prepend_am62xx() {
+ ( cd ${RTOS_IPC_FW_DIR}; \
+ mv am62-mcu-m4f0_0-fw ipc_echo_baremetal_test_mcu2_0_release_strip.xer5f; \
+ )
+}
+
#Install all R5 & DSP ipc echo test binaries in lib/firmware/pdk-ipc, with softlinks up a level
do_install() {

@@ -154,6 +162,13 @@ do_install_am64xx() {
install -m 0644 ${RTOS_IPC_FW_DIR}/ipc_echo_baremetal_test_mcu3_0_release_strip.xer5f ${LEGACY_IPC_FW_DIR}
}

+do_install_am62xx() {
+ install -d ${LEGACY_IPC_FW_DIR}
+ install -m 0644 ${RTOS_IPC_FW_DIR}/ipc_echo_baremetal_test_mcu2_0_release_strip.xer5f ${LEGACY_IPC_FW_DIR}
+ # DM Firmware
+ install -m 0644 ${RTOS_DM_FW_DIR}/ipc_echo_testb_mcu1_0_release_strip.xer5f ${LEGACY_DM_FW_DIR}
+}
+
# Set up names for the firmwares
ALTERNATIVE_${PN}_am65xx = "\
am65x-mcu-r5f0_0-fw \
@@ -167,6 +182,10 @@ ALTERNATIVE_${PN}_am64xx = "\
am64-main-r5f1_1-fw \
am64-mcu-m4f0_0-fw \
"
+ALTERNATIVE_${PN}_am62xx = "\
+ am62-mcu-m4f0_0-fw \
+ am62-main-r5f0_0-fw \
+ "

ALTERNATIVE_${PN}_j7 = "\
j7-mcu-r5f0_0-fw \
@@ -216,6 +235,9 @@ TARGET_MAIN_R5FSS1_0_am64xx = "am64-main-r5f1_0-fw"
TARGET_MAIN_R5FSS1_1_am64xx = "am64-main-r5f1_1-fw"
TARGET_MCU_M4FSS0_0_am64xx = "am64-mcu-m4f0_0-fw"

+TARGET_MAIN_R5FSS0_0_am62xx = "am62-main-r5f0_0-fw"
+TARGET_MCU_M4FSS0_0_am62xx = "am62-mcu-m4f0_0-fw"
+
TARGET_MCU_R5FSS0_0_j7 = "j7-mcu-r5f0_0-fw"
TARGET_MCU_R5FSS0_1_j7 = "j7-mcu-r5f0_1-fw"
TARGET_MAIN_R5FSS0_0_j7 = "j7-main-r5f0_0-fw"
@@ -254,6 +276,9 @@ ALTERNATIVE_LINK_NAME[am64-main-r5f1_0-fw] = "${base_libdir}/firmware/${TARGET_M
ALTERNATIVE_LINK_NAME[am64-main-r5f1_1-fw] = "${base_libdir}/firmware/${TARGET_MAIN_R5FSS1_1}"
ALTERNATIVE_LINK_NAME[am64-mcu-m4f0_0-fw] = "${base_libdir}/firmware/${TARGET_MCU_M4FSS0_0}"

+ALTERNATIVE_LINK_NAME[am62-main-r5f0_0-fw] = "${base_libdir}/firmware/${TARGET_MAIN_R5FSS0_0}"
+ALTERNATIVE_LINK_NAME[am62-mcu-m4f0_0-fw] = "${base_libdir}/firmware/${TARGET_MCU_M4FSS0_0}"
+
ALTERNATIVE_LINK_NAME[j7-mcu-r5f0_0-fw] = "${base_libdir}/firmware/${TARGET_MCU_R5FSS0_0}"
ALTERNATIVE_LINK_NAME[j7-mcu-r5f0_1-fw] = "${base_libdir}/firmware/${TARGET_MCU_R5FSS0_1}"
ALTERNATIVE_LINK_NAME[j7-main-r5f0_0-fw] = "${base_libdir}/firmware/${TARGET_MAIN_R5FSS0_0}"
@@ -289,6 +314,9 @@ ALTERNATIVE_TARGET[am64-main-r5f1_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_e
ALTERNATIVE_TARGET[am64-main-r5f1_1-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_baremetal_test_mcu2_1_release_strip.xer5f"
ALTERNATIVE_TARGET[am64-mcu-m4f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_baremetal_test_mcu3_0_release_strip.xer5f"

+ALTERNATIVE_TARGET[am62-main-r5f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_testb_mcu1_0_release_strip.xer5f"
+ALTERNATIVE_TARGET[am62-mcu-m4f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_baremetal_test_mcu2_0_release_strip.xer5f"
+
ALTERNATIVE_TARGET[j7-mcu-r5f0_0-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_testb_mcu1_0_release_strip.xer5f"
ALTERNATIVE_TARGET[j7-mcu-r5f0_1-fw] = "${base_libdir}/firmware/pdk-ipc/ipc_echo_test_mcu1_1_release_strip.xer5f"
ALTERNATIVE_TARGET[j7-main-r5f0_0-fw] = "${base_libdir}/firmware/ethfw/app_remoteswitchcfg_server_strip.xer5f"
--
2.17.1


Re: [dunfell][PATCH v3] machine: Add am62xx evm configuration

Ryan Eatmon
 

On 3/24/2022 20:47, Andrew Davis wrote:
On 3/24/22 5:21 PM, Ryan Eatmon via lists.yoctoproject.org wrote:
@@ -167,6 +182,10 @@ ALTERNATIVE_${PN}_am64xx = "\
                      am64-main-r5f1_1-fw \
                      am64-mcu-m4f0_0-fw \
                      "
+ALTERNATIVE_${PN}_am62xx = "\
+                    am62-mcu-m4f0_0-fw \
+                    am62-main-r5f0_0-fw \
^^ Looks like some tabs found there way in here..
I'll remove those errant tabs in v4.

Why do we have these indented so far anyway, this whole file has wacky
indenting, needs normalized.
The formatting has been in there for quite a while, so a more general file clean up might be in order. I'll save that for another commit after we get past all of the am62xx changes.



Andrew

+                    "
  ALTERNATIVE_${PN}_j7 = "\
                      j7-mcu-r5f0_0-fw \
@@ -216,6 +235,9 @@ TARGET_MAIN_R5FSS1_0_am64xx = "am64-main-r5f1_0-fw"
  TARGET_MAIN_R5FSS1_1_am64xx = "am64-main-r5f1_1-fw"
  TARGET_MCU_M4FSS0_0_am64xx = "am64-mcu-m4f0_0-fw"
+TARGET_MAIN_R5FSS0_0_am62xx = "am62-main-r5f0_0-fw"
+TARGET_MCU_M4FSS0_0_am62xx = "am62-mcu-m4f0_0-fw"
+
--
Ryan Eatmon
reatmon@...


Re: [dunfell][PATCH v3] machine: Add am62xx evm configuration

Denys Dmytriyenko
 

On Thu, Mar 24, 2022 at 08:47:12PM -0500, Andrew F. Davis via lists.yoctoproject.org wrote:
On 3/24/22 5:21 PM, Ryan Eatmon via lists.yoctoproject.org wrote:
@@ -167,6 +182,10 @@ ALTERNATIVE_${PN}_am64xx = "\
am64-main-r5f1_1-fw \
am64-mcu-m4f0_0-fw \
"
+ALTERNATIVE_${PN}_am62xx = "\
+ am62-mcu-m4f0_0-fw \
+ am62-main-r5f0_0-fw \

^^ Looks like some tabs found there way in here..

Why do we have these indented so far anyway, this whole file has wacky
indenting, needs normalized.
Some quotes from the manual for 3 different cases - shell code, python code
and multi-line statements:

===============================================
Indentation: Use spaces for indentation rather than than tabs. For shell
functions, both currently work. However, it is a policy decision of the Yocto
Project to use tabs in shell functions. Realize that some layers have a policy
to use spaces for all indentation.

Python Function Whitespace: All Python functions must now use four spaces for
indentation. Previously, an inconsistent mix of spaces and tabs existed, which
made extending these functions using _append or _prepend complicated given
that Python treats whitespace as syntactically significant. If you are
defining or extending any Python functions (e.g. populate_packages, do_unpack,
do_patch and so forth) in custom recipes or classes, you need to ensure you
are using consistent four-space indentation.

Line Continuation: \ - Use the backward slash (\) character to split a
statement over multiple lines. Place the slash character at the end of the
line that is to be continued on the next line:

VAR = "A really long \
line"
===============================================

As you can see in the final example of multi-line, it shows the second line
starting where its content begins in the previous line. But it is not required
to indent like that, especially if the left part before the assignment sign is
very long, e.g.:

ALTERNATIVE_${PN}_am62xx = "am62-mcu-m4f0_0-fw \
am62-main-r5f0_0-fw \

Instead, you could start at the beginning of the line or use minimal
indentation of few spaces (no tabs here):

ALTERNATIVE_${PN}_am62xx = " \
am62-mcu-m4f0_0-fw \
am62-main-r5f0_0-fw \

ALTERNATIVE_${PN}_am62xx = " \
am62-mcu-m4f0_0-fw \
am62-main-r5f0_0-fw \

Both are acceptable.

Tabs to be only used in shell functions, such as do_compile, do_install, etc.

And one more final comment - when making functional changes, please keep the
existing indentation as is. If indentation need to be cleaned up or changed
for a recipe, should be a separate patch just for that w/o any functionality
or code changes - don't mix them in a single patch, unless it's a one-off.

--
Regards,
Denys Dmytriyenko <denis@...>
PGP: 0x420902729A92C964 - https://denix.org/0x420902729A92C964
Fingerprint: 25FC E4A5 8A72 2F69 1186 6D76 4209 0272 9A92 C964


Re: [dunfell][PATCH v2] ti-graphics: gpu enable and move all platforms to ddk 1.15

Denys Dmytriyenko
 

On Wed, Mar 23, 2022 at 02:37:07PM -0500, Darren Etheridge wrote:
Enable the GPU for am62xx and j721s2 and use IMG DDK 1.15

Migrate Imagination DDK 1.13 to DDK 1.15 for J721e
Overall looks good, please see inline below.


Signed-off-by: Darren Etheridge <detheridge@...>
---

No changes in the content of the patch, however I regenerated it with the
similarity threshold reduced as requested by Denys.

conf/machine/am62xx-evm.conf | 2 ++
conf/machine/j721s2-evm.conf | 2 ++
...bb => ti-img-rogue-driver_1.15.6133109.bb} | 20 +++++++++++--------
...bb => ti-img-rogue-umlibs_1.15.6133109.bb} | 13 ++++++------
4 files changed, 23 insertions(+), 14 deletions(-)
rename recipes-bsp/powervr-drivers/{ti-img-rogue-driver_1.13.5776728.bb => ti-img-rogue-driver_1.15.6133109.bb} (48%)
rename recipes-graphics/libgles/{ti-img-rogue-umlibs_1.13.5776728.bb => ti-img-rogue-umlibs_1.15.6133109.bb} (84%)

diff --git a/conf/machine/am62xx-evm.conf b/conf/machine/am62xx-evm.conf
index 600abb58..086e40e4 100644
--- a/conf/machine/am62xx-evm.conf
+++ b/conf/machine/am62xx-evm.conf
@@ -4,6 +4,8 @@

require conf/machine/include/am62xx.inc

+MACHINE_FEATURES += "gpu"
+
KERNEL_DEVICETREE = " \
ti/k3-am625-sk.dtb \
ti/k3-am625-sk-lpmdemo.dtb \
diff --git a/conf/machine/j721s2-evm.conf b/conf/machine/j721s2-evm.conf
index 82fd33da..e5ed0b73 100644
--- a/conf/machine/j721s2-evm.conf
+++ b/conf/machine/j721s2-evm.conf
@@ -4,6 +4,8 @@

require conf/machine/include/j7.inc

+MACHINE_FEATURES += "gpu"
+
SERIAL_CONSOLES = "115200;ttyS10"
SERIAL_CONSOLES_CHECK = "${SERIAL_CONSOLES}"
TFA_K3_USART = "0x8"
diff --git a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
similarity index 48%
rename from recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
rename to recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
index a05de0f2..fbff6c51 100644
--- a/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.13.5776728.bb
+++ b/recipes-bsp/powervr-drivers/ti-img-rogue-driver_1.15.6133109.bb
@@ -7,17 +7,17 @@ inherit module features_check

REQUIRED_MACHINE_FEATURES = "gpu"

-MACHINE_KERNEL_PR_append = "b"
+MACHINE_KERNEL_PR_append = "a"
PR = "${MACHINE_KERNEL_PR}"

PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"

DEPENDS = "virtual/kernel"

PROVIDES = "virtual/gpudriver"

-BRANCH = "1.13-5776728/linux-k5.10"
+BRANCH = "linuxws/dunfell/k5.10/${PV}"

SRC_URI = " \
git://git.ti.com/graphics/ti-img-rogue-driver.git;branch=${BRANCH} \
@@ -26,15 +26,19 @@ SRC_URI = " \

S = "${WORKDIR}/git"

-SRCREV = "35a25875ae8738f82c7cabc6b077ef992b0cca84"
+SRCREV = "ee0674adccac16f5b2f7cb8d5d05948706080cb5"

-PVR_SOC = "j721e_linux"
I was actually thinking of keeping PVR_SOC variable and moving it to
corresponding machine configs.


-PVR_BVNC = "22.104.208.318"
+TARGET_PRODUCT_j7-evm = "j721e_linux"
+TARGET_PRODUCT_j721s2-evm = "j721s2_linux"
+TARGET_PRODUCT_am62xx = "am62_linux"
E.g. instead of these 3 overrides in the recipe, those 3 machines will be
setting their respective PVR_SOC variables, which is more descriptive than
TARGET_PRODUCT.

Similar to how machine configs already set KERNEL_DEVICETREE, UBOOT_MACHINE,
TFA_PLATFORM or OPTEEMACHINE.

I know SGX been using TARGET_PRODUCT historically, but outside of the recipe
it won't make much sense.

But it may be too disruptive for Dunfell at this point. I can do such change
in master when porting this patch over on top of Andrew's changes.


+TARGET_BVNC_j7-evm = "22.104.208.318"
+TARGET_BVNC_j721s2-evm = "36.53.104.796"
+TARGET_BVNC_am62xx = "33.15.11.3"
PVR_BUILD = "release"
PVR_WS = "wayland"

-EXTRA_OEMAKE += 'KERNELDIR="${STAGING_KERNEL_DIR}" RGX_BVNC=${PVR_BVNC} BUILD=${PVR_BUILD} PVR_BUILD_DIR=${PVR_SOC} WINDOW_SYSTEM=${PVR_WS}'
+EXTRA_OEMAKE += 'KERNELDIR="${STAGING_KERNEL_DIR}" RGX_BVNC=${TARGET_BVNC} BUILD=${PVR_BUILD} PVR_BUILD_DIR=${TARGET_PRODUCT} WINDOW_SYSTEM=${PVR_WS}'

do_install() {
- make -C ${STAGING_KERNEL_DIR} M=${B}/binary_${PVR_SOC}_${PVR_WS}_${PVR_BUILD}/target_aarch64/kbuild INSTALL_MOD_PATH=${D}${root_prefix} PREFIX=${STAGING_DIR_HOST} modules_install
+ make -C ${STAGING_KERNEL_DIR} M=${B}/binary_${TARGET_PRODUCT}_${PVR_WS}_${PVR_BUILD}/target_aarch64/kbuild INSTALL_MOD_PATH=${D}${root_prefix} PREFIX=${STAGING_DIR_HOST} modules_install
}
diff --git a/recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb b/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
similarity index 84%
rename from recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb
rename to recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
index 5194015e..e00dce99 100644
--- a/recipes-graphics/libgles/ti-img-rogue-umlibs_1.13.5776728.bb
+++ b/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
@@ -8,17 +8,18 @@ inherit features_check
REQUIRED_MACHINE_FEATURES = "gpu"

PACKAGE_ARCH = "${MACHINE_ARCH}"
-COMPATIBLE_MACHINE = "j7"
+COMPATIBLE_MACHINE = "j7-evm|j721s2-evm|am62xx"

-PR = "r3"
+PR = "r1"

BRANCH = "linuxws/dunfell/k5.10/${PV}"

SRC_URI = "git://git.ti.com/graphics/ti-img-rogue-umlibs.git;branch=${BRANCH}"
+SRCREV = "47c3ffc44f2881397d45c8a2b5dfa7d6c58b79fb"

-SRCREV = "5ef38353c38d921a65ea6df75c7b6ce710b66034"
-
-PVR_SOC ?= "j721e_linux"
+TARGET_PRODUCT_j7-evm = "j721e_linux"
+TARGET_PRODUCT_j721s2-evm = "j721s2_linux"
+TARGET_PRODUCT_am62xx = "am62_linux"
Same here.


PVR_BUILD ?= "release"
PVR_WS = "wayland"

@@ -50,7 +51,7 @@ RRECOMMENDS_${PN} += "ti-img-rogue-driver"
S = "${WORKDIR}/git"

do_install () {
- oe_runmake install DESTDIR=${D} TARGET_PRODUCT=${PVR_SOC} BUILD=${PVR_BUILD} WINDOW_SYSTEM=${PVR_WS}
+ oe_runmake install DESTDIR=${D} TARGET_PRODUCT=${TARGET_PRODUCT} BUILD=${PVR_BUILD} WINDOW_SYSTEM=${PVR_WS}
chown -R root:root ${D}
}

--
2.17.1
--
Regards,
Denys Dmytriyenko <denis@...>
PGP: 0x420902729A92C964 - https://denix.org/0x420902729A92C964
Fingerprint: 25FC E4A5 8A72 2F69 1186 6D76 4209 0272 9A92 C964

301 - 320 of 14873