From a4fc9e21030030d0449c5b2ff954911a4a7f9fba Mon Sep 17 00:00:00 2001 From: Ernest Van Hoecke Date: Tue, 15 Apr 2025 13:12:23 +0200 Subject: EULA: Update to v58 This version is used in NXP BSP LF6.12.3-1.0.0 Signed-off-by: Ernest Van Hoecke (cherry picked from commit ab2458268c7148f2a8df96d77fbffeee34e09d5c) --- EULA | 64 ++++++++++++++++++++++++++++++----------- classes/fsl-eula-unpack.bbclass | 4 ++- 2 files changed, 50 insertions(+), 18 deletions(-) diff --git a/EULA b/EULA index ac7337fa..5f5cc2f9 100644 --- a/EULA +++ b/EULA @@ -1,4 +1,4 @@ -LA_OPT_NXP_Software_License v57 July 2024 +LA_OPT_NXP_Software_License v58 November 2024 IMPORTANT. Read the following NXP Software License Agreement ("Agreement") completely. By selecting the "I Accept" button at the end of this page, or by downloading, installing, or using the Licensed Software, you indicate that you @@ -242,21 +242,51 @@ COSTS, DAMAGES, CLAIMS, OR LOSSES WHATSOEVER ARISING OUT OF OR IN CONNECTION WITH THIS AGREEMENT OR PRODUCT(S) SUPPLIED UNDER THIS AGREEMENT IS LIMITED TO THE AGGREGATE AMOUNT PAID BY YOU TO NXP IN CONNECTION WITH THE LICENSED SOFTWARE PROVIDED UNDER THIS AGREEMENT TO WHICH LOSSES OR DAMAGES ARE CLAIMED. -12. EXPORT COMPLIANCE. Each party shall comply with all applicable -export and import control laws and regulations including but not limited to the -US Export Administration Regulation (including restrictions on certain military -end uses and military end users as specified in Section 15 C.F.R. § 744.21 and -prohibited party lists issued by other federal governments), Catch-all -regulations and all national and international embargoes. Each party further -agrees that it will not knowingly transfer, divert, export or re-export, -directly or indirectly, any product, software, including software source code, -or technology restricted by such regulations or by other applicable national -regulations, received from the other party under this Agreement, or any direct -product of such software or technical data to any person, firm, entity, country -or destination to which such transfer, diversion, export or re-export is -restricted or prohibited, without obtaining prior written authorization from -the applicable competent government authorities to the extent required by those -laws. +12. EXPORT COMPLIANCE. +12.1 Each party shall comply with all applicable export and import control +laws and regulations including but not limited to the US Export Administration +Regulation (including restrictions on certain military end uses and military +end users as specified in Section 15 C.F.R. § 744.21 and prohibited party +lists issued by other federal governments), Catch-all regulations and all +national and international embargoes. Each party further agrees that it will +not knowingly transfer, divert, export or re-export, directly or indirectly, +any product, software, including software source code, or technology restricted +by such regulations or by other applicable national regulations, received from +the other party under this Agreement, or any direct product of such software or +technical data to any person, firm, entity, country or destination to which +such transfer, diversion, export or re-export is restricted or prohibited, +without obtaining prior written authorization from the applicable competent +government authorities to the extent required by those laws. +12.2 Prohibition of Export to Russian Federation + +(a) With respect to activitit that falls under the scope of Article 12g, +12ga of Council Regulation (EU) No 833/2014, or Council Regulation (EU) No +765/2006 (as the case requires), you (a) will not sell, export or re-export, +directly or indirectly any item, and (b) will not sell, license or sublicense +any intellectual property rights or trade secrets, to the Russian Federation or +Belarus, or for use in the Russian Federation or Belarus. + +(b) You will ensure that the purpose of paragraph (a) above is not +frustrated by any third parties further down the commercial chain, including by +either resellers, sublicensees, or both. + +(c) You will set up and maintain an adequate monitoring mechanism to detect +conduct by any third parties further down the commercial chain, including by +either resellers, sublicensees, or both, that would frustrate the purpose of +paragraph (a). + +(d) Any violation of paragraphs (a), (b) or (c) will constitute a material +breach of this Agreement, and NXP will be entitled to seek appropriate +remedies, including, but not limited to: (i) termination of these Terms; (ii) +suspension of any of its business relationships with you, youraffiliates or +both, until the breach of paragraph (a) above is remedied, and (iii) a plan to +remedy the breach. + +(e) You will immediately inform NXP about any problems in applying +paragraphs (a), (b) or (c), above, including any relevant activities by third +parties that could frustrate the purpose of paragraph (a). You will make +available to NXPinformation concerning compliance with the obligations under +paragraphs (a), (b) and (c) within 2 weeks of the request for information. 13. GOVERNMENT CONTRACT COMPLIANCE 13.1. If you sell Authorized Systems directly to any government or public entity, including U.S., state, local, foreign or international governments or @@ -403,7 +433,7 @@ directly from AGGIOS, Inc. Airbiquity Inc.: The Airbiquity software may only be used in object code and Licensee may not sublicense the Airbiquity software to any third party. -Licensee’s license to use the Airbiquity software expires on June 30, 2024. +Licensee’s license to use the Airbiquity software expires on June 30, 2026. Amazon: Use of the Amazon software constitutes your acceptance of the terms of the Amazon Program Materials License Agreement (including the AVS Component diff --git a/classes/fsl-eula-unpack.bbclass b/classes/fsl-eula-unpack.bbclass index c170d2e0..5b165e48 100644 --- a/classes/fsl-eula-unpack.bbclass +++ b/classes/fsl-eula-unpack.bbclass @@ -61,6 +61,7 @@ FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V49 = "2827219e81f28aba7c6a569f FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V53 = "44a8052c384584ba09077e85a3d1654f" FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V56 = "10c0fda810c63b052409b15a5445671a" FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V57 = "ca53281cc0caa7e320d4945a896fb837" +FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V58 = "c0fb372b5d7f12181de23ef480f225f3" FSL_EULA_FILE_MD5SUMS = " \ ${FSL_EULA_FILE_MD5SUM_LA_OPT_BASE_LICENSE_V8} \ @@ -118,11 +119,12 @@ FSL_EULA_FILE_MD5SUMS = " \ ${FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V53} \ ${FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V56} \ ${FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V57} \ + ${FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V58} \ " # The checksum for the EULA in the layer FSL_EULA_FILE_MD5SUM ?= \ - "${FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V57}" + "${FSL_EULA_FILE_MD5SUM_LA_OPT_NXP_SOFTWARE_LICENSE_V58}" LIC_FILES_CHKSUM_LAYER ?= "file://${FSL_EULA_FILE};md5=${FSL_EULA_FILE_MD5SUM}" LIC_FILES_CHKSUM_LAYER[vardepsexclude] += "FSL_EULA_FILE" -- cgit v1.2.3-54-g00ecf From 5732d5403a576c3e5374dd73bc5a0c5f0eeae64b Mon Sep 17 00:00:00 2001 From: Ernest Van Hoecke Date: Tue, 15 Apr 2025 11:17:03 +0200 Subject: firmware-imx: Upgrade to v8.27 This updates firmware-imx to the versions used in NXP BSP L6.12.3-1.0.0. Compared to v8.26 at d4c33ab, the following binaries were added: - ddr/lpddr4x_dmem_qb_v202409.bin - ddr/lpddr4x_dmem_v202409.bin - ddr/lpddr4x_imem_qb_v202409.bin - ddr/lpddr4x_imem_v202409.bin - ddr/lpddr5_dmem_qb_v202409.bin - ddr/lpddr5_dmem_v202409.bin - ddr/lpddr5_imem_qb_v202409.bin - ddr/lpddr5_imem_v202409.bin No binaries were removed, the following have been updated: - vpu/vpu_fw_imx8_dec.bin - vpu/ave633c_codec_fw.bin Signed-off-by: Ernest Van Hoecke (cherry picked from commit 2cb2dc355827044a0011dcc4425da88b0ab36689) --- recipes-bsp/firmware-imx/firmware-imx-8.26.inc | 16 -- recipes-bsp/firmware-imx/firmware-imx-8.27.inc | 16 ++ recipes-bsp/firmware-imx/firmware-imx_8.26.bb | 171 --------------------- recipes-bsp/firmware-imx/firmware-imx_8.27.bb | 171 +++++++++++++++++++++ .../firmware-imx/imx-boot-firmware-files_8.26.bb | 61 -------- .../firmware-imx/imx-boot-firmware-files_8.27.bb | 61 ++++++++ 6 files changed, 248 insertions(+), 248 deletions(-) delete mode 100644 recipes-bsp/firmware-imx/firmware-imx-8.26.inc create mode 100644 recipes-bsp/firmware-imx/firmware-imx-8.27.inc delete mode 100644 recipes-bsp/firmware-imx/firmware-imx_8.26.bb create mode 100644 recipes-bsp/firmware-imx/firmware-imx_8.27.bb delete mode 100644 recipes-bsp/firmware-imx/imx-boot-firmware-files_8.26.bb create mode 100644 recipes-bsp/firmware-imx/imx-boot-firmware-files_8.27.bb diff --git a/recipes-bsp/firmware-imx/firmware-imx-8.26.inc b/recipes-bsp/firmware-imx/firmware-imx-8.26.inc deleted file mode 100644 index 0da88f47..00000000 --- a/recipes-bsp/firmware-imx/firmware-imx-8.26.inc +++ /dev/null @@ -1,16 +0,0 @@ -# Copyright (C) 2012-2016 Freescale Semiconductor -# Copyright 2017-2024 NXP -# Copyright (C) 2018 O.S. Systems Software LTDA. -SECTION = "base" -LICENSE = "Proprietary" -LIC_FILES_CHKSUM = "file://COPYING;md5=ca53281cc0caa7e320d4945a896fb837" - -# Note: This .inc file is used from differently named recipes, so the package -# name must be hard-coded, i.e., ${BPN} cannot be used. -SRC_URI = "${FSL_MIRROR}/firmware-imx-${PV}-${IMX_SRCREV_ABBREV}.bin;fsl-eula=true" -IMX_SRCREV_ABBREV = "d4c33ab" -SRC_URI[sha256sum] = "b2fcf84a0417678aa441b1bcde9ece467f8bd063a63d8390684f8e37768d84cf" - -S = "${WORKDIR}/firmware-imx-${PV}-${IMX_SRCREV_ABBREV}" - -inherit fsl-eula-unpack diff --git a/recipes-bsp/firmware-imx/firmware-imx-8.27.inc b/recipes-bsp/firmware-imx/firmware-imx-8.27.inc new file mode 100644 index 00000000..022289d3 --- /dev/null +++ b/recipes-bsp/firmware-imx/firmware-imx-8.27.inc @@ -0,0 +1,16 @@ +# Copyright (C) 2012-2016 Freescale Semiconductor +# Copyright 2017-2024 NXP +# Copyright (C) 2018 O.S. Systems Software LTDA. +SECTION = "base" +LICENSE = "Proprietary" +LIC_FILES_CHKSUM = "file://COPYING;md5=c0fb372b5d7f12181de23ef480f225f3" + +# Note: This .inc file is used from differently named recipes, so the package +# name must be hard-coded, i.e., ${BPN} cannot be used. +SRC_URI = "${FSL_MIRROR}/firmware-imx-${PV}-${IMX_SRCREV_ABBREV}.bin;fsl-eula=true" +IMX_SRCREV_ABBREV = "5af0ceb" +SRC_URI[sha256sum] = "61f925e606ab020b1a36f3f7f7e459c6847f5b9dbc79421f9ef86e8fc124eb2f" + +S = "${WORKDIR}/firmware-imx-${PV}-${IMX_SRCREV_ABBREV}" + +inherit fsl-eula-unpack diff --git a/recipes-bsp/firmware-imx/firmware-imx_8.26.bb b/recipes-bsp/firmware-imx/firmware-imx_8.26.bb deleted file mode 100644 index 7bac8106..00000000 --- a/recipes-bsp/firmware-imx/firmware-imx_8.26.bb +++ /dev/null @@ -1,171 +0,0 @@ -# Copyright (C) 2012-2016 Freescale Semiconductor -# Copyright 2017-2021,2024 NXP -# Copyright (C) 2018 O.S. Systems Software LTDA. -SUMMARY = "Freescale i.MX firmware" -DESCRIPTION = "Freescale i.MX firmware such as for the VPU" - -require ${BP}.inc - -PE = "1" - -inherit allarch - -IMX_USE_LINUX_FIRMWARE_SDMA ?= "1" - -do_install() { - install -d ${D}${nonarch_base_libdir}/firmware/imx - - # SDMA Firmware section - install -d ${D}${nonarch_base_libdir}/firmware/imx/sdma - install -m 0644 ${S}/firmware/sdma/* ${D}${nonarch_base_libdir}/firmware/imx/sdma - # Define IMX_USE_LINUX_FIRMWARE_SDMA = "0" in layer.conf, machine.conf, local.conf - # or in .bbappend to use sdma-imx6q/7d.bin from here and not linux-firmware - if [ ${IMX_USE_LINUX_FIRMWARE_SDMA} -gt 0 ] - then - rm -f ${D}${nonarch_base_libdir}/firmware/imx/sdma/sdma-imx6q.bin - rm -f ${D}${nonarch_base_libdir}/firmware/imx/sdma/sdma-imx7d.bin - fi - - # EASRC Firmware section - install -d ${D}${nonarch_base_libdir}/firmware/imx/easrc - install -m 0644 ${S}/firmware/easrc/* ${D}${nonarch_base_libdir}/firmware/imx/easrc/ - - # XCVR Firmware section - install -d ${D}${nonarch_base_libdir}/firmware/imx/xcvr - install -m 0644 ${S}/firmware/xcvr/* ${D}${nonarch_base_libdir}/firmware/imx/xcvr/ - - # XUVI Firmware section - install -d ${D}${nonarch_base_libdir}/firmware/imx/xuvi - install -m 0644 ${S}/firmware/xuvi/* ${D}${nonarch_base_libdir}/firmware/imx/xuvi/ - - # EPDC Firmware section - # NOTE: - # epdc_ED060XH2C1.fw file has .nonrestricted suffix in the source archive, hence it should - # be installed with a different name - install -d ${D}${nonarch_base_libdir}/firmware/imx/epdc - install -m 0644 ${S}/firmware/epdc/*.fw ${D}${nonarch_base_libdir}/firmware/imx/epdc/ - install -m 0644 ${S}/firmware/epdc/epdc_ED060XH2C1.fw.nonrestricted ${D}${nonarch_base_libdir}/firmware/imx/epdc/epdc_ED060XH2C1.fw - - # HDMI Firmware section - # NOTE: - # Only install pre-defined list of firmware files, since the source archive contains - # also HDMI binary files for imx8m derivatives, which are taken care of by another recipe - install -m 0644 ${S}/firmware/hdmi/cadence/hdmitxfw.bin ${D}${nonarch_base_libdir}/firmware - install -m 0644 ${S}/firmware/hdmi/cadence/hdmirxfw.bin ${D}${nonarch_base_libdir}/firmware - install -m 0644 ${S}/firmware/hdmi/cadence/dpfw.bin ${D}${nonarch_base_libdir}/firmware - - # VPU Firmware section - # NOTE: - # Do the same thing as above for HDMI - only install a pre-defined list of firmware files, - # as some of other files are provided by packages from other recipes. - install -d ${D}${nonarch_base_libdir}/firmware/vpu - install -m 0644 ${S}/firmware/vpu/vpu_fw_imx*.bin ${D}${nonarch_base_libdir}/firmware/vpu - # Update i.MX8 vpu firmware path to align with kernel6.5+ - install -d ${D}${nonarch_base_libdir}/firmware/amphion/vpu/ - mv ${D}${nonarch_base_libdir}/firmware/vpu/vpu_fw_imx8* ${D}${nonarch_base_libdir}/firmware/amphion/vpu/ - # Install i.MX 95 VPU firmware - install -m 0644 ${S}/firmware/vpu/wave633c_codec_fw.bin ${D}${nonarch_base_libdir}/firmware -} - -# -# This prepend is here to produce separate packages containing firmware, -# which could be included separately based on the machine definition. -# -# It operates similar to the FILES mechanism by travesing through -# ${D} + folder supplied as a first parameter, matches the regexp supplied -# as second one, and for every file match - it creates a separate package, -# which contains only files that matches the pattern. -# -python populate_packages:prepend() { - # CODA driver tries to locate VPU firmwares directly in ${nonarch_base_libdir}/firmware, to - # avoid fallback loading which is usually 40-60 seconds later after system boots up, let's - # create symbolic links in ${nonarch_base_libdir}/firmware for VPU firmwares. - def coda_vpu_links(file, pkg, pattern, format, basename): - # Only CODA VPU firmwares need this procedure - if 'imx8' in basename: - return - - dir = os.path.dirname(file) - dir = os.path.abspath(os.path.join(dir, os.pardir)) - cwd = os.getcwd() - - os.chdir(dir) - - name = os.path.basename(file) - os.symlink(os.path.join("vpu", name), name) - - oldfiles = d.getVar('FILES:' + pkg) - newfile = os.path.join(d.getVar('nonarch_base_libdir'), "firmware", name) - d.setVar('FILES:' + pkg, oldfiles + " " + newfile) - - os.chdir(cwd) - - - easrcdir = bb.data.expand('${nonarch_base_libdir}/firmware/imx/easrc', d) - do_split_packages(d, easrcdir, r'^easrc-([^_]*).*\.bin', - output_pattern='firmware-imx-easrc-%s', - description='Freescale IMX EASRC Firmware [%s]', - extra_depends='', - prepend=True) - - vpudir = bb.data.expand('${nonarch_base_libdir}/firmware/vpu', d) - do_split_packages(d, vpudir, r'^vpu_fw_([^_]*).*\.bin', - output_pattern='firmware-imx-vpu-%s', - description='Freescale IMX VPU Firmware [%s]', - hook=coda_vpu_links, - extra_depends='', - prepend=True) - - sdmadir = bb.data.expand('${nonarch_base_libdir}/firmware/imx/sdma', d) - do_split_packages(d, sdmadir, r'^sdma-([^-]*).*\.bin', - output_pattern='firmware-imx-sdma-%s', - description='Freescale IMX SDMA Firmware [%s]', - extra_depends='', - prepend=True) - - xcvrdir = bb.data.expand('${nonarch_base_libdir}/firmware/imx/xcvr', d) - do_split_packages(d, xcvrdir, r'^xcvr-([^_]*).*\.bin', - output_pattern='firmware-imx-xcvr-%s', - description='Freescale IMX XCVR Firmware [%s]', - extra_depends='', - prepend=True) - - xuvidir = bb.data.expand('${nonarch_base_libdir}/firmware/imx/xuvi', d) - do_split_packages(d, xuvidir, r'^vpu_fw_([^_]*).*\.bin', - output_pattern='firmware-imx-xuvi-%s', - description='Freescale IMX XUVI Firmware [%s]', - extra_depends='', - prepend=True) -} - -# Declare a contract that we would provide packages produced by prepend above -PACKAGES_DYNAMIC = "${PN}-vpu-* ${PN}-sdma-* ${PN}-easrc-* ${PN}-xcvr-* ${PN}-xuvi-*" - -# -# Deal with the rest of Firmware packages here -# -# Provide EPDC and HDMI Firmware in common packages as they tend to be special in -# terms of the content. -# -# NOTE: PACKAGES are defined explicitly here in order to remove the auto-generated -# complimentary packages (-dev and -dbg). -# This is done in order to be able to keep the main package empty and fail when -# somebody tries to install it in the image. -# If -dev package is present in that setup, and dev-pkgs is enabled in -# IMAGE_FEATURES - this leads to a failure during do_rootfs() while all -dev -# packages would be installed, and -dev package would fail because the main one -# is empty. -# Therefore, we opt-out from producing -dev package here, since also for firmware -# files it makes no sense. -PACKAGES = "${PN} ${PN}-epdc ${PN}-hdmi ${PN}-vpu-amphion ${PN}-vpu-wave" - -FILES:${PN}-epdc = "${nonarch_base_libdir}/firmware/imx/epdc/" -FILES:${PN}-hdmi = " \ - ${nonarch_base_libdir}/firmware/hdmitxfw.bin \ - ${nonarch_base_libdir}/firmware/hdmirxfw.bin \ - ${nonarch_base_libdir}/firmware/dpfw.bin \ -" -FILES:${PN}-vpu-amphion = "${nonarch_base_libdir}/firmware/amphion/vpu/*" -FILES:${PN}-vpu-wave = "${nonarch_base_libdir}/firmware/wave633c_codec_fw.bin" - -COMPATIBLE_MACHINE = "(imx-generic-bsp)" diff --git a/recipes-bsp/firmware-imx/firmware-imx_8.27.bb b/recipes-bsp/firmware-imx/firmware-imx_8.27.bb new file mode 100644 index 00000000..7bac8106 --- /dev/null +++ b/recipes-bsp/firmware-imx/firmware-imx_8.27.bb @@ -0,0 +1,171 @@ +# Copyright (C) 2012-2016 Freescale Semiconductor +# Copyright 2017-2021,2024 NXP +# Copyright (C) 2018 O.S. Systems Software LTDA. +SUMMARY = "Freescale i.MX firmware" +DESCRIPTION = "Freescale i.MX firmware such as for the VPU" + +require ${BP}.inc + +PE = "1" + +inherit allarch + +IMX_USE_LINUX_FIRMWARE_SDMA ?= "1" + +do_install() { + install -d ${D}${nonarch_base_libdir}/firmware/imx + + # SDMA Firmware section + install -d ${D}${nonarch_base_libdir}/firmware/imx/sdma + install -m 0644 ${S}/firmware/sdma/* ${D}${nonarch_base_libdir}/firmware/imx/sdma + # Define IMX_USE_LINUX_FIRMWARE_SDMA = "0" in layer.conf, machine.conf, local.conf + # or in .bbappend to use sdma-imx6q/7d.bin from here and not linux-firmware + if [ ${IMX_USE_LINUX_FIRMWARE_SDMA} -gt 0 ] + then + rm -f ${D}${nonarch_base_libdir}/firmware/imx/sdma/sdma-imx6q.bin + rm -f ${D}${nonarch_base_libdir}/firmware/imx/sdma/sdma-imx7d.bin + fi + + # EASRC Firmware section + install -d ${D}${nonarch_base_libdir}/firmware/imx/easrc + install -m 0644 ${S}/firmware/easrc/* ${D}${nonarch_base_libdir}/firmware/imx/easrc/ + + # XCVR Firmware section + install -d ${D}${nonarch_base_libdir}/firmware/imx/xcvr + install -m 0644 ${S}/firmware/xcvr/* ${D}${nonarch_base_libdir}/firmware/imx/xcvr/ + + # XUVI Firmware section + install -d ${D}${nonarch_base_libdir}/firmware/imx/xuvi + install -m 0644 ${S}/firmware/xuvi/* ${D}${nonarch_base_libdir}/firmware/imx/xuvi/ + + # EPDC Firmware section + # NOTE: + # epdc_ED060XH2C1.fw file has .nonrestricted suffix in the source archive, hence it should + # be installed with a different name + install -d ${D}${nonarch_base_libdir}/firmware/imx/epdc + install -m 0644 ${S}/firmware/epdc/*.fw ${D}${nonarch_base_libdir}/firmware/imx/epdc/ + install -m 0644 ${S}/firmware/epdc/epdc_ED060XH2C1.fw.nonrestricted ${D}${nonarch_base_libdir}/firmware/imx/epdc/epdc_ED060XH2C1.fw + + # HDMI Firmware section + # NOTE: + # Only install pre-defined list of firmware files, since the source archive contains + # also HDMI binary files for imx8m derivatives, which are taken care of by another recipe + install -m 0644 ${S}/firmware/hdmi/cadence/hdmitxfw.bin ${D}${nonarch_base_libdir}/firmware + install -m 0644 ${S}/firmware/hdmi/cadence/hdmirxfw.bin ${D}${nonarch_base_libdir}/firmware + install -m 0644 ${S}/firmware/hdmi/cadence/dpfw.bin ${D}${nonarch_base_libdir}/firmware + + # VPU Firmware section + # NOTE: + # Do the same thing as above for HDMI - only install a pre-defined list of firmware files, + # as some of other files are provided by packages from other recipes. + install -d ${D}${nonarch_base_libdir}/firmware/vpu + install -m 0644 ${S}/firmware/vpu/vpu_fw_imx*.bin ${D}${nonarch_base_libdir}/firmware/vpu + # Update i.MX8 vpu firmware path to align with kernel6.5+ + install -d ${D}${nonarch_base_libdir}/firmware/amphion/vpu/ + mv ${D}${nonarch_base_libdir}/firmware/vpu/vpu_fw_imx8* ${D}${nonarch_base_libdir}/firmware/amphion/vpu/ + # Install i.MX 95 VPU firmware + install -m 0644 ${S}/firmware/vpu/wave633c_codec_fw.bin ${D}${nonarch_base_libdir}/firmware +} + +# +# This prepend is here to produce separate packages containing firmware, +# which could be included separately based on the machine definition. +# +# It operates similar to the FILES mechanism by travesing through +# ${D} + folder supplied as a first parameter, matches the regexp supplied +# as second one, and for every file match - it creates a separate package, +# which contains only files that matches the pattern. +# +python populate_packages:prepend() { + # CODA driver tries to locate VPU firmwares directly in ${nonarch_base_libdir}/firmware, to + # avoid fallback loading which is usually 40-60 seconds later after system boots up, let's + # create symbolic links in ${nonarch_base_libdir}/firmware for VPU firmwares. + def coda_vpu_links(file, pkg, pattern, format, basename): + # Only CODA VPU firmwares need this procedure + if 'imx8' in basename: + return + + dir = os.path.dirname(file) + dir = os.path.abspath(os.path.join(dir, os.pardir)) + cwd = os.getcwd() + + os.chdir(dir) + + name = os.path.basename(file) + os.symlink(os.path.join("vpu", name), name) + + oldfiles = d.getVar('FILES:' + pkg) + newfile = os.path.join(d.getVar('nonarch_base_libdir'), "firmware", name) + d.setVar('FILES:' + pkg, oldfiles + " " + newfile) + + os.chdir(cwd) + + + easrcdir = bb.data.expand('${nonarch_base_libdir}/firmware/imx/easrc', d) + do_split_packages(d, easrcdir, r'^easrc-([^_]*).*\.bin', + output_pattern='firmware-imx-easrc-%s', + description='Freescale IMX EASRC Firmware [%s]', + extra_depends='', + prepend=True) + + vpudir = bb.data.expand('${nonarch_base_libdir}/firmware/vpu', d) + do_split_packages(d, vpudir, r'^vpu_fw_([^_]*).*\.bin', + output_pattern='firmware-imx-vpu-%s', + description='Freescale IMX VPU Firmware [%s]', + hook=coda_vpu_links, + extra_depends='', + prepend=True) + + sdmadir = bb.data.expand('${nonarch_base_libdir}/firmware/imx/sdma', d) + do_split_packages(d, sdmadir, r'^sdma-([^-]*).*\.bin', + output_pattern='firmware-imx-sdma-%s', + description='Freescale IMX SDMA Firmware [%s]', + extra_depends='', + prepend=True) + + xcvrdir = bb.data.expand('${nonarch_base_libdir}/firmware/imx/xcvr', d) + do_split_packages(d, xcvrdir, r'^xcvr-([^_]*).*\.bin', + output_pattern='firmware-imx-xcvr-%s', + description='Freescale IMX XCVR Firmware [%s]', + extra_depends='', + prepend=True) + + xuvidir = bb.data.expand('${nonarch_base_libdir}/firmware/imx/xuvi', d) + do_split_packages(d, xuvidir, r'^vpu_fw_([^_]*).*\.bin', + output_pattern='firmware-imx-xuvi-%s', + description='Freescale IMX XUVI Firmware [%s]', + extra_depends='', + prepend=True) +} + +# Declare a contract that we would provide packages produced by prepend above +PACKAGES_DYNAMIC = "${PN}-vpu-* ${PN}-sdma-* ${PN}-easrc-* ${PN}-xcvr-* ${PN}-xuvi-*" + +# +# Deal with the rest of Firmware packages here +# +# Provide EPDC and HDMI Firmware in common packages as they tend to be special in +# terms of the content. +# +# NOTE: PACKAGES are defined explicitly here in order to remove the auto-generated +# complimentary packages (-dev and -dbg). +# This is done in order to be able to keep the main package empty and fail when +# somebody tries to install it in the image. +# If -dev package is present in that setup, and dev-pkgs is enabled in +# IMAGE_FEATURES - this leads to a failure during do_rootfs() while all -dev +# packages would be installed, and -dev package would fail because the main one +# is empty. +# Therefore, we opt-out from producing -dev package here, since also for firmware +# files it makes no sense. +PACKAGES = "${PN} ${PN}-epdc ${PN}-hdmi ${PN}-vpu-amphion ${PN}-vpu-wave" + +FILES:${PN}-epdc = "${nonarch_base_libdir}/firmware/imx/epdc/" +FILES:${PN}-hdmi = " \ + ${nonarch_base_libdir}/firmware/hdmitxfw.bin \ + ${nonarch_base_libdir}/firmware/hdmirxfw.bin \ + ${nonarch_base_libdir}/firmware/dpfw.bin \ +" +FILES:${PN}-vpu-amphion = "${nonarch_base_libdir}/firmware/amphion/vpu/*" +FILES:${PN}-vpu-wave = "${nonarch_base_libdir}/firmware/wave633c_codec_fw.bin" + +COMPATIBLE_MACHINE = "(imx-generic-bsp)" diff --git a/recipes-bsp/firmware-imx/imx-boot-firmware-files_8.26.bb b/recipes-bsp/firmware-imx/imx-boot-firmware-files_8.26.bb deleted file mode 100644 index c35e31e0..00000000 --- a/recipes-bsp/firmware-imx/imx-boot-firmware-files_8.26.bb +++ /dev/null @@ -1,61 +0,0 @@ -# Copyright (C) 2018-2024 NXP -SUMMARY = "Freescale i.MX Firmware files used for boot" - -require firmware-imx-${PV}.inc - -inherit deploy nopackages - -do_install[noexec] = "1" - -DEPLOY_FOR = "" -DEPLOY_FOR:mx8-generic-bsp = "mx8" -DEPLOY_FOR:mx8m-generic-bsp = "mx8m" -DEPLOY_FOR:mx9-generic-bsp = "mx9" - -deploy_for_mx8() { - # Cadence HDMI - install -m 0644 ${S}/firmware/hdmi/cadence/hdmitxfw.bin ${DEPLOYDIR} - install -m 0644 ${S}/firmware/hdmi/cadence/hdmirxfw.bin ${DEPLOYDIR} - install -m 0644 ${S}/firmware/hdmi/cadence/dpfw.bin ${DEPLOYDIR} -} - -deploy_for_mx8m() { - # Synopsys DDR - for ddr_firmware in ${DDR_FIRMWARE_NAME}; do - install -m 0644 ${S}/firmware/ddr/synopsys/${ddr_firmware} ${DEPLOYDIR} - done - - # Cadence DP and HDMI - install -m 0644 ${S}/firmware/hdmi/cadence/signed_dp_imx8m.bin ${DEPLOYDIR} - install -m 0644 ${S}/firmware/hdmi/cadence/signed_hdmi_imx8m.bin ${DEPLOYDIR} -} - - -deploy_for_mx9() { - # Synopsys DDR - for ddr_firmware in ${DDR_FIRMWARE_NAME}; do - install -m 0644 ${S}/firmware/ddr/synopsys/${ddr_firmware} ${DEPLOYDIR} - done -} - -python () { - # Manually add the required functions as dependencies otherwise they won't be included in the - # final run script. - deploy_for = d.getVar('DEPLOY_FOR', True).split() - for soc in deploy_for: - d.appendVarFlag('do_deploy', 'vardeps', ' deploy_for_%s' % soc) -} - -do_deploy () { - for soc in ${DEPLOY_FOR}; do - bbnote "Running deploy for $soc" - deploy_for_$soc - done -} - -addtask deploy after do_install before do_build - -PACKAGE_ARCH = "${MACHINE_SOCARCH}" - -COMPATIBLE_MACHINE = "(mx8-generic-bsp|mx9-generic-bsp)" -COMPATIBLE_MACHINE:mx8x-generic-bsp = "(^$)" diff --git a/recipes-bsp/firmware-imx/imx-boot-firmware-files_8.27.bb b/recipes-bsp/firmware-imx/imx-boot-firmware-files_8.27.bb new file mode 100644 index 00000000..c35e31e0 --- /dev/null +++ b/recipes-bsp/firmware-imx/imx-boot-firmware-files_8.27.bb @@ -0,0 +1,61 @@ +# Copyright (C) 2018-2024 NXP +SUMMARY = "Freescale i.MX Firmware files used for boot" + +require firmware-imx-${PV}.inc + +inherit deploy nopackages + +do_install[noexec] = "1" + +DEPLOY_FOR = "" +DEPLOY_FOR:mx8-generic-bsp = "mx8" +DEPLOY_FOR:mx8m-generic-bsp = "mx8m" +DEPLOY_FOR:mx9-generic-bsp = "mx9" + +deploy_for_mx8() { + # Cadence HDMI + install -m 0644 ${S}/firmware/hdmi/cadence/hdmitxfw.bin ${DEPLOYDIR} + install -m 0644 ${S}/firmware/hdmi/cadence/hdmirxfw.bin ${DEPLOYDIR} + install -m 0644 ${S}/firmware/hdmi/cadence/dpfw.bin ${DEPLOYDIR} +} + +deploy_for_mx8m() { + # Synopsys DDR + for ddr_firmware in ${DDR_FIRMWARE_NAME}; do + install -m 0644 ${S}/firmware/ddr/synopsys/${ddr_firmware} ${DEPLOYDIR} + done + + # Cadence DP and HDMI + install -m 0644 ${S}/firmware/hdmi/cadence/signed_dp_imx8m.bin ${DEPLOYDIR} + install -m 0644 ${S}/firmware/hdmi/cadence/signed_hdmi_imx8m.bin ${DEPLOYDIR} +} + + +deploy_for_mx9() { + # Synopsys DDR + for ddr_firmware in ${DDR_FIRMWARE_NAME}; do + install -m 0644 ${S}/firmware/ddr/synopsys/${ddr_firmware} ${DEPLOYDIR} + done +} + +python () { + # Manually add the required functions as dependencies otherwise they won't be included in the + # final run script. + deploy_for = d.getVar('DEPLOY_FOR', True).split() + for soc in deploy_for: + d.appendVarFlag('do_deploy', 'vardeps', ' deploy_for_%s' % soc) +} + +do_deploy () { + for soc in ${DEPLOY_FOR}; do + bbnote "Running deploy for $soc" + deploy_for_$soc + done +} + +addtask deploy after do_install before do_build + +PACKAGE_ARCH = "${MACHINE_SOCARCH}" + +COMPATIBLE_MACHINE = "(mx8-generic-bsp|mx9-generic-bsp)" +COMPATIBLE_MACHINE:mx8x-generic-bsp = "(^$)" -- cgit v1.2.3-54-g00ecf