Comments (14)
Strange, I had tested U-Boot-2019.10 release with OpenSBI v0.5 release.
Can you provide exact steps to reproduce this compile error ?
from opensbi.
That's exactly the versions I am using. The following worked:
- QEMU virt with kernel payload;
- QEMU virt with U-Boot payload;
So only SiFive FU540 with U-Boot payload fails (tried twice on different hosts, i.e. boards).
Full build log is here (incl. commands being executed): http://fedora.riscv.rocks/kojifiles/work/tasks/5439/315439/build.log
I just tagged older binutils 2.32 to F32/Rawhide to check if this is due to changes in binutils (most likely).
from opensbi.
Can you also tell us size of hifive-unleashed-a00.dtb and sifive_fu540/u-boot.bin ?
It would be even better if you can send us above binaries via google driver (or something else).
Regards,
Anup
from opensbi.
Huh, 2.32 produced the same issue. You can extract those from RPMs, .e.g:
rpm2cpio 'http://fedora.riscv.rocks/kojifiles/packages/kernel/5.4.0/0.rc3.git2.300.1.riscv64.fc32/riscv64/kernel-core-5.4.0-0.rc3.git2.300.1.riscv64.fc32.riscv64.rpm' | cpio -dvim
This should be the DTB /lib/modules/5.4.0-0.rc3.git2.300.1.riscv64.fc32.riscv64/dtb/sifive/hifive-unleashed-a00.dtb
For the U-Boot image:
rpm2cpio 'http://fedora.riscv.rocks/kojifiles/packages/uboot-tools/2019.10/2.0.riscv64.fc31/noarch/uboot-images-riscv64-2019.10-2.0.riscv64.fc31.noarch.rpm' | cpio -dvim
That should have /usr/share/uboot/sifive_fu540/u-boot.bin
from opensbi.
This seems to be a know issue with RISC-V binutils.
Refer, riscv-collab/riscv-gnu-toolchain#298
Can you try adding line ".option norelax" before line "#ifdef FW_PAYLOAD_FDT_PATH" in firmware/fw_payload.S ?
Regards,
Anup
from opensbi.
Alternately, can you also try replacing ".align 4" with ".balign 16" in firmware/fw_payload.S ?
Regards,
Anup
from opensbi.
.option norelax
seems to solve the problem, but changing .align 4
to balign 16
does not.
from opensbi.
Cool, thanks for trying my suggestion.
The issue will only manifest when we are embedding DTB in FW_PAYLOAD and DTB size is not multiple of 16 bytes.
You can send patch to OpenSBI. Please mention the GCC binutils issue in your commit description as well.
Regards,
Anup
from opensbi.
I send patch to OpenSBI to fix this issue.
I was not able to reproduce this issue with Bootlin toolchain so I guess lot of people might not be seeing this issue.
(Refer, https://toolchains.bootlin.com/)
Can you provide Tested-by to my patch ?
Regards,
Anup
from opensbi.
I noticed that. I just started a test build with my own patch and your patch arrived. I killed my build and pulled in your patch instead. I will send Tested-by within 30 minutes if nothing goes wrong.
One nitpick, why .option pop
is not aligned to .option push
in your patch?
from opensbi.
You did not acknowledge that you will send patch so I thought you might be busy.
My bad, I should have waited little longer for your patch.
The ".option push" will save current options and ".options pop" will restore previously saved options. This is done same way Linux head.S as well.
Regards,
Anup
from opensbi.
What I wanted to say is that indentation is different between push and pop lines.
from opensbi.
Ahh, the difference in indentation is typo. I will fix it.
Regards,
Anup
from opensbi.
Fix for this is now merged. Closing this issue.
Regards,
Anup
from opensbi.
Related Issues (20)
- Why is MTIME M-mode only?
- [QUESTION] Usage of negative number notations on unsigned numbers. HOT 1
- `sbi_cppc_write` is never passed the full 64-bit value when `__riscv_xlen == 32` HOT 1
- Too small fw_heap_size makes OpenSBI corrupt memory HOT 3
- TH1520(C910)boot information: CPU1、CPU2、CPU3: failed to come online ; only CPU0 succeed to come online HOT 7
- semihosting_write bug in generic HOT 6
- [help] how to build test payload for non-qemu target HOT 2
- opensbi testing HOT 2
- What is the relationship between Coreboot and Opensbi HOT 2
- ld.bfd: unrecognized option --exclude-libs HOT 2
- fw_start and fw_rw_offset not aligned
- Is there any upper memory bound for initramfs or opensbi or kernel?
- Handling interrupts with multiple privileges on multiple harts in OpenSBI HOT 1
- [help] K210 serial port has no output HOT 1
- build issue - functions do not get linked HOT 1
- System freezes when setting smp value to 54 or higher with qemu-system-riscv64
- Firmware SMP boot bug HOT 2
- sbi_hsm_hart_start_finish: ERR: The hart is in invalid state [2147774600] HOT 1
- firmware base is not the value of FW_TEXT_START( but 0x80000000)
- How to get symtab from elf?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from opensbi.