Comments (13)
You can find it in newlib/libc/machine/riscv/sys/string.h. So it appears that it will compile with an embedded elf compiler using newlib, but not a linux compiler. The files in the lib dir all appear remarkably similar to the ones in newlib/libc/machine/riscv, so either they were borrowed from newlib, or they have a common ancestor.
It looks like we could fix this by copying the missing function from newlib into freedom-u540-c000-bootloader, but we might have to rename it to avoid conflicts with a newlib based embedded elf compiler. Or maybe we could fix this by forcing use of newlib headers somehow.
I don't know if anyone is actively maintaining this tree. There are no commits since Sept 2018. Bootloader code probably doesn't need a lot of changes once it is working though.
from freedom-u540-c000-bootloader.
How else can you fix the DTS? Kernel drivers are failing to work with the embedded device tree.
from freedom-u540-c000-bootloader.
I'm not a kernel hacker and don't know anything about kernel driver problems in general.
I do know that we have started using u-boot in house. I think this somehow allows one to specify an alternate DTS, perhaps by replacing the FSBL with u-boot. Using u-boot requires flipping one of the boot select switches to boot from the SDcard. With the red power switch on the left, the second switch from the bottom must be slid to the right. So maybe with u-boot working we don't need updates to the FSBL anymore?
The u-boot tree we are using is at
https://github.com/tmagik/HiFive_U-Boot
I haven't tried building this myself. We also have a freedom-u-sdk update in progress
sifive/freedom-u-sdk#88
but last I tried this it wasn't working because a compiler change meant that u-boot didn't fit in its sdcard partition anymore. This tree has never actually worked on hardware for me. And there is an alpha release at
https://github.com/tmagik/freedom-u-sdk/releases
but when I tried this it didn't work for me on hardware either. uboot ran, but the kernel didn't mount the root filesystem and dropped into busybox.
So unfortunately, we don't have anything in a releasable form at the moment, and I'm not a kernel hacker so I don't know exactly what is going on in this area.
There is one kernel driver problem I know about, and that applies only if you have the Microsemi expansion board for the HiFive Unleashed. The built-in FSBL doesn't have a DTS entry for the Microsemi PCIe support. I use the solution Atish Patra developed which modifies bbl to allow dynamically adding DTS entries. This can be found at
https://github.com/westerndigitalcorporation/RISC-V-Linux
but I think this is obsoleted by the u-boot stuff, which I haven't actually switched to yet.
from freedom-u540-c000-bootloader.
The upstream U-Boot does not support replacing FSBL, it is started by BBL or openSBI.
from freedom-u540-c000-bootloader.
If the reported issue here is the error message "undefined reference to `__libc_detect_null'", then as Jim wrote, that can be resolved by using the correct compiler. Please try using the compiler built with crosstool-ng with the "riscv64-unknown-elf" sample configuration:
https://github.com/crosstool-ng/crosstool-ng
Certainly, this is not appropriately documented. This is in keeping with the spirit of the rest of this repository ;-)
from freedom-u540-c000-bootloader.
We are discussing DTS problems now. Andreas wanted to build FSBL to fix the DTS, but I'm saying that u-boot provides its own DTS and hence a FSBL fix should not be necessary for that, and that we probably don't have any FSBL fixes for the DTS. But I don't know why the DTS is broken, other than for the microsemi expansion board.
from freedom-u540-c000-bootloader.
U-Boot does not have its own DTS.
from freedom-u540-c000-bootloader.
The comments on this issue are too confusing for me to figure out what the current problem is. If there is another problem with this repository beyond the compilation issue, could you guys open a separate issue?
from freedom-u540-c000-bootloader.
The u-boot I pointed at, the one we are using, has its own DTS.
https://github.com/tmagik/HiFive_U-Boot/blob/master/arch/riscv/dts/hifive_u540.dts
I think we are going in circles here. If you want a solution from SiFive, then you have to use our u-boot. If you don't want our u-boot, then you have to get a solution from someone else.
from freedom-u540-c000-bootloader.
Some people at SiFive may be using that U-Boot & DTS file, but as far as I know, it's not a supported SiFive repository. It's probably mostly useful for older kernels. Mainline-oriented DTS files will be different.
from freedom-u540-c000-bootloader.
That U-boot and DTS file is what is going to get promoted to the next officially supported SiFive release. I would appreciate any pull requests for more mainline-oriented DTS files, along with working and tested kernel configs.
from freedom-u540-c000-bootloader.
@andreas-schwab https://github.com/tmagik/freedom-u-sdk/blob/dev/buildroot/conf/uEnv.txt allows you to specify an alternate device tree, and use either the one provided by U-boot, or the one in the FIT image, or you can modify the env and options to load a separate bbl, kernel, DTB, and initrd images either from a partition on the SDcard, or tftp/dhcp over the network.
from freedom-u540-c000-bootloader.
I don't use buildroot, I'm using a real distribution.
from freedom-u540-c000-bootloader.
Related Issues (13)
- This version did not do the full linux boot. HOT 2
- what does unimp a0 a1 mean? HOT 5
- device tree error HOT 3
- Merging build-fixes branch to master? HOT 3
- Why is zsbl/ux00_zsbl.dts different from fsbl/ux00_zsbl.dts
- Fails to build with clang
- location of ROM binary? HOT 8
- cannot understand ccache_sideband HOT 1
- a memcpy bug(possibly) HOT 2
- Bootrom challenge notes HOT 3
- Your license template needs finished
- how to use fsbl.bin in HighFive Unleashed board ? HOT 10
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 freedom-u540-c000-bootloader.