skiffos / SkiffOS

Any Linux distribution, anywhere.
https://skiffos.com
MIT License
685 stars 50 forks source link

Initial patch for visionfive2 #268

Closed maxberger closed 1 year ago

maxberger commented 1 year ago

For early review only!

This compiles, but it is yet-to-be-tested on the real hardware. There are probably many additional patches needed.

Done:

paralin commented 1 year ago

Looks good! I don't have a visionfive2, but if someone does and can test, that'd be excellent.

maxberger commented 1 year ago

Comments addressed, will now test on real hardware...

clayauld commented 1 year ago

I should also be getting some hardware in a couple months. I'll be able to test and plan to test this at that time.

maxberger commented 1 year ago

Comments addressed, tested on the machine, added known issues to documentation. From my side this is good for more public testing

paralin commented 1 year ago

Adjusted: added the board to README. Merged, thanks!

paralin commented 1 year ago

@maxberger I have adjusted some options related to locale in be6e8c348e07bd06da238b82c9203cb59771148e

I think this might fix the problem with locales on the visionfive2 as well.

Please have a test & let me know if it's fixed and we can remove the known issue in the readme.

To update the locales without fully rebuilding:

git checkout master
git pull
git submodule update
make br/glibc-dirclean
make configure compile

Thanks!

EDIT: after maxberger's message below this one, we eventually fixed this via a change to the sshd config to not allow the LANG env variable through.

maxberger commented 1 year ago

Unfortunately this did not fix it for me. Still the same issue: I can ssh in if I unset LANG, as soon as I try to set LANG to anything, bash still crashes. So there is probably something somewhere else as well.

I also tried a full rebuild just to be sure, same behavior

clayauld commented 1 year ago

I finally got my VisionFive 2 board. I was able to build from the master branch but have been unable to get a successful boot. The UART output only shows this error:

BOOT fail,Error is 0xffffffff

I've confirmed I can get the board to boot properly from the Starfive buildroot sdcard.img file from here: https://github.com/starfive-tech/VisionFive2/releases/tag/VF2_v2.11.5

Any pointers on getting this to boot? It looks like Starfive's buildroot SDK is here: https://github.com/starfive-tech/VisionFive2

paralin commented 1 year ago

@clayauld could you please open an issue with the uboot logs and other info? I'll double check the visionfive2 config.

maxberger commented 1 year ago

@clayauld did you upgrade to the latest U-Boot+Firmware? You need to do that before anything else really works.

clayauld commented 1 year ago

I did update to the latest U-Boot and SPL binary according to the documentation for the board: (Section 4.3 in the Appendix): https://doc-en.rvspace.org/VisionFive2/PDF/VisionFive2_QSG.pdf

Not sure how much help U-Boot logs would be. This is all I'm getting:

BOOT fail,Error is 0xffffffff

I saw this consistently when I was using the wrong Debian image for the eMMC module. I switched to trying this all on the SD card since that is better supported at this time, and SkiffOS may not play well with that.

Do I need to flash U-Boot and SPL binaries from the SkiffOS build to make this all work?

clayauld commented 1 year ago

I can open an issue tomorrow with more info. I need to get some sleep....