summaryrefslogtreecommitdiffstats
path: root/meta-xilinx-standalone-experimental/recipes-core
diff options
context:
space:
mode:
authorAppana Durga Kedareswara rao <appana.durga.kedareswara.rao@amd.com>2022-11-15 17:33:03 +0530
committerMark Hatle <mark.hatle@amd.com>2022-11-21 11:03:23 -0600
commit0ba2651d60275333125efad9456e7b6b484bbf3d (patch)
tree094e2b54337bb6b07df3c031410bea3ab115b8d3 /meta-xilinx-standalone-experimental/recipes-core
parent4921181108bec2d765d847555026ecf1ba09cb8e (diff)
downloadmeta-xilinx-0ba2651d60275333125efad9456e7b6b484bbf3d.tar.gz
meta-xilinx-standalone-experimental: Update as per latest lopper updates
lopper baremeal assists got updated to take cpu name as input instead of yocto machine name this commit updates the dt-processor.sh script for the same, and also adds support for generating mulit config machine for Other processor cores (Cortexr5-1 etc...) Signed-off-by: Appana Durga Kedareswara rao <appana.durga.kedareswara.rao@amd.com> Signed-off-by: Mark Hatle <mark.hatle@amd.com>
Diffstat (limited to 'meta-xilinx-standalone-experimental/recipes-core')
-rwxr-xr-xmeta-xilinx-standalone-experimental/recipes-core/meta/files/dt-processor.sh190
1 files changed, 102 insertions, 88 deletions
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 fab16393..67722bfe 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
@@ -91,7 +91,7 @@ parse_args() {
91detect_machine() { 91detect_machine() {
92 if [ -z "${machine}" ]; then 92 if [ -z "${machine}" ]; then
93 # Identify the system type first using PSM/PMC/PMU 93 # Identify the system type first using PSM/PMC/PMU
94 while read -r cpu domain os_hint; do 94 while read -r cpu core domain cpu_name os_hint; do
95 case ${cpu} in 95 case ${cpu} in
96 pmu-microblaze) 96 pmu-microblaze)
97 machine="zynqmp" ;; 97 machine="zynqmp" ;;
@@ -188,7 +188,7 @@ cortex_a53_baremetal() {
188 [ ${a53_fsbl_done} = 1 ] && return 188 [ ${a53_fsbl_done} = 1 ] && return
189 info "cortex-a53 FSBL baremetal configuration" 189 info "cortex-a53 FSBL baremetal configuration"
190 else 190 else
191 info "cortex-a53 for baremetal [ $1 ]" 191 info "cortex-a53 baremetal configuration for core $2 [ $1 ]"
192 fi 192 fi
193 193
194 suffix=""; lto="-nolto" 194 suffix=""; lto="-nolto"
@@ -196,9 +196,9 @@ cortex_a53_baremetal() {
196 suffix="-$1"; lto="" 196 suffix="-$1"; lto=""
197 fi 197 fi
198 198
199 dtb_file="cortexa53-${machine}${suffix}-baremetal.dtb" 199 dtb_file="cortexa53-$2-${machine}${suffix}-baremetal.dtb"
200 multiconf="${multiconf} cortexa53-${machine}${suffix}-baremetal" 200 multiconf="${multiconf} cortexa53-$2-${machine}${suffix}-baremetal"
201 conf_file="multiconfig/cortexa53-${machine}${suffix}-baremetal.conf" 201 conf_file="multiconfig/cortexa53-$2-${machine}${suffix}-baremetal.conf"
202 libxil="multiconfig/includes/cortexa53-${machine}${suffix}-libxil.conf" 202 libxil="multiconfig/includes/cortexa53-${machine}${suffix}-libxil.conf"
203 distro="multiconfig/includes/cortexa53-${machine}${suffix}-distro.conf" 203 distro="multiconfig/includes/cortexa53-${machine}${suffix}-distro.conf"
204 yocto_distro="xilinx-standalone${lto}" 204 yocto_distro="xilinx-standalone${lto}"
@@ -224,11 +224,11 @@ cortex_a53_baremetal() {
224 224
225 # Build baremetal multiconfig 225 # Build baremetal multiconfig
226 if [ -n "${domain_file}" ]; then 226 if [ -n "${domain_file}" ]; then
227 ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ 227 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \
228 -- baremetaldrvlist_xlnx cortexa53-${machine} "${embeddedsw}" \ 228 -- baremetaldrvlist_xlnx $3 "${embeddedsw}" \
229 || error "lopper failed" 229 || error "lopper failed"
230 else 230 else
231 ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx cortexa53-${machine} "${embeddedsw}" \ 231 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx $3 "${embeddedsw}" \
232 || error "lopper failed" 232 || error "lopper failed"
233 fi 233 fi
234 234
@@ -253,7 +253,7 @@ EOF
253CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" 253CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}"
254CONFIG_DTFILE[vardepsexclude] += "TOPDIR" 254CONFIG_DTFILE[vardepsexclude] += "TOPDIR"
255 255
256ESW_MACHINE = "cortexa53-${machine}" 256ESW_MACHINE = "$3"
257DEFAULTTUNE = "cortexa53" 257DEFAULTTUNE = "cortexa53"
258 258
259TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}" 259TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}"
@@ -270,14 +270,14 @@ EOF
270} 270}
271 271
272cortex_a53_freertos() { 272cortex_a53_freertos() {
273 info "cortex-a53 for FreeRTOS [ $1 ]" 273 info "cortex-a53 FreeRTOS configuration for core $2 [ $1 ]"
274 274
275 suffix="" 275 suffix=""
276 [ "$1" != "None" ] && suffix="-$1" 276 [ "$1" != "None" ] && suffix="-$1"
277 277
278 dtb_file="cortexa53-${machine}${suffix}-freertos.dtb" 278 dtb_file="cortexa53-${machine}${suffix}-freertos.dtb"
279 multiconf="${multiconf} cortexa53-${machine}${suffix}-freertos" 279 multiconf="${multiconf} cortexa53-$2-${machine}${suffix}-freertos"
280 conf_file="multiconfig/cortexa53-${machine}${suffix}-freertos.conf" 280 conf_file="multiconfig/cortexa53-$2-${machine}${suffix}-freertos.conf"
281 libxil="multiconfig/includes/cortexa53-${machine}${suffix}-libxil.conf" 281 libxil="multiconfig/includes/cortexa53-${machine}${suffix}-libxil.conf"
282 distro="multiconfig/includes/cortexa53-${machine}${suffix}-distro.conf" 282 distro="multiconfig/includes/cortexa53-${machine}${suffix}-distro.conf"
283 283
@@ -297,10 +297,10 @@ cortex_a53_freertos() {
297 297
298 # Build baremetal multiconfig 298 # Build baremetal multiconfig
299 if [ -n "${domain_file}" ]; then 299 if [ -n "${domain_file}" ]; then
300 ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ 300 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \
301 -- baremetaldrvlist_xlnx cortexa53-${machine} "${embeddedsw}" || error "lopper failed" 301 -- baremetaldrvlist_xlnx $3 "${embeddedsw}" || error "lopper failed"
302 else 302 else
303 ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx cortexa53-${machine} "${embeddedsw}" \ 303 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx $3 "${embeddedsw}" \
304 || error "lopper failed" 304 || error "lopper failed"
305 fi 305 fi
306 306
@@ -311,7 +311,7 @@ cortex_a53_freertos() {
311CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" 311CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}"
312CONFIG_DTFILE[vardepsexclude] += "TOPDIR" 312CONFIG_DTFILE[vardepsexclude] += "TOPDIR"
313 313
314ESW_MACHINE = "cortexa53-${machine}" 314ESW_MACHINE = "$3"
315DEFAULTTUNE = "cortexa53" 315DEFAULTTUNE = "cortexa53"
316 316
317TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}" 317TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}"
@@ -409,14 +409,14 @@ EOF
409} 409}
410 410
411cortex_a72_baremetal() { 411cortex_a72_baremetal() {
412 info "cortex-a72 for baremetal [ $1 ]" 412 info "cortex-a72 baremetal configuration for core $2 [ $1 ]"
413 413
414 suffix="" 414 suffix=""
415 [ "$1" != "None" ] && suffix="-$1" 415 [ "$1" != "None" ] && suffix="-$1"
416 416
417 dtb_file="cortexa72-${machine}${suffix}-baremetal.dtb" 417 dtb_file="cortexa72-$2-${machine}${suffix}-baremetal.dtb"
418 multiconf="${multiconf} cortexa72-${machine}${suffix}-baremetal" 418 multiconf="${multiconf} cortexa72-$2-${machine}${suffix}-baremetal"
419 conf_file="multiconfig/cortexa72-${machine}${suffix}-baremetal.conf" 419 conf_file="multiconfig/cortexa72-$2-${machine}${suffix}-baremetal.conf"
420 libxil="multiconfig/includes/cortexa72-${machine}${suffix}-libxil.conf" 420 libxil="multiconfig/includes/cortexa72-${machine}${suffix}-libxil.conf"
421 distro="multiconfig/includes/cortexa72-${machine}${suffix}-distro.conf" 421 distro="multiconfig/includes/cortexa72-${machine}${suffix}-distro.conf"
422 422
@@ -436,10 +436,10 @@ cortex_a72_baremetal() {
436 436
437 # Build baremetal multiconfig 437 # Build baremetal multiconfig
438 if [ -n "${domain_file}" ]; then 438 if [ -n "${domain_file}" ]; then
439 ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ 439 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \
440 -- baremetaldrvlist_xlnx cortexa72-${machine} "${embeddedsw}" || error "lopper failed" 440 -- baremetaldrvlist_xlnx $3 "${embeddedsw}" || error "lopper failed"
441 else 441 else
442 ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx cortexa72-${machine} "${embeddedsw}" \ 442 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx $3 "${embeddedsw}" \
443 || error "lopper failed" 443 || error "lopper failed"
444 fi 444 fi
445 445
@@ -450,7 +450,7 @@ cortex_a72_baremetal() {
450CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" 450CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}"
451CONFIG_DTFILE[vardepsexclude] += "TOPDIR" 451CONFIG_DTFILE[vardepsexclude] += "TOPDIR"
452 452
453ESW_MACHINE = "cortexa72-${machine}" 453ESW_MACHINE = "$3"
454DEFAULTTUNE = "cortexa72" 454DEFAULTTUNE = "cortexa72"
455 455
456TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}" 456TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}"
@@ -467,14 +467,14 @@ EOF
467} 467}
468 468
469cortex_a72_freertos() { 469cortex_a72_freertos() {
470 info "cortex-a72 for FreeRTOS [ $1 ]" 470 info "cortex-a72 FreeRTOS configuration for core $2 [ $1 ]"
471 471
472 suffix="" 472 suffix=""
473 [ "$1" != "None" ] && suffix="-$1" 473 [ "$1" != "None" ] && suffix="-$1"
474 474
475 dtb_file="cortexa72-${machine}${suffix}-freertos.dtb" 475 dtb_file="cortexa72-$2-${machine}${suffix}-freertos.dtb"
476 multiconf="${multiconf} cortexa72-${machine}${suffix}-freertos" 476 multiconf="${multiconf} cortexa72-$2-${machine}${suffix}-freertos"
477 conf_file="multiconfig/cortexa72-${machine}${suffix}-freertos.conf" 477 conf_file="multiconfig/cortexa72-$2-${machine}${suffix}-freertos.conf"
478 libxil="multiconfig/includes/cortexa72-${machine}${suffix}-libxil.conf" 478 libxil="multiconfig/includes/cortexa72-${machine}${suffix}-libxil.conf"
479 distro="multiconfig/includes/cortexa72-${machine}${suffix}-distro.conf" 479 distro="multiconfig/includes/cortexa72-${machine}${suffix}-distro.conf"
480 480
@@ -494,10 +494,10 @@ cortex_a72_freertos() {
494 494
495 # Build baremetal multiconfig 495 # Build baremetal multiconfig
496 if [ -n "${domain_file}" ]; then 496 if [ -n "${domain_file}" ]; then
497 ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ 497 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \
498 -- baremetaldrvlist_xlnx cortexa72-${machine} "${embeddedsw}" || error "lopper failed" 498 -- baremetaldrvlist_xlnx $3 "${embeddedsw}" || error "lopper failed"
499 else 499 else
500 ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx cortexa72-${machine} "${embeddedsw}" \ 500 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx $3 "${embeddedsw}" \
501 || error "lopper failed" 501 || error "lopper failed"
502 fi 502 fi
503 503
@@ -508,7 +508,7 @@ cortex_a72_freertos() {
508CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" 508CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}"
509CONFIG_DTFILE[vardepsexclude] += "TOPDIR" 509CONFIG_DTFILE[vardepsexclude] += "TOPDIR"
510 510
511ESW_MACHINE = "cortexa72-${machine}" 511ESW_MACHINE = "$3"
512DEFAULTTUNE = "cortexa72" 512DEFAULTTUNE = "cortexa72"
513 513
514TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}" 514TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}"
@@ -530,7 +530,7 @@ cortex_r5_baremetal() {
530 [ ${r5_fsbl_done} = 1 ] && return 530 [ ${r5_fsbl_done} = 1 ] && return
531 info "cortex-r5 FSBL baremetal configuration" 531 info "cortex-r5 FSBL baremetal configuration"
532 else 532 else
533 info "cortex-r5 for baremetal [ $1 ]" 533 info "cortex-r5 baremetal configuration for core $2 [ $1 ]"
534 fi 534 fi
535 535
536 suffix=""; lto="-nolto" 536 suffix=""; lto="-nolto"
@@ -538,9 +538,9 @@ cortex_r5_baremetal() {
538 suffix="-$1"; lto="" 538 suffix="-$1"; lto=""
539 fi 539 fi
540 540
541 dtb_file="cortexr5-${machine}${suffix}-baremetal.dtb" 541 dtb_file="cortexr5-$2-${machine}${suffix}-baremetal.dtb"
542 multiconf="${multiconf} cortexr5-${machine}${suffix}-baremetal" 542 multiconf="${multiconf} cortexr5-$2-${machine}${suffix}-baremetal"
543 conf_file="multiconfig/cortexr5-${machine}${suffix}-baremetal.conf" 543 conf_file="multiconfig/cortexr5-$2-${machine}${suffix}-baremetal.conf"
544 libxil="multiconfig/includes/cortexr5-${machine}${suffix}-libxil.conf" 544 libxil="multiconfig/includes/cortexr5-${machine}${suffix}-libxil.conf"
545 distro="multiconfig/includes/cortexr5-${machine}${suffix}-distro.conf" 545 distro="multiconfig/includes/cortexr5-${machine}${suffix}-distro.conf"
546 yocto_distro="xilinx-standalone${lto}" 546 yocto_distro="xilinx-standalone${lto}"
@@ -567,10 +567,10 @@ cortex_r5_baremetal() {
567 567
568 # Build baremetal multiconfig 568 # Build baremetal multiconfig
569 if [ -n "${domain_file}" ]; then 569 if [ -n "${domain_file}" ]; then
570 ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ 570 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \
571 -- baremetaldrvlist_xlnx cortexr5-${machine} "${embeddedsw}" || error "lopper failed" 571 -- baremetaldrvlist_xlnx $3 "${embeddedsw}" || error "lopper failed"
572 else 572 else
573 ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx cortexr5-${machine} "${embeddedsw}" \ 573 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx $3 "${embeddedsw}" \
574 || error "lopper failed" 574 || error "lopper failed"
575 fi 575 fi
576 576
@@ -595,7 +595,7 @@ EOF
595CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" 595CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}"
596CONFIG_DTFILE[vardepsexclude] += "TOPDIR" 596CONFIG_DTFILE[vardepsexclude] += "TOPDIR"
597 597
598ESW_MACHINE = "cortexr5-${machine}" 598ESW_MACHINE = "$3"
599DEFAULTTUNE = "cortexr5" 599DEFAULTTUNE = "cortexr5"
600 600
601TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}" 601TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}"
@@ -612,14 +612,14 @@ EOF
612} 612}
613 613
614cortex_r5_freertos() { 614cortex_r5_freertos() {
615 info "cortex-r5 for FreeRTOS [ $1 ]" 615 info "cortex-r5 FreeRTOS configuration for core $2 [ $1 ]"
616 616
617 suffix="" 617 suffix=""
618 [ "$1" != "None" ] && suffix="-$1" 618 [ "$1" != "None" ] && suffix="-$1"
619 619
620 dtb_file="cortexr5-${machine}${suffix}-freertos.dtb" 620 dtb_file="cortexr5-$2-${machine}${suffix}-freertos.dtb"
621 multiconf="${multiconf} cortexr5-${machine}${suffix}-freertos" 621 multiconf="${multiconf} cortexr5-$2-${machine}${suffix}-freertos"
622 conf_file="multiconfig/cortexr5-${machine}${suffix}-freertos.conf" 622 conf_file="multiconfig/cortexr5-$2-${machine}${suffix}-freertos.conf"
623 libxil="multiconfig/includes/cortexr5-${machine}${suffix}-libxil.conf" 623 libxil="multiconfig/includes/cortexr5-${machine}${suffix}-libxil.conf"
624 distro="multiconfig/includes/cortexr5-${machine}${suffix}-distro.conf" 624 distro="multiconfig/includes/cortexr5-${machine}${suffix}-distro.conf"
625 625
@@ -639,10 +639,10 @@ cortex_r5_freertos() {
639 639
640 # Build baremetal multiconfig 640 # Build baremetal multiconfig
641 if [ -n "${domain_file}" ]; then 641 if [ -n "${domain_file}" ]; then
642 ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ 642 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \
643 -- baremetaldrvlist_xlnx cortexr5-${machine} "${embeddedsw}" || error "lopper failed" 643 -- baremetaldrvlist_xlnx $3 "${embeddedsw}" || error "lopper failed"
644 else 644 else
645 ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx cortexr5-${machine} "${embeddedsw}" \ 645 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx $3 "${embeddedsw}" \
646 || error "lopper failed" 646 || error "lopper failed"
647 fi 647 fi
648 648
@@ -653,7 +653,7 @@ cortex_r5_freertos() {
653CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" 653CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}"
654CONFIG_DTFILE[vardepsexclude] += "TOPDIR" 654CONFIG_DTFILE[vardepsexclude] += "TOPDIR"
655 655
656ESW_MACHINE = "cortexr5-${machine}" 656ESW_MACHINE = "$3"
657DEFAULTTUNE = "cortexr5" 657DEFAULTTUNE = "cortexr5"
658 658
659TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}" 659TMPDIR = "\${BASE_TMPDIR}/tmp-${dtb_file%%.dtb}"
@@ -678,7 +678,7 @@ process_microblaze() {
678 678
679 ( 679 (
680 cd dtb || error "Unable to cd to dtb dir" 680 cd dtb || error "Unable to cd to dtb dir"
681 ${lopper} -f --enhanced -i "${lops_dir}/lop-microblaze-yocto.dts" "${system_dtb}" \ 681 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -i "${lops_dir}/lop-microblaze-yocto.dts" "${system_dtb}" \
682 || error "lopper failed" 682 || error "lopper failed"
683 rm -f lop-microblaze-yocto.dts.dtb 683 rm -f lop-microblaze-yocto.dts.dtb
684 ) >microblaze.conf 684 ) >microblaze.conf
@@ -709,10 +709,10 @@ pmu-microblaze() {
709 709
710 # Build baremetal multiconfig 710 # Build baremetal multiconfig
711 if [ -n "${domain_file}" ]; then 711 if [ -n "${domain_file}" ]; then
712 ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ 712 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \
713 -- baremetaldrvlist_xlnx microblaze-pmu "${embeddedsw}" || error "lopper failed" 713 -- baremetaldrvlist_xlnx $1 "${embeddedsw}" || error "lopper failed"
714 else 714 else
715 ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx microblaze-pmu "${embeddedsw}" \ 715 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx $1 "${embeddedsw}" \
716 || error "lopper failed" 716 || error "lopper failed"
717 fi 717 fi
718 718
@@ -723,7 +723,7 @@ pmu-microblaze() {
723CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" 723CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}"
724CONFIG_DTFILE[vardepsexclude] += "TOPDIR" 724CONFIG_DTFILE[vardepsexclude] += "TOPDIR"
725 725
726ESW_MACHINE = "microblaze-pmu" 726ESW_MACHINE = "$1"
727 727
728require conf/microblaze.conf 728require conf/microblaze.conf
729DEFAULTTUNE = "microblaze" 729DEFAULTTUNE = "microblaze"
@@ -767,10 +767,10 @@ pmc-microblaze() {
767 767
768 # Build baremetal multiconfig 768 # Build baremetal multiconfig
769 if [ -n "${domain_file}" ]; then 769 if [ -n "${domain_file}" ]; then
770 ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ 770 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \
771 -- baremetaldrvlist_xlnx microblaze-plm "${embeddedsw}" || error "lopper failed" 771 -- baremetaldrvlist_xlnx $1 "${embeddedsw}" || error "lopper failed"
772 else 772 else
773 ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx microblaze-plm "${embeddedsw}" \ 773 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx $1 "${embeddedsw}" \
774 || error "lopper failed" 774 || error "lopper failed"
775 fi 775 fi
776 776
@@ -781,7 +781,7 @@ pmc-microblaze() {
781CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" 781CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}"
782CONFIG_DTFILE[vardepsexclude] += "TOPDIR" 782CONFIG_DTFILE[vardepsexclude] += "TOPDIR"
783 783
784ESW_MACHINE = "microblaze-plm" 784ESW_MACHINE = "$1"
785 785
786require conf/microblaze.conf 786require conf/microblaze.conf
787DEFAULTTUNE = "microblaze" 787DEFAULTTUNE = "microblaze"
@@ -825,10 +825,10 @@ psm-microblaze() {
825 825
826 # Build baremetal multiconfig 826 # Build baremetal multiconfig
827 if [ -n "${domain_file}" ]; then 827 if [ -n "${domain_file}" ]; then
828 ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \ 828 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -x '*.yaml' -i "${domain_file}" "${system_dtb}" \
829 -- baremetaldrvlist_xlnx microblaze-psm "${embeddedsw}" || error "lopper failed" 829 -- baremetaldrvlist_xlnx $1 "${embeddedsw}" || error "lopper failed"
830 else 830 else
831 ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx microblaze-psm "${embeddedsw}" \ 831 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f "${system_dtb}" -- baremetaldrvlist_xlnx $1 "${embeddedsw}" \
832 || error "lopper failed" 832 || error "lopper failed"
833 fi 833 fi
834 834
@@ -839,7 +839,7 @@ psm-microblaze() {
839CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}" 839CONFIG_DTFILE = "\${TOPDIR}/conf/dtb/${dtb_file}"
840CONFIG_DTFILE[vardepsexclude] += "TOPDIR" 840CONFIG_DTFILE[vardepsexclude] += "TOPDIR"
841 841
842ESW_MACHINE = "microblaze-psm" 842ESW_MACHINE = "$1"
843 843
844require conf/microblaze.conf 844require conf/microblaze.conf
845DEFAULTTUNE = "microblaze" 845DEFAULTTUNE = "microblaze"
@@ -863,8 +863,8 @@ EOF
863parse_cpus() { 863parse_cpus() {
864 info "Generating configuration..." 864 info "Generating configuration..."
865 865
866 while read -r cpu domain os_hint; do 866 gen_linux_dtb="None"
867 867 while read -r cpu core domain cpu_name os_hint; do
868 # Skip commented lines and WARNINGs 868 # Skip commented lines and WARNINGs
869 case ${cpu} in 869 case ${cpu} in
870 \#* | \[WARNING\]:) continue ;; 870 \#* | \[WARNING\]:) continue ;;
@@ -874,19 +874,28 @@ parse_cpus() {
874 874
875 arm,cortex-a53) 875 arm,cortex-a53)
876 # We need a base cortex_a53_baremetal for the FSBL 876 # We need a base cortex_a53_baremetal for the FSBL
877 cortex_a53_baremetal fsbl 877 if [ "${core}" == 0 ]; then
878 cortex_a53_baremetal fsbl ${core} ${cpu_name}
879 fi
878 if [ "${os_hint}" == "None" ]; then 880 if [ "${os_hint}" == "None" ]; then
879 cortex_a53_linux "${domain}" 881 if [ "${gen_linux_dtb}" == "None" ]; then
880 cortex_a53_baremetal "${domain}" 882 cortex_a53_linux "${domain}"
881 cortex_a53_freertos "${domain}" 883 gen_linux_dtb="True"
884 fi
885 cortex_a53_baremetal "${domain}" ${core} ${cpu_name}
886 cortex_a53_freertos "${domain}" ${core} ${cpu_name}
882 else 887 else
883 case "${os_hint}" in 888 case "${os_hint}" in
884 linux*) 889 linux*)
885 cortex_a53_linux "${domain}" ;; 890 if [ "${gen_linux_dtb}" == "None" ]; then
891 cortex_a53_linux "${domain}"
892 gen_linux_dtb="True"
893 fi
894 ;;
886 baremetal*) 895 baremetal*)
887 cortex_a53_baremetal "${domain}" ;; 896 cortex_a53_baremetal "${domain}" ${core} ${cpu_name};;
888 freertos*) 897 freertos*)
889 cortex_a53_freertos "${domain}" ;; 898 cortex_a53_freertos "${domain}" ${core} ${cpu_name};;
890 *) 899 *)
891 warn "cortex-a53 for unknown OS (${os_hint}), parsing baremetal. ${domain}" 900 warn "cortex-a53 for unknown OS (${os_hint}), parsing baremetal. ${domain}"
892 cortex_a53_baremetal "${domain}" 901 cortex_a53_baremetal "${domain}"
@@ -896,36 +905,42 @@ parse_cpus() {
896 905
897 arm,cortex-a72) 906 arm,cortex-a72)
898 if [ "${os_hint}" == "None" ]; then 907 if [ "${os_hint}" == "None" ]; then
899 cortex_a72_linux "${domain}" 908 if [ "${gen_linux_dtb}" == "None" ]; then
900 cortex_a72_baremetal "${domain}" 909 cortex_a72_linux "${domain}"
901 cortex_a72_freertos "${domain}" 910 gen_linux_dtb="True"
911 fi
912 cortex_a72_baremetal "${domain}" ${core} ${cpu_name}
913 cortex_a72_freertos "${domain}" ${core} ${cpu_name}
902 else 914 else
903 case "${os_hint}" in 915 case "${os_hint}" in
904 linux*) 916 linux*)
905 cortex_a72_linux "${domain}" ;; 917 if [ "${gen_linux_dtb}" == "None" ]; then
918 cortex_a72_linux "${domain}"
919 gen_linux_dtb="True"
920 fi
921 ;;
906 baremetal*) 922 baremetal*)
907 cortex_a72_baremetal "${domain}" ;; 923 cortex_a72_baremetal "${domain}" ${core} ${cpu_name};;
908 freertos*) 924 freertos*)
909 cortex_a72_freertos "${domain}" ;; 925 cortex_a72_freertos "${domain}" ${core} ${cpu_name};;
910 *) 926 *)
911 warn "cortex-a72 for unknown OS (${os_hint}), parsing baremetal. ${domain}" 927 warn "cortex-a72 for unknown OS (${os_hint}), parsing baremetal. ${domain}"
912 cortex_a72_baremetal "${domain}" 928 cortex_a72_baremetal "${domain}"
913 esac 929 esac
914 fi 930 fi
915 ;; 931 ;;
916
917 arm,cortex-r5) 932 arm,cortex-r5)
918 if [ "${os_hint}" == "None" ]; then 933 if [ "${os_hint}" == "None" ]; then
919 # We need a base cortex_r5_baremetal for the FSBL for ZynqMP platform 934 # We need a base cortex_r5_baremetal for the FSBL for ZynqMP platform
920 [ "${machine}" = "zynqmp" ] && cortex_r5_baremetal fsbl 935 [ "${machine}" = "zynqmp" ] && cortex_r5_baremetal fsbl ${core} ${cpu_name}
921 cortex_r5_baremetal "${domain}" 936 cortex_r5_baremetal "${domain}" ${core} ${cpu_name}
922 cortex_r5_freertos "${domain}" 937 cortex_r5_freertos "${domain}" ${core} ${cpu_name}
923 else 938 else
924 case "${os_hint}" in 939 case "${os_hint}" in
925 baremetal*) 940 baremetal*)
926 cortex_r5_baremetal "${domain}" ;; 941 cortex_r5_baremetal "${domain}" ${core} ${cpu_name};;
927 freertos*) 942 freertos*)
928 cortex_r5_freertos "${domain}" ;; 943 cortex_r5_freertos "${domain}" ${core} ${cpu_name};;
929 *) 944 *)
930 warn "cortex-r5 for unknown OS (${os_hint}), parsing baremetal. ${domain}" 945 warn "cortex-r5 for unknown OS (${os_hint}), parsing baremetal. ${domain}"
931 cortex_r5_baremetal "${domain}" 946 cortex_r5_baremetal "${domain}"
@@ -946,14 +961,13 @@ parse_cpus() {
946 ;; 961 ;;
947 962
948 pmu-microblaze) 963 pmu-microblaze)
949 pmu-microblaze ;; 964 pmu-microblaze ${cpu_name};;
950 965
951 pmc-microblaze) 966 pmc-microblaze)
952 pmc-microblaze ;; 967 pmc-microblaze ${cpu_name};;
953 968
954 psm-microblaze) 969 psm-microblaze)
955 psm-microblaze ;; 970 psm-microblaze ${cpu_name};;
956
957 *) 971 *)
958 warn "Unknown CPU ${cpu}" 972 warn "Unknown CPU ${cpu}"
959 973
@@ -1022,7 +1036,7 @@ cd "${config_dir}" || exit
1022mkdir -p dtb multiconfig/includes 1036mkdir -p dtb multiconfig/includes
1023( 1037(
1024 cd dtb || error "Unable to cd to dtb dir" 1038 cd dtb || error "Unable to cd to dtb dir"
1025 ${lopper} -f --enhanced -i "${lops_dir}/lop-xilinx-id-cpus.dts" "${system_dtb}" \ 1039 LOPPER_DTC_FLAGS="-b 0 -@" ${lopper} -f --enhanced -i "${lops_dir}/lop-xilinx-id-cpus.dts" "${system_dtb}" \
1026 /dev/null > ${cpulist} || error "lopper failed" 1040 /dev/null > ${cpulist} || error "lopper failed"
1027 rm -f "lop-xilinx-id-cpus.dts.dtb" 1041 rm -f "lop-xilinx-id-cpus.dts.dtb"
1028) 1042)
@@ -1055,4 +1069,4 @@ if [ -n "${petalinux_schema}" ]; then
1055fi 1069fi
1056 1070
1057# Cleanup our temp file 1071# Cleanup our temp file
1058rm ${cpulist} 1072rm -rf ${cpulist} ${config_dir}/CMakeLists.txt ${config_dir}/DRVLISTConfig.cmake