summaryrefslogtreecommitdiffstats
path: root/meta/classes
diff options
context:
space:
mode:
authorAlejandro Hernandez Samaniego <alejandro@enedino.org>2021-05-10 23:31:34 -0600
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-05-12 23:06:04 +0100
commit4ba09d6a2b6f100eb68dfc6940b5c1c0b74c18f3 (patch)
tree6e82aeeae6f8da12bd02af6e7675176af1d94afd /meta/classes
parentd875ba64e9c66543bc47c2518f27651b67be8a7e (diff)
downloadpoky-4ba09d6a2b6f100eb68dfc6940b5c1c0b74c18f3.tar.gz
baremetal-helloworld: Enable RISC-V 64 port
Add support for MACHINE=qemuriscv64. $ runqemu nographic KERNEL: [tmp/deploy/images/qemuriscv64/baremetal-helloworld-image-qemuriscv64.bin] MACHINE: [qemuriscv64] FSTYPE: [bin] runqemu - INFO - Running tmp/work/x86_64-linux/qemu-helper-native/1.0-r1/recipe-sysroot-native/usr/bin/qemu-system-riscv64 Hello OpenEmbedded on RISC-V 64! (From OE-Core rev: 31fde82640bf0d185eab55d2cbaf663c9faae801) Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandro@enedino.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/baremetal-image.bbclass14
1 files changed, 13 insertions, 1 deletions
diff --git a/meta/classes/baremetal-image.bbclass b/meta/classes/baremetal-image.bbclass
index b0f5e885b5..319b61c7cd 100644
--- a/meta/classes/baremetal-image.bbclass
+++ b/meta/classes/baremetal-image.bbclass
@@ -73,7 +73,19 @@ QB_DEFAULT_KERNEL ?= "${IMAGE_LINK_NAME}.bin"
73QB_MEM ?= "-m 256" 73QB_MEM ?= "-m 256"
74QB_DEFAULT_FSTYPE ?= "bin" 74QB_DEFAULT_FSTYPE ?= "bin"
75QB_DTB ?= "" 75QB_DTB ?= ""
76QB_OPT_APPEND = "-nographic" 76QB_OPT_APPEND_append = " -nographic"
77
78# RISC-V tunes set the BIOS, unset, and instruct QEMU to
79# ignore the BIOS and boot from -kernel
80QB_DEFAULT_BIOS_qemuriscv64 = ""
81QB_OPT_APPEND_append_qemuriscv64 = " -bios none"
82
83
84# Use the medium-any code model for the RISC-V 64 bit implementation,
85# since medlow can only access addresses below 0x80000000 and RAM
86# starts at 0x80000000 on RISC-V 64
87CFLAGS_append_qemuriscv64 = " -mcmodel=medany"
88
77 89
78# This next part is necessary to trick the build system into thinking 90# This next part is necessary to trick the build system into thinking
79# its building an image recipe so it generates the qemuboot.conf 91# its building an image recipe so it generates the qemuboot.conf