diff options
| author | Mark Hatle <mark.hatle@xilinx.com> | 2021-12-15 13:52:16 -0800 |
|---|---|---|
| committer | Mark Hatle <mark.hatle@xilinx.com> | 2022-01-14 15:37:02 -0800 |
| commit | f900c6a0c8908e370689235230094308ec419cf9 (patch) | |
| tree | bd9ca83e452c263c7a421b826086048cf8130f34 /meta-xilinx-standalone-experimental | |
| parent | aaddcc3f785404da04af9ea3d005f2f520b4ec9e (diff) | |
| download | meta-xilinx-f900c6a0c8908e370689235230094308ec419cf9.tar.gz | |
Initial restructure/split of meta-xilinx-bsp
Create a new meta-xilinx-core, move core functionality to the core, keeping
board specific files in the bsp layer.
zynqmp-generic changed from require <board> to include, so if meta-xilinx-bsp
is not available it will not fail.
Signed-off-by: Mark Hatle <mark.hatle@xilinx.com>
Diffstat (limited to 'meta-xilinx-standalone-experimental')
3 files changed, 41 insertions, 30 deletions
diff --git a/meta-xilinx-standalone-experimental/classes/esw_examples.bbclass b/meta-xilinx-standalone-experimental/classes/esw_examples.bbclass index ea93f715..3ae01ac1 100644 --- a/meta-xilinx-standalone-experimental/classes/esw_examples.bbclass +++ b/meta-xilinx-standalone-experimental/classes/esw_examples.bbclass | |||
| @@ -26,8 +26,8 @@ do_install() { | |||
| 26 | } | 26 | } |
| 27 | 27 | ||
| 28 | do_deploy() { | 28 | do_deploy() { |
| 29 | install -d ${DEPLOYDIR}/${MACHINE}-${BPN}/ | 29 | install -d ${DEPLOYDIR}/ |
| 30 | install -Dm 0644 ${WORKDIR}/package/${base_libdir}/firmware/*.elf ${DEPLOYDIR}/${MACHINE}-${BPN}/ | 30 | install -Dm 0644 ${WORKDIR}/package/${base_libdir}/firmware/*.elf ${DEPLOYDIR}/ |
| 31 | } | 31 | } |
| 32 | addtask deploy before do_build after do_package | 32 | addtask deploy before do_build after do_package |
| 33 | 33 | ||
diff --git a/meta-xilinx-standalone-experimental/recipes-core/meta/files/README-setup b/meta-xilinx-standalone-experimental/recipes-core/meta/files/README-setup index 5a01c33e..88046966 100644 --- a/meta-xilinx-standalone-experimental/recipes-core/meta/files/README-setup +++ b/meta-xilinx-standalone-experimental/recipes-core/meta/files/README-setup | |||
| @@ -32,10 +32,10 @@ however you may use any path you wish. | |||
| 32 | . <build>/prestep/environment-setup-x86_64-petalinux-linux | 32 | . <build>/prestep/environment-setup-x86_64-petalinux-linux |
| 33 | 33 | ||
| 34 | # Run the script from the same directory as this README | 34 | # Run the script from the same directory as this README |
| 35 | <build>/prestep/dt-processor.sh <path_to_conf> <dtb> | 35 | <build>/prestep/dt-processor.sh -c <conf> -s <dtb> |
| 36 | 36 | ||
| 37 | # For example, zynqmp: | 37 | # For example, zynqmp: |
| 38 | # <build>/prestep/dt-processor.sh <build>/conf <device-tree>/zu-sdt/system-top.dts | 38 | # <build>/prestep/dt-processor.sh -c <build>/conf -s <device-tree>/zu-sdt/system-top.dts |
| 39 | # | 39 | # |
| 40 | # Follow the instructions returned by the script! | 40 | # Follow the instructions returned by the script! |
| 41 | # Such as: | 41 | # Such as: |
| @@ -61,7 +61,7 @@ PMU_FIRMWARE_DEPLOY_DIR = "${BASE_TMPDIR}/tmp-microblaze-pmu/deploy/images/${MAC | |||
| 61 | # OR | 61 | # OR |
| 62 | # | 62 | # |
| 63 | # Versal: | 63 | # Versal: |
| 64 | # <build>/prestep/dt-processor.sh <build>/conf <device-tree>/vck190-sdt/system-top.dts | 64 | # <build>/prestep/dt-processor.sh -c <build>/conf -s <device-tree>/vck190-sdt/system-top.dts |
| 65 | # | 65 | # |
| 66 | # Follow the instructions returned by the script! | 66 | # Follow the instructions returned by the script! |
| 67 | # Such as: | 67 | # Such as: |
diff --git a/meta-xilinx-standalone-experimental/recipes-core/meta/files/dt-processor.sh b/meta-xilinx-standalone-experimental/recipes-core/meta/files/dt-processor.sh index 243a2cfd..a8da5b4a 100755 --- a/meta-xilinx-standalone-experimental/recipes-core/meta/files/dt-processor.sh +++ b/meta-xilinx-standalone-experimental/recipes-core/meta/files/dt-processor.sh | |||
| @@ -89,7 +89,7 @@ detect_machine() { | |||
| 89 | } | 89 | } |
| 90 | 90 | ||
| 91 | cortex_a53_linux() { | 91 | cortex_a53_linux() { |
| 92 | info "coretex-a53 for Linux [ $1 ]" | 92 | info "cortex-a53 for Linux [ $1 ]" |
| 93 | 93 | ||
| 94 | if [ "$1" = "None" ]; then | 94 | if [ "$1" = "None" ]; then |
| 95 | dtb_file="cortexa53-${machine}-linux.dtb" | 95 | dtb_file="cortexa53-${machine}-linux.dtb" |
| @@ -130,11 +130,11 @@ cortex_a53_linux() { | |||
| 130 | CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" | 130 | CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" |
| 131 | MACHINE = "${machine}-generic" | 131 | MACHINE = "${machine}-generic" |
| 132 | # Override the SYSTEM_DTFILE for Linux builds | 132 | # Override the SYSTEM_DTFILE for Linux builds |
| 133 | SYSTEM_DTFILE_linux = "\${CONFIG_DTFILE}" | 133 | SYSTEM_DTFILE:linux = "\${CONFIG_DTFILE}" |
| 134 | # We don't want the kernel to build us a device-tree | 134 | # We don't want the kernel to build us a device-tree |
| 135 | KERNEL_DEVICETREE_${machine}-generic = "" | 135 | KERNEL_DEVICETREE:${machine}-generic = "" |
| 136 | # We need u-boot to use the one we passed in | 136 | # We need u-boot to use the one we passed in |
| 137 | DEVICE_TREE_NAME_pn-u-boot-zynq-scr = "\${@os.path.basename(d.getVar('CONFIG_DTFILE'))}" | 137 | DEVICE_TREE_NAME:pn-u-boot-zynq-scr = "\${@os.path.basename(d.getVar('CONFIG_DTFILE'))}" |
| 138 | # Update bootbin to use proper device tree | 138 | # Update bootbin to use proper device tree |
| 139 | BIF_PARTITION_IMAGE[device-tree] = "\${RECIPE_SYSROOT}/boot/devicetree/\${@os.path.basename(d.getVar('CONFIG_DTFILE'))}" | 139 | BIF_PARTITION_IMAGE[device-tree] = "\${RECIPE_SYSROOT}/boot/devicetree/\${@os.path.basename(d.getVar('CONFIG_DTFILE'))}" |
| 140 | # Remap boot files to ensure the right device tree is listed first | 140 | # Remap boot files to ensure the right device tree is listed first |
| @@ -146,9 +146,9 @@ a53_fsbl_done=0 | |||
| 146 | cortex_a53_baremetal() { | 146 | cortex_a53_baremetal() { |
| 147 | if [ "$1" = "fsbl" ]; then | 147 | if [ "$1" = "fsbl" ]; then |
| 148 | [ ${a53_fsbl_done} = 1 ] && return | 148 | [ ${a53_fsbl_done} = 1 ] && return |
| 149 | info "coretex-a53 FSBL baremetal configuration" | 149 | info "cortex-a53 FSBL baremetal configuration" |
| 150 | else | 150 | else |
| 151 | info "coretex-a53 for baremetal [ $1 ]" | 151 | info "cortex-a53 for baremetal [ $1 ]" |
| 152 | fi | 152 | fi |
| 153 | 153 | ||
| 154 | suffix=""; lto="-nolto" | 154 | suffix=""; lto="-nolto" |
| @@ -210,7 +210,7 @@ EOF | |||
| 210 | } | 210 | } |
| 211 | 211 | ||
| 212 | cortex_a53_freertos() { | 212 | cortex_a53_freertos() { |
| 213 | info "coretex-a53 for FreeRTOS [ $1 ]" | 213 | info "cortex-a53 for FreeRTOS [ $1 ]" |
| 214 | 214 | ||
| 215 | suffix="" | 215 | suffix="" |
| 216 | [ "$1" != "None" ] && suffix="-$1" | 216 | [ "$1" != "None" ] && suffix="-$1" |
| @@ -262,7 +262,7 @@ EOF | |||
| 262 | } | 262 | } |
| 263 | 263 | ||
| 264 | cortex_a72_linux() { | 264 | cortex_a72_linux() { |
| 265 | info "coretex-a72 for Linux [ $1 ]" | 265 | info "cortex-a72 for Linux [ $1 ]" |
| 266 | 266 | ||
| 267 | if [ "$1" = "None" ]; then | 267 | if [ "$1" = "None" ]; then |
| 268 | dtb_file="cortexa72-${machine}-linux.dtb" | 268 | dtb_file="cortexa72-${machine}-linux.dtb" |
| @@ -305,11 +305,11 @@ cortex_a72_linux() { | |||
| 305 | CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" | 305 | CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" |
| 306 | MACHINE = "${machine}-generic" | 306 | MACHINE = "${machine}-generic" |
| 307 | # Override the SYSTEM_DTFILE for Linux builds | 307 | # Override the SYSTEM_DTFILE for Linux builds |
| 308 | SYSTEM_DTFILE_linux = "\${CONFIG_DTFILE}" | 308 | SYSTEM_DTFILE:linux = "\${CONFIG_DTFILE}" |
| 309 | # We don't want the kernel to build us a device-tree | 309 | # We don't want the kernel to build us a device-tree |
| 310 | KERNEL_DEVICETREE_${machine}-generic = "" | 310 | KERNEL_DEVICETREE:${machine}-generic = "" |
| 311 | # We need u-boot to use the one we passed in | 311 | # We need u-boot to use the one we passed in |
| 312 | DEVICE_TREE_NAME_pn-u-boot-zynq-scr = "\${@os.path.basename(d.getVar('CONFIG_DTFILE'))}" | 312 | DEVICE_TREE_NAME:pn-u-boot-zynq-scr = "\${@os.path.basename(d.getVar('CONFIG_DTFILE'))}" |
| 313 | # Update bootbin to use proper device tree | 313 | # Update bootbin to use proper device tree |
| 314 | BIF_PARTITION_IMAGE[device-tree] = "\${RECIPE_SYSROOT}/boot/devicetree/\${@os.path.basename(d.getVar('CONFIG_DTFILE'))}" | 314 | BIF_PARTITION_IMAGE[device-tree] = "\${RECIPE_SYSROOT}/boot/devicetree/\${@os.path.basename(d.getVar('CONFIG_DTFILE'))}" |
| 315 | # Remap boot files to ensure the right device tree is listed first | 315 | # Remap boot files to ensure the right device tree is listed first |
| @@ -318,7 +318,7 @@ EOF | |||
| 318 | } | 318 | } |
| 319 | 319 | ||
| 320 | cortex_a72_baremetal() { | 320 | cortex_a72_baremetal() { |
| 321 | info "coretex-a72 for baremetal [ $1 ]" | 321 | info "cortex-a72 for baremetal [ $1 ]" |
| 322 | 322 | ||
| 323 | suffix="" | 323 | suffix="" |
| 324 | [ "$1" != "None" ] && suffix="-$1" | 324 | [ "$1" != "None" ] && suffix="-$1" |
| @@ -370,7 +370,7 @@ EOF | |||
| 370 | } | 370 | } |
| 371 | 371 | ||
| 372 | cortex_a72_freertos() { | 372 | cortex_a72_freertos() { |
| 373 | info "coretex-a72 for FreeRTOS [ $1 ]" | 373 | info "cortex-a72 for FreeRTOS [ $1 ]" |
| 374 | 374 | ||
| 375 | suffix="" | 375 | suffix="" |
| 376 | [ "$1" != "None" ] && suffix="-$1" | 376 | [ "$1" != "None" ] && suffix="-$1" |
| @@ -425,9 +425,9 @@ r5_fsbl_done=0 | |||
| 425 | cortex_r5_baremetal() { | 425 | cortex_r5_baremetal() { |
| 426 | if [ "$1" = "fsbl" ]; then | 426 | if [ "$1" = "fsbl" ]; then |
| 427 | [ ${r5_fsbl_done} = 1 ] && return | 427 | [ ${r5_fsbl_done} = 1 ] && return |
| 428 | info "coretex-r5 FSBL baremetal configuration" | 428 | info "cortex-r5 FSBL baremetal configuration" |
| 429 | else | 429 | else |
| 430 | info "coretex-r5 for baremetal [ $1 ]" | 430 | info "cortex-r5 for baremetal [ $1 ]" |
| 431 | fi | 431 | fi |
| 432 | 432 | ||
| 433 | suffix=""; lto="-nolto" | 433 | suffix=""; lto="-nolto" |
| @@ -451,14 +451,25 @@ cortex_r5_baremetal() { | |||
| 451 | # Build device tree | 451 | # Build device tree |
| 452 | ( | 452 | ( |
| 453 | cd dtb || error "Unable to cd to dtb dir" | 453 | cd dtb || error "Unable to cd to dtb dir" |
| 454 | LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -i "${lops_dir}/lop-r5-imux.dts" \ | 454 | if [ -n "$domain_file" ]; then |
| 455 | "${system_dtb}" "${dtb_file}" || error "lopper.py failed" | 455 | LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --permissive --enhanced -x '*.yaml' \ |
| 456 | -i "${domain_file}" -i "${lops_dir}/lop-r5-imux.dts" "${system_dtb}" "${dtb_file}" \ | ||
| 457 | || error "lopper.py failed" | ||
| 458 | else | ||
| 459 | LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -i "${lops_dir}/lop-r5-imux.dts" \ | ||
| 460 | "${system_dtb}" "${dtb_file}" || error "lopper.py failed" | ||
| 461 | fi | ||
| 456 | rm -f lop-r5-imux.dts.dtb | 462 | rm -f lop-r5-imux.dts.dtb |
| 457 | ) | 463 | ) |
| 458 | 464 | ||
| 459 | # Build baremetal multiconfig | 465 | # Build baremetal multiconfig |
| 460 | ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx cortexr5-${machine} "${embeddedsw}" \ | 466 | if [ -n "${domain_file}" ]; then |
| 461 | || error "lopper.py failed" | 467 | ${lopper} -f --permissive --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ |
| 468 | -- baremetaldrvlist_xlnx cortexr5-${machine} "${embeddedsw}" || error "lopper.py failed" | ||
| 469 | else | ||
| 470 | ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx cortexr5-${machine} "${embeddedsw}" \ | ||
| 471 | || error "lopper.py failed" | ||
| 472 | fi | ||
| 462 | 473 | ||
| 463 | mv libxil.conf "${libxil}" | 474 | mv libxil.conf "${libxil}" |
| 464 | mv distro.conf "${distro}" | 475 | mv distro.conf "${distro}" |
| @@ -478,7 +489,7 @@ EOF | |||
| 478 | } | 489 | } |
| 479 | 490 | ||
| 480 | cortex_r5_freertos() { | 491 | cortex_r5_freertos() { |
| 481 | info "coretex-r5 for FreeRTOS [ $1 ]" | 492 | info "cortex-r5 for FreeRTOS [ $1 ]" |
| 482 | 493 | ||
| 483 | suffix="" | 494 | suffix="" |
| 484 | [ "$1" != "None" ] && suffix="-$1" | 495 | [ "$1" != "None" ] && suffix="-$1" |
| @@ -506,7 +517,7 @@ cortex_r5_freertos() { | |||
| 506 | # Build baremetal multiconfig | 517 | # Build baremetal multiconfig |
| 507 | if [ -n "${domain_file}" ]; then | 518 | if [ -n "${domain_file}" ]; then |
| 508 | ${lopper} -f --permissive --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ | 519 | ${lopper} -f --permissive --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ |
| 509 | -- baremetaldrvlist_xlnx coretexr5-${machine} "${embeddedsw}" || error "lopper.py failed" | 520 | -- baremetaldrvlist_xlnx cortexr5-${machine} "${embeddedsw}" || error "lopper.py failed" |
| 510 | else | 521 | else |
| 511 | ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx cortexr5-${machine} "${embeddedsw}" \ | 522 | ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx cortexr5-${machine} "${embeddedsw}" \ |
| 512 | || error "lopper.py failed" | 523 | || error "lopper.py failed" |
| @@ -585,7 +596,7 @@ ESW_MACHINE = "microblaze-pmu" | |||
| 585 | 596 | ||
| 586 | require conf/microblaze.conf | 597 | require conf/microblaze.conf |
| 587 | DEFAULTTUNE = "microblaze" | 598 | DEFAULTTUNE = "microblaze" |
| 588 | TUNE_FEATURES_tune-microblaze_forcevariable = "\${TUNE_FEATURES_tune-pmu-microblaze}" | 599 | TUNE_FEATURES:tune-microblaze:forcevariable = "\${TUNE_FEATURES:tune-pmu-microblaze}" |
| 589 | 600 | ||
| 590 | TARGET_CFLAGS += "-DPSU_PMU=1U" | 601 | TARGET_CFLAGS += "-DPSU_PMU=1U" |
| 591 | 602 | ||
| @@ -637,7 +648,7 @@ ESW_MACHINE = "microblaze-plm" | |||
| 637 | 648 | ||
| 638 | require conf/microblaze.conf | 649 | require conf/microblaze.conf |
| 639 | DEFAULTTUNE = "microblaze" | 650 | DEFAULTTUNE = "microblaze" |
| 640 | TUNE_FEATURES_tune-microblaze_forcevariable = "\${TUNE_FEATURES_tune-pmc-microblaze}" | 651 | TUNE_FEATURES:tune-microblaze:forcevariable = "\${TUNE_FEATURES:tune-pmc-microblaze}" |
| 641 | 652 | ||
| 642 | TARGET_CFLAGS += "-DVERSAL_PLM=1" | 653 | TARGET_CFLAGS += "-DVERSAL_PLM=1" |
| 643 | 654 | ||
| @@ -689,7 +700,7 @@ ESW_MACHINE = "microblaze-psm" | |||
| 689 | 700 | ||
| 690 | require conf/microblaze.conf | 701 | require conf/microblaze.conf |
| 691 | DEFAULTTUNE = "microblaze" | 702 | DEFAULTTUNE = "microblaze" |
| 692 | TUNE_FEATURES_tune-microblaze_forcevariable = "\${TUNE_FEATURES_tune-psm-microblaze}" | 703 | TUNE_FEATURES:tune-microblaze:forcevariable = "\${TUNE_FEATURES:tune-psm-microblaze}" |
| 693 | 704 | ||
| 694 | TARGET_CFLAGS += "-DVERSAL_psm=1" | 705 | TARGET_CFLAGS += "-DVERSAL_psm=1" |
| 695 | 706 | ||
| @@ -808,7 +819,7 @@ gen_local_conf() { | |||
| 808 | echo "To enable this, add the following to your local.conf:" | 819 | echo "To enable this, add the following to your local.conf:" |
| 809 | echo | 820 | echo |
| 810 | echo "# Adjust BASE_TMPDIR if you want to move the tmpdirs elsewhere" | 821 | echo "# Adjust BASE_TMPDIR if you want to move the tmpdirs elsewhere" |
| 811 | echo "BASE_TMPDIR = \"${TOPDIR}\"" | 822 | echo "BASE_TMPDIR = \"\${TOPDIR}\"" |
| 812 | [ -n "${system_conf}" ] && echo "require ${system_conf}" | 823 | [ -n "${system_conf}" ] && echo "require ${system_conf}" |
| 813 | echo "SYSTEM_DTFILE = \"${system_dtb}\"" | 824 | echo "SYSTEM_DTFILE = \"${system_dtb}\"" |
| 814 | echo "BBMULTICONFIG += \"${multiconf}\"" | 825 | echo "BBMULTICONFIG += \"${multiconf}\"" |
