Giter Site home page Giter Site logo

freedom-u-sdk's Introduction

freedom-u-sdk

SiFive Freedom Unleashed SDK layer for OpenEmbedded/Yocto

Description

The experimental Freedom Unleashed (FU) SDK is based on OpenEmbedded/Yocto framework, allowing to build custom Linux distributions:

  • build predefined disk images for QEMU, SiFive HiFive Unleashed development board and SiFive HiFive Unmatched
  • build custom disk images with additional software packages from various third-party OE layers;
  • quickly launch QEMU VM instance with your built disk image;
  • build bootloader binaries (OpenSBI, U-Boot, U-Boot SPL);
  • build Device Tree Binary (DTB);
  • build Linux kernel images;
  • easily modify disk partition layout.

For more information on particular release see ReleaseNotes directory in freedom-u-sdk repository on GitHub.

For advanced OE usage we advice to look into Yocto Project Documentation and A practical guide to BitBake.

Dependencies

This layer depends on:

Prerequisites for the build host

Create the build environment

mkdir dist && cd dist
git clone https://github.com/sifive/freedom-u-sdk

Available machines

This layer doesn't define new machines. It uses machine provides by the meta-sifive layer, as well as the Qemu RISC-V provided by the oe-core layer.

Available distribution

This layer provides a distribution, named freedom-u-sdk for the following machines:

  • freedom-u540: The SiFive HiFive Unleashed board,
  • unmatched: The Sifive Unmatched board,
  • qemuriscv64: The Qemu RISC-V 64bits.

It also provides two disk images:

  • demo-coreip-cli: basic command line image (recommended);
  • demo-coreip-xfce4: basic graphical disk image with Xfce 4 desktop environment.

Build images

Building disk images is CPU intensive, could require <10GB of sources downloaded over the Internet and <200GB of local storage.

This layer provides Kas scripts configured to download and to configure the build environment to build demo-coreip images for supported targets:

kas build --update ./freedom-u-sdk/scripts/kas/freedom-u540.yml
kas build --update ./freedom-u-sdk/scripts/kas/qemuriscv64.yml
kas build --update ./freedom-u-sdk/scripts/kas/unmatched.yml

Moreover, it is also possible to build other images, or SDK, or also packages, for example:

kas build --update ./freedom-u-sdk/scripts/kas/unmatched.yml --target core-image-weston
kas build --update ./freedom-u-sdk/scripts/kas/unmatched.yml --target buildtools-extended-tarball
kas build --update ./freedom-u-sdk/scripts/kas/unmatched.yml --target busybox
kas shell --update ./freedom-u-sdk/scripts/kas/unmatched.yml -c "bitbake core-image-minimal -c populate_sdk"
kas shell --update ./freedom-u-sdk/scripts/kas/unmatched.yml -c "bitbake core-image-minimal -c populate_sdk_ext"

Running in QEMU

The OpenEmbedded/Yocto framework provides a wrapper for QEMU, named runqemu in order to use it easily.

Below examples to use this Qemu over a Kas shell:

kas shell ./freedom-u-sdk/scripts/kas/qemuriscv64.yml -c "runqemu slirp nographic demo-coreip-cli"
kas shell ./freedom-u-sdk/scripts/kas/qemuriscv64.yml -c "runqemu slirp serialstdio demo-coreip-xfce4"

Execute runtime tests

The OpenEmbedded/Yocto framework provides also provides tools to implement and to run tests.

These tests can be executed on all supported targets, using the following commands:

kas build --update ./freedom-u-sdk/scripts/kas/qemuriscv64.yml:./freedom-u-sdk/scripts/kas/include/test.yml
kas shell --update ./freedom-u-sdk/scripts/kas/qemuriscv64.yml:./freedom-u-sdk/scripts/kas/include/test.yml -c "bitbake demo-coreip-cli -c populate_sdk && bitbake demo-coreip-cli -c testsdk"
kas shell --update ./freedom-u-sdk/scripts/kas/qemuriscv64.yml:./freedom-u-sdk/scripts/kas/include/test.yml -c "bitbake demo-coreip-cli -c populate_sdk_ext && bitbake demo-coreip-cli -c testsdkext"
kas shell --update ./freedom-u-sdk/scripts/kas/qemuriscv64.yml:./freedom-u-sdk/scripts/kas/include/test.yml -c "resulttool report  ./tmp/log/oeqa"

Running on Hardware

You will find all available build fragments (incl. disk images) in $BUILDDIR/tmp/deploy/images/$MACHINE where MACHINE can be:

  • freedom-u540
  • qemuriscv64
  • unmatched

Disk images files use <image>-<machine>.<output_format> format, for example,

demo-coreip-cli-unmatched.rootfs.wic.xz. We are interested in .wic.xz disk images for writing to uSD card.

Be very careful while picking /dev/sdX device! Look at dmesg, lsblk, blkid, GNOME Disks, etc. before and after plugging in your uSD card to find a proper device. Double check it to avoid overwriting any of system disks/partitions!

Unmount any mounted partitions from uSD card before writing!

Flash the image on SDCard

Images built can be flashed with bmaptool (faster), for example:

sudo bmaptool copy ../build/tmp/deploy/images/unmatched/demo-coreip-xfce4-unmatched.rootfs.wic.xz /dev/mmcblk0

Otherwise, you can also use the dd command, for example:

xzcat ../build/tmp/deploy/images/unmatched/demo-coreip-xfce4-unmatched.rootfs.wic.xz | sudo dd of=/dev/mmcblk0 bs=512K iflag=fullblock oflag=direct conv=fsync status=progress

MSEL for Unleashed

You will need to modify MSEL to allow using U-Boot SPL, OpenSBI, U-Boot proper bootloaders from uSD card instead of SPI-NOR Flash chip:

      USB   LED    Mode Select                  Ethernet
 +===|___|==****==+-+-+-+-+-+-+=================|******|===+
 |                | | | | |X| |                 |      |   |
 |                | | | | | | |                 |      |   |
 |        HFXSEL->|X|X|X|X| |X|                 |______|   |
 |                +-+-+-+-+-+-+                            |
 |        RTCSEL-----/ 0 1 2 3 <--MSEL                     |
 |                                                         |

MSEL for Unmatched

By default MSEL on Unmatched is set to use uSD instead of SPI-NOR Flash chip to load U-Boot SPL, OpenSBI and U-Boot proper. Below is the default configuration for DIP switches (located next to Assembly Number and RTC battery):

  +----------> CHIPIDSEL
  | +--------> MSEL3
  | | +------> MSEL2
  | | | +----> MSEL1
  | | | | +--> MSEL0
  | | | | |
 +-+-+-+-+-+
 | |X| |X|X| ON(1)
 | | | | | |
 |X| |X| | | OFF(0)
 +-+-+-+-+-+
BOOT MODE SEL

Connecting Using Serial Console

Connect your HiFive Unleashed or HiFive Unmatched to your PC using microUSB-USB cable to access serial console.

For macOS, run: screen -L /dev/tty.usbserial-*01 115200

For Linux, run: screen -L /dev/serial/by-id/usb-FTDI_Dual_RS232-HS-if01-port0 115200

The above commands might vary depending on your exact setup.

-L command will log all output to screenlog.0 in your current working directory.

To quit screen, hit Ctrl - A followed by \ symbol. Finally agree to terminate all windows by typing y.

You can login with root account. The password is sifive. We strongly recommend to change the default password for the root account on the first boot before you connect it to the Internet.

Connecting Using SSH

Before you connect your board to the Internet we strongly recommend to change the default password for the root account and configure your network equipment (for example, routers and firewalls) appropriately.

SSH daemon is enabled by default, in order to be able to execute remotely runtime tests. To disable SSH daemon connect to the board using serial console method described above. Once connected execute the following commands:

systemctl disable sshd.socket
systemctl stop sshd.socket

The HiFive Unleashed and Unmatched behave like any other network capable device (such as PC, laptop, and Single Board Computers like Raspberry Pi). Connect the board to your network (for example, a router), and it will acquire IPv4 + DNS configuration using DHCP protocol. You can use your router management panel to get assigned IPv4 address or use the serial console to acquire it directly from the board (use ip addr command to print active network information). Finally you can SSH to the board:

ssh -o PreferredAuthentications=password -o PubkeyAuthentication=no -o StrictHostKeyChecking=no -o "UserKnownHostsFile /dev/null" root@<IPv4>

Supported GPUs

Various GPUs from AMD were successfully tested with the boards. In particular Radeon HD 6450 is the most widely used. Other GPUs from the same family might also work, for instance, THD64xxM, HD7450, HD8450, R5 230, R5 235, R5 235X. The newest tested GPUs from AMD are RX 550, RX 570, RX 580 with no issues.

Online Resizing of rootfs (Root File Partition)

It is highly advised to resize partitions offline (i.e. before booting the system). If you already booted the system and cannot do offline resizing then the following instructions should resize rootfs (root file partition) to full uSD capacity:

sgdisk -v /dev/mmcblk0
sgdisk -e /dev/mmcblk0
parted /dev/mmcblk0 resizepart 4 100%
resize2fs /dev/mmcblk0p4
sync

NBD (Network Block Device) rootfs

This is an experimantal feature currently only available on SiFive HiFive Unmatched board. This allow sharing a block device over the network. This is not an extensive guide into NBD, but a quick start.

If you want to use this feature open extlinux.conf in /boot partition and modify the append line to:

append ip=dhcp root=/dev/nbd0 rw nbdroot=<server_ip_address>:<export_name> nbdport=10809 console=ttySIF0,115200 earlycon

If you are booting directly from U-Boot prompt, you would need to set bootargs variable instead.

Note that <export_name> value might be ignored by the NBD server (depends on the implementation and configuration).

nbdkit is a recommended NBD server for it's flexibility.

Here is an example command for nbdkit:

sudo nbdkit -f --verbose --threads 128 --filter=cow --filter=partition --filter=xz file demo-coreip-xfce4-unmatched-<..>.rootfs.wic.xz partition=4

This would expose the ext4 filesystem on the 4th partition from XZ compressed disk image. By default it's read-only thus we also add a COW (Copy-on-Write) layer. Note that COW layer is not saved by default and will be lost if nbdkit process is terminated. See nbdkit-cow-filter NOTES on how to save disk image with all the modifications for further use.

Using XZ compressed disk image is convenient, but doesn't deliver high performance. For higher performance uncompress disk image before sharing it via NBD.

Here is another example:

sudo mkdir rootfs
sudo tar -xJ --numeric-owner -C rootfs -f demo-coreip-xfce4-unmatched-<..>.rootfs.tar.xz
sudo nbdkit -f --verbose --threads 128 --filter=partition --filter=cow linuxdisk $PWD/rootfs size=+2G partition=1

In this particular case we uncompress rootfs into a directory. We ask nbdkit to take the directory, generate linux disk image from it, add some additional free space, add a COW layer to make it writable and send "naked" filesystem (i.e. no partition table) as before.

nbdkit has a number of plugins and filters allowing various ways how to share disk images over the network.

Run Tensorflow Lite demo

cd /usr/share/tensorflow/lite/examples/python/
python3 python3 mnist.py

Contributions & Feedback

If you want to file issues, send patches and make feature/enhancement requests use freedom-u-sdk repository on GitHub. So that the maintainer can process your request.

You are also welcome to join SiFive Forums where we have HiFive Unleashed and HiFive Unmatched categories for discussions.

freedom-u-sdk's People

Contributors

a0u avatar atishp04 avatar carlosedp avatar davidlt avatar edolnx avatar embeddedlinuxguy avatar emfive avatar michaeljclark avatar palmer-dabbelt avatar ruinland-tsai avatar solomatnikov avatar terpstra avatar tmagik avatar tprrt avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

freedom-u-sdk's Issues

Priv-1.10 branch doesn't work with QEMU / Master's branch user/pass?

Everything built successfully on the priv-1.10 branch. The following is used to run qemu, but nothing happens.

qemu-system-riscv64 -kernel riscv-pk/bbl -initrd bbl.bin -nographic

The master branch boots with the same command, but what is the user/password? Users default nor root without a password work.

Running bbl image from freedom-u-sdk with fesvr

The Linux image generated from freedom-u-sdk tag hifiveu-0.0 runs nicely on spike with 4 cores, but I wasn't able to use the corresponding bbl image, which is also automatically generated, for booting Linux on top of a single-core Rocket Chip running on a ZC706.

In light of this, should I make any modification to the Kernel config or to any other tool to boot that same spike-working image on an FPGA?

I've already made sure that riscv-pk and riscv-fesvr are updated and that the /usr/local/lib path on the board holds the new version of libfesvr.so. Running $./riscv-fesvr pk hello on the board also works as intended.

Better error message if submodules don't exist

It would be nice if you happen to forget to check out the submodules to provide a more helpful error message.

Currently cloning the freedom-u-sdk with 'git clone https://github.com/sifive/freedom-u-sdk' and then running 'make' gives an error message like this:

freedom-u-sdk tmagik$ make
rm -rf /Users/tmagik/src/SiFive/freedom-u-sdk/work/buildroot_initramfs/
mkdir -p /Users/tmagik/src/SiFive/freedom-u-sdk/work/buildroot_initramfs/
cp /Users/tmagik/src/SiFive/freedom-u-sdk/conf/buildroot_initramfs_config /Users/tmagik/src/SiFive/freedom-u-sdk/work/buildroot_initramfs/.config
/Applications/Xcode.app/Contents/Developer/usr/bin/make -C /Users/tmagik/src/SiFive/freedom-u-sdk/buildroot RISCV=/Users/tmagik/src/SiFive/freedom-u-sdk/toolchain PATH=/Users/tmagik/src/SiFive/freedom-u-sdk/toolchain/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin:/opt/X11/bin:/Applications/Wireshark.app/Contents/MacOS:/opt/openafs/bin:/opt/openafs/sbin O=/Users/tmagik/src/SiFive/freedom-u-sdk/work/buildroot_initramfs olddefconfig
make[1]: *** No rule to make target `olddefconfig'.  Stop.

trap_illegal_instruction and trap_instruction_access_fault when running program

After running make and compiling some programs for RISCV and trying to run them, I get errors. When running these programs on the linux kernel through spike, I get the trap_illegal_instruction and trap_instruction_access_fault, and the programs stop working. I am running spike with -p2 processors.

The instructions that result in trap_illegal_instruction are:
csrr
fsd
fld

When the second core, core 1, starts running, it runs for a bit, then does the mret instruction, and immediately after this it gets stuck on the trap_instruction_access_fault exception. The full error is:
core 1: exception trap_instruction_access_fault, epc 0x0000000000000000
core 1: badaddr 0x0000000000000000

It continues like this until I CTRL+C.
Any ideas how to fix this? I would like to get some memory traces from a shared memory program, to be able to test a cache coherence protocol I am designing for a computer with a RISCV core.

buildroot compile failure on Debian Buster (testing)

I am having a problem building buildroot when running make qemu with top-of-tree on Debian Linux x86_64 (Note I have done unset RISCV so that I use the toolchain bundled with freedom-u-sdk):

$ make qemu
[snip]
make[4]: Entering directory '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1/debugfs'
	CC debug_cmds.c
	CC extent_cmds.c
	CC create_inode.o
	CC quota.c
	CC xattrs.c
	CC journal.c
./../misc/create_inode.c: In function โ€˜do_mknod_internalโ€™:
./../misc/create_inode.c:290:13: warning: In the GNU C Library, "major" is defined
 by <sys/sysmacros.h>. For historical compatibility, it is
 currently defined by <sys/types.h> as well, but we plan to
 remove this soon. To use "major", include <sys/sysmacros.h>
 directly. If you did not intend to use a system-defined macro
 "major", you should undefine it after including <sys/types.h>.
   devmajor = major(st->st_rdev);
             ^~~~~~~~~~~~~~~~~~~~                                                                                                                                                                                                                                                                                                                                                    
./../misc/create_inode.c:291:13: warning: In the GNU C Library, "minor" is defined
 by <sys/sysmacros.h>. For historical compatibility, it is
 currently defined by <sys/types.h> as well, but we plan to
 remove this soon. To use "minor", include <sys/sysmacros.h>
 directly. If you did not intend to use a system-defined macro
 "minor", you should undefine it after including <sys/types.h>.
   devminor = minor(st->st_rdev);
             ^~~~~~~~~~~~~~~~~~~~                                                                                                                                                                                                                                                                                                                                                    
./../misc/create_inode.c: At top level:
./../misc/create_inode.c:395:18: error: conflicting types for โ€˜copy_file_rangeโ€™
 static errcode_t copy_file_range(ext2_filsys fs, int fd, ext2_file_t e2_file,
                  ^~~~~~~~~~~~~~~
In file included from ./../misc/create_inode.c:19:0:
/usr/include/unistd.h:1110:9: note: previous declaration of โ€˜copy_file_rangeโ€™ was here
 ssize_t copy_file_range (int __infd, __off64_t *__pinoff,
         ^~~~~~~~~~~~~~~
Makefile:417: recipe for target 'create_inode.o' failed
make[4]: *** [create_inode.o] Error 1
make[4]: *** Waiting for unfinished jobs....
make[4]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1/debugfs'
Makefile:404: recipe for target 'all-progs-recursive' failed
make[3]: *** [all-progs-recursive] Error 1
make[3]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1'
Makefile:339: recipe for target 'all' failed
make[2]: *** [all] Error 2
make[2]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1'
package/pkg-generic.mk:195: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1/.stamp_built' failed
make[1]: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1/.stamp_built] Error 2
make[1]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
Makefile:90: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar' failed
make: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar] Error 2

I have done a make clean and git fetch, git reset origin/master and recursively reset submodules. Below is the output excluding riscv-qemu.

$ git branch -v
* master                62ae153 Merge pull request #50 from sifive/add_u500_openocd_cfg
$ git submodule foreach --recursive git reset --hard
Entering 'buildroot'
HEAD is now at dfc1531953 Add tyrquake, an open source quake 1 implementation
Entering 'linux'
HEAD is now at 2b0aa1de45f6 serial/sifive: initial driver from Paul Walmsley
Entering 'riscv-fesvr'
HEAD is now at f683e01 dtm: Avoid back-to-back writes to dmcontrol (#35)
Entering 'riscv-gnu-toolchain'
HEAD is now at b4dae89 Bump GCC
Entering 'riscv-gnu-toolchain/riscv-binutils-gdb'
HEAD is now at d0176cb165 RISC-V: Fix riscv g++ testsuite EH failures.
Entering 'riscv-gnu-toolchain/riscv-dejagnu'
HEAD is now at 5f3adaf Textual RISC-V cleanups
Entering 'riscv-gnu-toolchain/riscv-gcc'
HEAD is now at b731149757b RISC-V: Implement movmemsi
Entering 'riscv-gnu-toolchain/riscv-glibc'
HEAD is now at 2f626de717 Handle errno a bit more correctly
Entering 'riscv-gnu-toolchain/riscv-newlib'
HEAD is now at ccd8a0a4f Use generic's one for time.h
Entering 'riscv-gnu-toolchain/riscv-qemu/roms/vgabios'
HEAD is now at 19ea12c Add qemu qxl vga pci bios
Entering 'riscv-isa-sim'
HEAD is now at 092b464 Put HTIF in the device tree
Entering 'riscv-pk'
HEAD is now at 5a0e3e5 minit: insert printm as work-around for a race condition

I tried to bump buildroot to the sifive-next and get this:

$ cd buildroot
$ git checkout sifive-next
$ cd ..
$ rm -fr work/buildroot_*
$ make qemu
make -C /home/mclark/src/sifive/freedom-u-sdk/buildroot RISCV=/home/mclark/src/sifive/freedom-u-sdk/toolchain PATH=/home/mclark/src/sifive/freedom-u-sdk/toolchain/bin:/home/mclark/bin:/home/mclark/.local/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games:/opt/riscv/toolchain/bin:/opt/riscv/qemu/bin:/opt/riscv/musl-riscv-toolchain-7.2.0-7/bin O=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs
make[1]: Entering directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
Makefile.legacy:9: *** "You have legacy configuration in your .config! Please check your configuration.".  Stop.
make[1]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
Makefile:90: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar' failed
make: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar] Error 2

I tried to bump buildroot to the sifive and get this:

$ cd buildroot
$ git checkout sifive
$ cd ..
$ rm -fr work/buildroot_*
$ make qemu
[snip]
make[4]: Entering directory '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1/debugfs'
	CC debug_cmds.c
	CC extent_cmds.c
	CC create_inode.o
	CC xattrs.c
	CC journal.c
	CC revoke.o
./../misc/create_inode.c: In function โ€˜do_mknod_internalโ€™:
./../misc/create_inode.c:290:13: warning: In the GNU C Library, "major" is defined
 by <sys/sysmacros.h>. For historical compatibility, it is
 currently defined by <sys/types.h> as well, but we plan to
 remove this soon. To use "major", include <sys/sysmacros.h>
 directly. If you did not intend to use a system-defined macro
 "major", you should undefine it after including <sys/types.h>.
   devmajor = major(st->st_rdev);
             ^~~~~~~~~~~~~~~~~~~~                                                                                                                                                                                                                                                                                                                                                    
./../misc/create_inode.c:291:13: warning: In the GNU C Library, "minor" is defined
 by <sys/sysmacros.h>. For historical compatibility, it is
 currently defined by <sys/types.h> as well, but we plan to
 remove this soon. To use "minor", include <sys/sysmacros.h>
 directly. If you did not intend to use a system-defined macro
 "minor", you should undefine it after including <sys/types.h>.
   devminor = minor(st->st_rdev);
             ^~~~~~~~~~~~~~~~~~~~                                                                                                                                                                                                                                                                                                                                                    
./../misc/create_inode.c: At top level:
./../misc/create_inode.c:395:18: error: conflicting types for โ€˜copy_file_rangeโ€™
 static errcode_t copy_file_range(ext2_filsys fs, int fd, ext2_file_t e2_file,
                  ^~~~~~~~~~~~~~~
In file included from ./../misc/create_inode.c:19:0:
/usr/include/unistd.h:1110:9: note: previous declaration of โ€˜copy_file_rangeโ€™ was here
 ssize_t copy_file_range (int __infd, __off64_t *__pinoff,
         ^~~~~~~~~~~~~~~
Makefile:417: recipe for target 'create_inode.o' failed
make[4]: *** [create_inode.o] Error 1
make[4]: *** Waiting for unfinished jobs....
make[4]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1/debugfs'
Makefile:404: recipe for target 'all-progs-recursive' failed
make[3]: *** [all-progs-recursive] Error 1
make[3]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1'
Makefile:339: recipe for target 'all' failed
make[2]: *** [all] Error 2
make[2]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1'
package/pkg-generic.mk:195: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1/.stamp_built' failed
make[1]: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-e2fsprogs-1.43.1/.stamp_built] Error 2
make[1]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
Makefile:90: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar' failed
make: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar] Error 2

The buildroot submodule in freedom-u-sdk points here: sifive/buildroot@dfc1531

The builtroot sifive branch points here: sifive/buildroot@9fa9c29

It seems e2fsprogs is not compiling due to a conflict between a unistd.h definition of copy_file_range and a statically defined version of copy_file_range in e2fsprogs-1.43.1/misc/create_inode.c

./../misc/create_inode.c: At top level:
./../misc/create_inode.c:395:18: error: conflicting types for โ€˜copy_file_rangeโ€™
 static errcode_t copy_file_range(ext2_filsys fs, int fd, ext2_file_t e2_file,
                  ^~~~~~~~~~~~~~~
In file included from ./../misc/create_inode.c:19:0:
/usr/include/unistd.h:1110:9: note: previous declaration of โ€˜copy_file_rangeโ€™ was here
 ssize_t copy_file_range (int __infd, __off64_t *__pinoff,
         ^~~~~~~~~~~~~~~

Okay. The error is buildroot trying to build a host e2fsprogs and it the conflict is with my debian system headers in /usr/include/unistd.h:1110

This is from this debian package which is from "buster" (Debian testing):

libc6-dev:amd64                           2.27-2 

Okay. Let's try a downgrade to "stretch" (Debian stable):

libc6-dev-i386                            2.24-11+deb9u3

We've downgraded the host compiler from gcc-7.3 (buster) to gcc-6.3 (stretch). More problems. Compiler doesn't support the Stack Smashing Protector:

SSP support not available in this toolchain, please disable BR2_TOOLCHAIN_EXTERNAL_HAS_SSP
package/pkg-generic.mk:185: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/toolchain-external-undefined/.stamp_configured' failed
make[1]: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/toolchain-external-undefined/.stamp_configured] Error 1
make[1]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
Makefile:90: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar' failed
make: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar] Error 2

Maybe I can modify one of these:

$ grep -r BR2_TOOLCHAIN_EXTERNAL_HAS_SSP work
./work/buildroot_initramfs/.config:BR2_TOOLCHAIN_EXTERNAL_HAS_SSP=y
./work/buildroot_initramfs/build/buildroot-config/auto.conf:BR2_TOOLCHAIN_EXTERNAL_HAS_SSP=y
./work/buildroot_initramfs/build/buildroot-config/autoconf.h:#define BR2_TOOLCHAIN_EXTERNAL_HAS_SSP 1

Okay lets try this:

$ git diff conf/buildroot_initramfs_config 
diff --git a/conf/buildroot_initramfs_config b/conf/buildroot_initramfs_config
index 335ad76..ceb4ac7 100644
--- a/conf/buildroot_initramfs_config
+++ b/conf/buildroot_initramfs_config
@@ -37,3 +37,4 @@ BR2_PACKAGE_DROPBEAR=y
 BR2_PACKAGE_SCREEN=y
 BR2_PACKAGE_HTOP=y
 BR2_PACKAGE_HOST_MKE2IMG=y
+# BR2_TOOLCHAIN_EXTERNAL_HAS_SSP is not set
$ make qemu
[snip]
>>> libtirpc 1.0.1 Patching libtool

Applying buildroot-libtool-v2.4.4.patch using patch: 
patching file ltmain.sh
Hunk #1 succeeded at 2694 (offset 7 lines).
Hunk #2 succeeded at 4284 (offset 7 lines).
Hunk #3 succeeded at 6579 (offset 25 lines).
Hunk #4 succeeded at 6589 (offset 25 lines).
Hunk #5 succeeded at 6882 (offset 25 lines).
Hunk #6 succeeded at 7174 (offset 25 lines).
Hunk #7 succeeded at 8140 (offset 28 lines).
Hunk #8 succeeded at 10769 (offset 59 lines).
(cd /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/libtirpc-1.0.1/ && rm -rf config.cache && PATH="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/bin:/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/sbin:/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin:/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/sbin:/home/mclark/src/sifive/freedom-u-sdk/toolchain/bin:/home/mclark/bin:/home/mclark/.local/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games:/opt/riscv/toolchain/bin:/opt/riscv/qemu/bin:/opt/riscv/musl-riscv-toolchain-7.2.0-7/bin" AR="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-ar" AS="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-as" LD="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-ld" NM="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-nm" CC="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-gcc" GCC="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-gcc" CPP="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-cpp" CXX="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-g++" FC="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-gfortran" RANLIB="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-ranlib" READELF="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-readelf" STRIP="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-strip" OBJCOPY="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-objcopy" OBJDUMP="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-objdump" AR_FOR_BUILD="/usr/bin/ar" AS_FOR_BUILD="/usr/bin/as" CC_FOR_BUILD="/usr/bin/gcc" GCC_FOR_BUILD="/usr/bin/gcc" CXX_FOR_BUILD="/usr/bin/g++" LD_FOR_BUILD="/usr/bin/ld" CPPFLAGS_FOR_BUILD="-I/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/include" CFLAGS_FOR_BUILD="-O2 -I/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/include" CXXFLAGS_FOR_BUILD="-O2 -I/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/include" LDFLAGS_FOR_BUILD="-L/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/lib -L/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/lib -Wl,-rpath,/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/lib" FCFLAGS_FOR_BUILD="" DEFAULT_ASSEMBLER="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-as" DEFAULT_LINKER="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-ld" CPPFLAGS="-D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64" CFLAGS="-D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64  -Os " CXXFLAGS="-D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64  -Os " LDFLAGS="" FCFLAGS="" PKG_CONFIG="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/pkg-config" STAGING_DIR="/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/riscv64-buildroot-linux-gnu/sysroot" INTLTOOL_PERL=/usr/bin/perl ac_cv_lbl_unaligned_fail=yes ac_cv_func_mmap_fixed_mapped=yes ac_cv_func_memcmp_working=yes ac_cv_have_decl_malloc=yes gl_cv_func_malloc_0_nonnull=yes ac_cv_func_malloc_0_nonnull=yes ac_cv_func_calloc_0_nonnull=yes ac_cv_func_realloc_0_nonnull=yes lt_cv_sys_lib_search_path_spec="" ac_cv_c_bigendian=no  CFLAGS="-D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64  -Os  -DGQ" CONFIG_SITE=/dev/null ./configure --target=riscv64-buildroot-linux-gnu --host=riscv64-buildroot-linux-gnu --build=x86_64-pc-linux-gnu --prefix=/usr --exec-prefix=/usr --sysconfdir=/etc --localstatedir=/var --program-prefix="" --disable-gtk-doc --disable-gtk-doc-html --disable-doc --disable-docs --disable-documentation --with-xmlto=no --with-fop=no --disable-dependency-tracking --enable-ipv6  --disable-static --enable-shared  --disable-gssapi )
configure: WARNING: unrecognized options: --disable-gtk-doc, --disable-gtk-doc-html, --disable-doc, --disable-docs, --disable-documentation, --with-xmlto, --with-fop
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for riscv64-buildroot-linux-gnu-strip... /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-strip
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether make supports nested variables... (cached) yes
checking for riscv64-buildroot-linux-gnu-gcc... /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/riscv64-unknown-linux-gnu-gcc
checking whether the C compiler works... no
configure: error: in `/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/libtirpc-1.0.1':
configure: error: C compiler cannot create executables
See `config.log' for more details
package/pkg-generic.mk:185: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/libtirpc-1.0.1/.stamp_configured' failed
make[1]: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/libtirpc-1.0.1/.stamp_configured] Error 77
make[1]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
Makefile:90: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar' failed
make: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar] Error 2

Hmmm. Frustrating. Let's get back onto the new gcc-7.3 compiler and glibc-2.27 in Debian Buster.

To be continued...

linux compilation failure with latest riscv-all branch

I checked out the latest riscv-all branch from riscv-linux and started getting following compilation error. Here is my commit log which matches [https://github.com/riscv/riscv-linux/commits/riscv-all]

54d5353c automerging branch "kernel.org-palmer-linux/wip-xilinx_of" into "riscv-all"
2665c958 automerging branch "kernel.org-palmer-linux/wip-xilinx_32bit_dma" into "riscv-all"
5d5ffd76 automerging branch "kernel.org-palmer-linux/wip-timer" into "riscv-all"
15460ab8 automerging branch "kernel.org-palmer-linux/wip-sifive_serial" into "riscv-all"
12cb6d82 automerging branch "kernel.org-palmer-linux/wip-seccomp" into "riscv-all"
5deeb826 automerging branch "kernel.org-palmer-linux/wip-prci_clock" into "riscv-all"
e6a6cf2a automerging branch "kernel.org-palmer-linux/wip-of_order" into "riscv-all"
58f43107 automerging branch "kernel.org-palmer-linux/wip-is25wp256d" into "riscv-all"
e67cd5b7 automerging branch "kernel.org-palmer-linux/wip-irq-3-plic" into "riscv-all"
e249a1b8 automerging branch "kernel.org-palmer-linux/wip-gemgxl_clock_driver" into "riscv-all"
706f9467 automerging branch "kernel.org-palmer-linux/wip-futex_cmpxchg" into "riscv-all"
76cf2cee automerging branch "kernel.org-palmer-linux/wip-fespi" into "riscv-all"
7eacc17a automerging branch "kernel.org-palmer-linux/wip-dt_enable" into "riscv-all"
30f4e8e5 automerging branch "kernel.org-palmer-linux/wip-dma" into "riscv-all"
fa6f7ded automerging branch "kernel.org-palmer-linux/wip-cleanup_generic_irq" into "riscv-all"
113dbaa9 automerging branch "kernel.org-palmer-linux/wip-32bit_dma" into "riscv-all"
005e05ee automerging branch "kernel.org-palmer-linux/review-intc" into "riscv-all"
230999e8 automerging branch "kernel.org-palmer-linux/review-early_printk" into "riscv-all"
a5746143 automerging branch "kernel.org-palmer-linux/review-dt-timebase" into "riscv-all"
1aae169d automerging branch "kernel.org-palmer-linux/fix-ptrace" into "riscv-all"
9f400bab automerging branch "kernel.org-palmer-linux/fix-lustig" into "riscv-all"
9d2c75e4 automerging branch "kernel.org-palmer-linux/fix-intc" into "riscv-all"
013dbd9f automerging branch "kernel.org-palmer-linux/fix-device-init" into "riscv-all"
d40dc71d automerging branch "kernel.org-palmer-linux/fix-addsub32" into "riscv-all"
463ab03d automerging branch "github.com-riscv-riscv_linux/wip-perf_events" into "riscv-all"
d72e90f3 Linux 4.18-rc6

Here is the build error:

gcc: error: unrecognized argument in option โ€˜-mabi=lp64โ€™
gcc: note: valid arguments to โ€˜-mabi=โ€™ are: ms sysv
gcc: error: unrecognized argument in option โ€˜-mcmodel=medanyโ€™
gcc: note: valid arguments to โ€˜-mcmodel=โ€™ are: 32 kernel large medium small
  CC      scripts/mod/devicetable-offsets.s
gcc: error: unrecognized command line option โ€˜-mno-save-restoreโ€™
/home/atish/workspace/freedom-u-sdk/linux/scripts/Makefile.build:317: recipe for target 'scripts/mod/empty.o' failed
make[4]: *** [scripts/mod/empty.o] Error 1
make[4]: *** Waiting for unfinished jobs....
gcc: error: unrecognized argument in option โ€˜-mabi=lp64โ€™
gcc: note: valid arguments to โ€˜-mabi=โ€™ are: ms sysv
gcc: error: unrecognized argument in option โ€˜-mcmodel=medanyโ€™
gcc: note: valid arguments to โ€˜-mcmodel=โ€™ are: 32 kernel large medium small
gcc: error: unrecognized command line option โ€˜-mno-save-restoreโ€™

However, if I checkout riscv-all based on 4.17, it works fine. I have not modified any other repo in between. Here is the commit history that builds fine.

f37675f7 automerging branch "kernel.org-palmer-linux/wip-xilinx_of" into "riscv-all"
8538d0f4 automerging branch "kernel.org-palmer-linux/wip-timer" into "riscv-all"
4b520023 automerging branch "kernel.org-palmer-linux/wip-sifive_serial" into "riscv-all"
c41f4a3c automerging branch "kernel.org-palmer-linux/wip-seccomp" into "riscv-all"
ed547257 automerging branch "kernel.org-palmer-linux/wip-prci_clock" into "riscv-all"
e6413491 automerging branch "kernel.org-palmer-linux/wip-of_order" into "riscv-all"
ef97dca8 automerging branch "kernel.org-palmer-linux/wip-is25wp256d" into "riscv-all"
328762a3 automerging branch "kernel.org-palmer-linux/wip-irq-3-plic" into "riscv-all"
438f7875 automerging branch "kernel.org-palmer-linux/wip-irq-2-hlic" into "riscv-all"
50ed6521 automerging branch "kernel.org-palmer-linux/wip-gemgxl_clock_driver" into "riscv-all"
2bc4cbac automerging branch "kernel.org-palmer-linux/wip-futex_cmpxchg" into "riscv-all"
2b42e640 automerging branch "kernel.org-palmer-linux/wip-fespi" into "riscv-all"
aa059c0b automerging branch "kernel.org-palmer-linux/wip-early_printk" into "riscv-all"
7f9a09bd automerging branch "kernel.org-palmer-linux/wip-dt_enable" into "riscv-all"
d2e978e1 automerging branch "kernel.org-palmer-linux/wip-dt-timebase" into "riscv-all"
841e320f automerging branch "kernel.org-palmer-linux/wip-dma" into "riscv-all"
2b1d264b automerging branch "kernel.org-palmer-linux/wip-cleanup_generic_irq" into "riscv-all"
a6dbb425 automerging branch "kernel.org-palmer-linux/review-console_defconfig" into "riscv-all"
250d493d automerging branch "kernel.org-palmer-linux/next-swiotlb" into "riscv-all"
8015ec09 automerging branch "kernel.org-palmer-linux/next-perf" into "riscv-all"
3e45350c automerging branch "kernel.org-palmer-linux/fix-sparse" into "riscv-all"
a7c82dbd automerging branch "kernel.org-palmer-linux/fix-sifive_maintainers" into "riscv-all"
078f862c automerging branch "kernel.org-palmer-linux/fix-r_riscv_32" into "riscv-all"
3ec20502 automerging branch "kernel.org-palmer-linux/fix-module_alloc" into "riscv-all"
b4ee212a automerging branch "kernel.org-palmer-linux/fix-memaccess_fixup" into "riscv-all"
4d0ca61c automerging branch "kernel.org-palmer-linux/fix-mcount_ftrace" into "riscv-all"
8c0af6f6 automerging branch "kernel.org-palmer-linux/fix-checkflags" into "riscv-all"
0ff797fb automerging branch "github.com-riscv-riscv_linux/wip-perf_events" into "riscv-all"
86406d51 riscv: split the declaration of __copy_user
a93858bc RISC-V: Handle R_RISCV_32 in modules
2f09f36b riscv/ftrace: Export _mcount when DYNAMIC_FTRACE isn't set
9bf97390 riscv: no __user for probe_kernel_address()
2861ae30 riscv: use NULL instead of a plain 0
3b15f447 riscv: add riscv-specific predefines to CHECKFLAGS
9c521764 MAINTAINERS: Update Albert's email, he's back at Berkeley
3ed45d7f MAINTAINERS: Add myself as a maintainer for SiFive's drivers
25d26dfc RISC-V: Load modules within relative jump range of the kernel text.
12eee80b riscv: Fix the bug in memory access fixup code
29dcea88 Linux 4.17

Am I missing something ? @jim-wilson @palmer-dabbelt
Google search results seems to indicate the above compilation errors are gcc related. However, I am not able to understand how switching linux kernel version affects this.

Compatible Rocket Chip Commit for Multicore?

Hi there,

I am starting to develop an accelerator for the Rocket Chip using its RoCC interface, but it has been a bit difficult to find a combination of versions for rocket-chip/riscv-tools/riscv-linux that works for multicore configurations of that SoC. On the other hand, the latest hifiveu-1.0-2018-03-20 release of this repository seems very promising.

That said, does anyone know a commit from Rocket Chip that is guaranteed to work with this latest release tag?

Besides, am I right to suppose that both the riscv-gnu-toolchain and riscv-linux repos here submoduled already target priv-1.10?

I would be immensely grateful for any help with this, as the process of checking out commits, configuring Linux, compiling everything, generating a bitstream and testing on the board does take some time x)

spike bbl command is going into debug mode

With the latest version from master branch of this repository, the spike bbl command is running into a debug mode and refusing to load up the entire kernel

admin1@admin:/Desktop/riscv/freedom-u-sdk/riscv-pk/build$ spike bbl /home/admin1/Desktop/riscv/freedom-u-sdk/linux/vmlinux
[ 0.000000] OF: fdt: Ignoring memory range 0x80000000 - 0x80200000
[ 0.000000] Linux version 4.14.0-rc7+ (admin1@admin) (gcc version 7.2.0 (GCC)) #4 Thu Nov 9 16:33:19 IST 2017
[ 0.000000] bootconsole [early0] enabled
[ 0.000000] Initial ramdisk at: 0xffffffe00002a9f0 (406030 bytes)
[ 0.000000] Zone ranges:
[ 0.000000] DMA [mem 0x0000000080200000-0x00000000ffffffff]
[ 0.000000] Normal empty
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x0000000080200000-0x00000000ffffffff]
[ 0.000000] Initmem setup node 0 [mem 0x0000000080200000-0x00000000ffffffff]
[ 0.000000] elf_hwcap is 0x112d
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 515592
[ 0.000000] Kernel command line:
[ 0.000000] PID hash table entries: 4096 (order: 3, 32768 bytes)
[ 0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes)
[ 0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes)
[ 0.000000] Sorting __ex_table...
[ 0.000000] Memory: 2049964K/2095104K available (4709K kernel code, 444K rwdata, 2424K rodata, 576K init, 1047K bss, 45140K reserved, 0K cma-reserved)
[ 0.000000] random: get_random_u64 called from cache_random_seq_create+0x52/0xf4 with crng_init=0
[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[ 0.000000] NR_IRQS: 0, nr_irqs: 0, preallocated irqs: 0
[ 0.000000] riscv,cpu_intc,0: 64 local interrupts mapped
[ 0.000000] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[ 0.000000] Console: colour dummy device 80x25
[ 0.000000] console [tty0] enabled
[ 0.000000] bootconsole [early0] disabled
^C:
core 0: 0xffffffe00025855e (0x00f586b3) add a3, a1, a5
:
core 0: 0xffffffe000258562 (0x00006294) ld a3, 0(a3)
:
core 0: 0xffffffe000258564 (0x0000983a) add a6, a6, a4
:
core 0: 0xffffffe000258566 (0x000097aa) add a5, a5, a0
:
core 0: 0xffffffe000258568 (0x41068333) sub t1, a3, a6
: ^Cadmin1@admin:
/Desktop/riscv/freedom-u-sdk/riscv-pk/build$

How to add files or directories into bbl.bin

Linux has run on my zc707 successfully, and I want to add files or directories in some subdirectories, such as /root.

When I modified the initramfs.txt in conf subdirectory, the bbl.bin got bigger. But I couldn't see my file in linux.

When I modified the initramfs.txt in linux/arch/riscv subdirectory and added its path through make linux-menuconfig, the bbl.bin remains invariant.

I don't know why.

I tried to modified buildroot, but don't konw how to do it.

Thanks for your help.

Issue with creating Sifive risc-v port

I am executing a $ make Sim command.but i got error like this **bootconsole [early0] disabled
** .
Can any one please give me solution for this

/home/billa/Sifive/freedom-u-sdk/work/riscv-isa-sim/prefix/bin/spike --isa=rv64imafdc -p4 /home/billa/Sifive/freedom-u-sdk/work/riscv-pk/bbl
bbl loader

            SIFIVE, INC.

     5555555555555555555555555
    5555                   5555
   5555                     5555
  5555                       5555
 5555       5555555555555555555555
5555       555555555555555555555555

5555 5555
5555 5555
5555 5555
5555555555555555555555555555 55555
55555 555555555 55555
55555 55555 55555
55555 5 55555
55555 55555
55555 55555
55555 55555
55555 55555
55555 55555
555555555
55555
5

       SiFive RISC-V Coreplex

[ 0.000000] OF: fdt: Ignoring memory range 0x80000000 - 0x80200000
[ 0.000000] Linux version 4.15.0-00044-g2b0aa1d (billa@billa-PC) (gcc version 7.2.0 (GCC)) #2 SMP Mon Apr 2 15:26:12 IST 2018
[ 0.000000] bootconsole [early0] enabled
[ 0.000000] Initial ramdisk at: 0x (ptrval) (9436160 bytes)
[ 0.000000] Zone ranges:
[ 0.000000] DMA32 [mem 0x0000000080200000-0x00000000ffffffff]
[ 0.000000] Normal [mem 0x0000000100000000-0x00000fffffffffff]
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x0000000080200000-0x00000000ffffffff]
[ 0.000000] Initmem setup node 0 [mem 0x0000000080200000-0x00000000ffffffff]
[ 0.000000] software IO TLB [mem 0xfa3fd000-0xfe3fd000] (64MB) mapped at [ (ptrval)- (ptrval)]
[ 0.000000] elf_hwcap is 0x112d
[ 0.000000] percpu: Embedded 14 pages/cpu @ (ptrval) s28632 r0 d28712 u57344
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 516615
[ 0.000000] Kernel command line:
[ 0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes)
[ 0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes)
[ 0.000000] Sorting __ex_table...
[ 0.000000] Memory: 1982864K/2095104K available (3073K kernel code, 212K rwdata, 840K rodata, 9379K init, 780K bss, 112240K reserved, 0K cma-reserved)
[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[ 0.000000] Hierarchical RCU implementation.
[ 0.000000] RCU event tracing is enabled.
[ 0.000000] RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=4.
[ 0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=4
[ 0.000000] NR_IRQS: 0, nr_irqs: 0, preallocated irqs: 0
[ 0.000000] riscv,cpu_intc,0: 64 local interrupts mapped
[ 0.000000] riscv,cpu_intc,1: 64 local interrupts mapped
[ 0.000000] riscv,cpu_intc,2: 64 local interrupts mapped
[ 0.000000] riscv,cpu_intc,3: 64 local interrupts mapped
[ 0.000000] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[ 0.000010] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[ 0.000995] Calibrating delay loop (skipped), value calculated using timer frequency.. 20.00 BogoMIPS (lpj=100000)
[ 0.002200] pid_max: default: 32768 minimum: 301
[ 0.002805] Mount-cache hash table entries: 4096 (order: 3, 32768 bytes)
[ 0.003590] Mountpoint-cache hash table entries: 4096 (order: 3, 32768 bytes)
[ 0.005355] Hierarchical SRCU implementation.
[ 0.007430] smp: Bringing up secondary CPUs ...
[ 0.008570] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[ 0.009880] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[ 0.011640] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[ 0.012950] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[ 0.014690] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[ 0.016000] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[ 0.017145] smp: Brought up 1 node, 4 CPUs
[ 0.018075] devtmpfs: initialized
[ 0.019020] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[ 0.020160] futex hash table entries: 1024 (order: 4, 65536 bytes)
[ 0.021110] random: get_random_u32 called from bucket_table_alloc+0xe6/0x276 with crng_init=0
[ 0.022160] NET: Registered protocol family 16
[ 0.025460] vgaarb: loaded
[ 0.025900] SCSI subsystem initialized
[ 0.026635] usbcore: registered new interface driver usbfs
[ 0.027285] usbcore: registered new interface driver hub
[ 0.028050] usbcore: registered new device driver usb
[ 0.028665] pps_core: LinuxPPS API ver. 1 registered
[ 0.029245] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti [email protected]
[ 0.030310] PTP clock support registered
[ 0.031200] clocksource: Switched to clocksource riscv_clocksource
[ 0.033115] NET: Registered protocol family 2
[ 0.033905] TCP established hash table entries: 16384 (order: 5, 131072 bytes)
[ 0.034945] TCP bind hash table entries: 16384 (order: 6, 262144 bytes)
[ 0.035910] TCP: Hash tables configured (established 16384 bind 16384)
[ 0.036705] UDP hash table entries: 1024 (order: 3, 32768 bytes)
[ 0.037440] UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes)
[ 0.038275] NET: Registered protocol family 1
[ 0.060930] Unpacking initramfs...
[ 0.087145] Initialise system trusted keyrings
[ 0.087860] workingset: timestamp_bits=62 max_order=19 bucket_order=0
[ 0.093905] random: fast init done
[ 0.108730] jitterentropy: Initialization failed with host not compliant with requirements: 2
[ 0.109720] Key type asymmetric registered
[ 0.110200] Asymmetric key parser 'x509' registered
[ 0.110780] io scheduler noop registered
[ 0.111430] io scheduler cfq registered (default)
[ 0.111980] io scheduler mq-deadline registered
[ 0.112510] io scheduler kyber registered
[ 0.170965] Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
[ 0.172820] libphy: Fixed MDIO Bus: probed
[ 0.173370] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 0.174130] ehci-pci: EHCI PCI platform driver
[ 0.174690] usbcore: registered new interface driver usb-storage
[ 0.175525] usbcore: registered new interface driver usbhid
[ 0.176175] usbhid: USB HID core driver
[ 0.176795] NET: Registered protocol family 17
[ 0.177780] bootconsole [early0] uses init memory and must be disabled even before the real one is ready
[ 0.178880] bootconsole [early0] disabled

fopen returns errno 38

Hello,
I use the newest freedom-u-sdk, commit id: 97b2ca1, to run a binary contains fopen function. However, it returns errno 38, which is 'not implemented'. This exact same issue had been addressed in Issue #86 in riscv-linux sub-directory, but the problem seems to manifest again with the newest commit.

My freedom project commit id is 89059e7.
Thank you

Failed to boot linux with master branch

I used to use no-pcie2 branch of freedom and hifive-unleashed branch of freedom-u-sdk when I didn't have a FMC card, and successfully boot linux in VC707. Now I get a FMC card and clone the master branch of freedom and freedom-u-sdk. Nothing goes wrong in compile process. But I didn't didn't see any output in minicom.

freedom commit id cd9a525a662b9eaf27c14533159d723efcf4c184
freedom-u-sdk commit id 62ae153.
Vivado 2016.4

Build 32-bit target failed

Hi,

I am trying to build 32-bit target from freedom-u-sdk. The build of 64-bit target works well but the 32-bit failed. What I am doing is modifying the Makefile and changed the variables

ISA ?= rv32ima
ABI ?= ilp32

Then type make linux and I got no rule to make target error:

image

Please help to point out what I am doing wrong.

Thanks in advance,
Kai-Yuan

the bootloader runs, but fails to boot linux

@palmer-dabbelt @terpstra

Hello.

I can not boot because of the following reasons.
sifive/freedom#38

The source code was not booted for the same reason before it was updated.
Is the installation and setup wrong?

Below are the logs that created the bitstream and image file using freedom and freedom-u-sdk.

freedom(/master)

# make -f Makefile.u500vc707devkit verilog
# make -f Makefile.u500vc707devkit mcs

Bitstream generation succeeded (Vivado : 2016_01)

freedom-u-sdk(/master)

$ /freedom-u-sdk# cd riscv-gnu-toolchain
$ make & linux make
 -> Toolchain installation (7.2.0)
$ /freedom-u-sdk# make
 -> linux image generation

Unescaped left brace in regex is illegal here in regex; marked by <-- HERE in m/\${ <-- HERE ([^ \t=:+{}]+)}/ at /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/automake line 3936.

>>> libtirpc 1.0.1 Updating config.sub and config.guess
for file in config.guess config.sub; do for i in $(find /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_initramfs/build/libtirpc-1.0.1 -name $file); do cp support/gnuconfig/$file $i; done; done
>>> libtirpc 1.0.1 Configuring
>>> libtirpc 1.0.1 Autoreconfiguring
libtoolize: putting auxiliary files in '.'.
libtoolize: copying file './ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
libtoolize: copying file 'm4/libtool.m4'
libtoolize: copying file 'm4/ltoptions.m4'
libtoolize: copying file 'm4/ltsugar.m4'
libtoolize: copying file 'm4/ltversion.m4'
libtoolize: copying file 'm4/lt~obsolete.m4'
Unescaped left brace in regex is illegal here in regex; marked by <-- HERE in m/\${ <-- HERE ([^ \t=:+{}]+)}/ at /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/automake line 3936.
autoreconf: /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/automake failed with exit status: 255
package/pkg-generic.mk:185: recipe for target '/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_initramfs/build/libtirpc-1.0.1/.stamp_configured' failed
make[1]: *** [/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_initramfs/build/libtirpc-1.0.1/.stamp_configured] Error 1
make[1]: Leaving directory '/home/spaceboyross/TheBlueSystem/freedom-u-sdk/buildroot'
Makefile:90: recipe for target '/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar' failed
make: *** [/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar] Error 2

failed to boot linux

freedom commit id cd9a525a662b9eaf27c14533159d723efcf4c184
freedom-u-sdk commit id 62ae153
vivado 2016.4
Nothing went wrong during compilation. But when I boot linux, error message occurred

INIT
CMD0
CMD8
ACMD41
CMD58
CMD16
CMD18
LOADING  
BOOT
bbl loader

                SIFIVE, INC.

         5555555555555555555555555
        5555                   5555
       5555                     5555
      5555                       5555
     5555       5555555555555555555555
    5555       555555555555555555555555
   5555                             5555
  5555                               5555
 5555                                 5555
5555555555555555555555555555          55555
 55555           555555555           55555
   55555           55555           55555
     55555           5           55555
       55555                   55555
         55555               55555
           55555           55555
             55555       55555
               55555   55555
                 555555555
                   55555
                     5

           SiFive RISC-V Coreplex
[    0.000000] OF: fdt: Ignoring memory range 0x80000000 - 0x80200000
[    0.000000] Linux version 4.15.0-00044-g2b0aa1d (xqz@cas) (gcc version 7.2.0 (GCC)) #3 SMP Tue May 15 15:34:10 CST 2018
[    0.000000] bootconsole [early0] enabled
[    0.000000] Initial ramdisk at: 0x        (ptrval) (9436160 bytes)
[    0.000000] Zone ranges:
[    0.000000]   DMA32    [mem 0x0000000080200000-0x00000000bfffffff]
[    0.000000]   Normal   [mem 0x00000000c0000000-0x00000bffffffffff]
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000080200000-0x00000000bfffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000080200000-0x00000000bfffffff]
[    0.000000] software IO TLB [mem 0xbb1fb000-0xbf1fb000] (64MB) mapped at [        (ptrval)-        (ptrval)]
[    0.000000] elf_hwcap is 0x112d
[    0.000000] percpu: Embedded 14 pages/cpu @        (ptrval) s28632 r0 d28712 u57344
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 258055
[    0.000000] Kernel command line: 
[    0.000000] Dentry cache hash table entries: 131072 (order: 8, 1048576 bytes)
[    0.000000] Inode-cache hash table entries: 65536 (order: 7, 524288 bytes)
[    0.000000] Sorting __ex_table...
[    0.000000] Memory: 950092K/1046528K available (3110K kernel code, 215K rwdata, 856K rodata, 9379K init, 780K bss, 96436K reserved, )
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000]  RCU event tracing is enabled.
[    0.000000]  RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=4.
[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=4
[    0.000000] NR_IRQS: 0, nr_irqs: 0, preallocated irqs: 0
[    0.000000] riscv,cpu_intc,0: 64 local interrupts mapped
[    0.000000] riscv,cpu_intc,1: 64 local interrupts mapped
[    0.000000] riscv,cpu_intc,2: 64 local interrupts mapped
[    0.000000] riscv,cpu_intc,3: 64 local interrupts mapped
[    0.000000] ------------[ cut here ]------------
[    0.000000] WARNING: CPU: 3 PID: 0 at /home/xqz/sifive/freedom-u-sdk/linux/drivers/irqchip/irq-riscv-intc.c:158 riscv_irq_enable+0x94
[    0.000000] CPU: 3 PID: 0 Comm: swapper/3 Not tainted 4.15.0-00044-g2b0aa1d #3
[    0.000000] Call Trace:
[    0.000000] [<        (ptrval)>] walk_stackframe+0x0/0xa2
[    0.000000] [<        (ptrval)>] show_stack+0x26/0x34
[    0.000000] [<        (ptrval)>] dump_stack+0x5e/0x7c
[    0.000000] [<        (ptrval)>] __warn+0xc6/0xdc
[    0.000000] [<        (ptrval)>] warn_slowpath_null+0x2c/0x3e
[    0.000000] [<        (ptrval)>] riscv_irq_enable+0x8e/0x94
[    0.000000] [<        (ptrval)>] irq_enable+0x3a/0x6a
[    0.000000] [<        (ptrval)>] __irq_startup+0x80/0x88
[    0.000000] [<        (ptrval)>] irq_startup+0x4e/0xe2
[    0.000000] [<        (ptrval)>] irq_activate_and_startup+0x1c/0x28
[    0.000000] [<        (ptrval)>] __irq_do_set_handler+0x6e/0x134
[    0.000000] [<        (ptrval)>] irq_set_chained_handler_and_data+0x2c/0x4a
[    0.000000] [<        (ptrval)>] plic_init+0x1ea/0x316
[    0.000000] [<        (ptrval)>] of_irq_init+0x136/0x252
[    0.000000] [<        (ptrval)>] irqchip_init+0x10/0x1c
[    0.000000] [<        (ptrval)>] init_IRQ+0x8/0x14
[    0.000000] [<        (ptrval)>] start_kernel+0x20a/0x350
[    0.000000] [<        (ptrval)>] _sinittext+0x4e/0x56
[    0.000000] random: get_random_bytes called from print_oops_end_marker+0x3a/0x52 with crng_init=0
[    0.000000] ---[ end trace 0000000000000000 ]---
[    0.000000] riscv,plic0,c000000: mapped 7 interrupts to 4/8 handlers
[    0.000000] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x1d854df40, max_idle_ns: 3526361616960 ns
[    0.000125] sched_clock: 64 bits at 1000kHz, resolution 1000ns, wraps every 2199023255500ns
[    0.009300] Calibrating delay loop (skipped), value calculated using timer frequency.. 2.00 BogoMIPS (lpj=10000)
[    0.019413] pid_max: default: 32768 minimum: 301
[    0.026667] Mount-cache hash table entries: 2048 (order: 2, 16384 bytes)
[    0.033720] Mountpoint-cache hash table entries: 2048 (order: 2, 16384 bytes)
[    0.067048] Hierarchical SRCU implementation.
[    0.084172] smp: Bringing up secondary CPUs ...
[    0.098377] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x1d854df40, max_idle_ns: 3526361616960 ns
[    0.109161] sched_clock: 64 bits at 1000kHz, resolution 1000ns, wraps every 2199023255500ns
[    0.131541] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x1d854df40, max_idle_ns: 3526361616960 ns
[    0.142329] sched_clock: 64 bits at 1000kHz, resolution 1000ns, wraps every 2199023255500ns
[    0.163958] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x1d854df40, max_idle_ns: 3526361616960 ns
[    0.174743] sched_clock: 64 bits at 1000kHz, resolution 1000ns, wraps every 2199023255500ns
[    0.185514] smp: Brought up 1 node, 4 CPUs
[    0.199657] devtmpfs: initialized
[    0.234821] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.244681] futex hash table entries: 1024 (order: 4, 65536 bytes)
[   15.762629] ------------[ cut here ]------------
[   15.767487] WARNING: CPU: 3 PID: 1 at /home/xqz/sifive/freedom-u-sdk/linux/mm/page_alloc.c:3926 __alloc_pages_nodemask+0x130/0x8da
[   15.779099] CPU: 3 PID: 1 Comm: swapper/3 Tainted: G        W        4.15.0-00044-g2b0aa1d #3
[   15.787177] Call Trace:
[   15.789814] [<        (ptrval)>] walk_stackframe+0x0/0xa2
[   15.795136] [<        (ptrval)>] show_stack+0x26/0x34
[   15.800190] [<        (ptrval)>] dump_stack+0x5e/0x7c
[   15.805200] [<        (ptrval)>] __warn+0xc6/0xdc
[   15.809908] [<        (ptrval)>] warn_slowpath_null+0x2c/0x3e
[   15.815698] [<        (ptrval)>] __alloc_pages_nodemask+0x12c/0x8da
[   15.821938] [<        (ptrval)>] kmalloc_order+0x12/0x52
[   15.827254] [<        (ptrval)>] __kmalloc+0x122/0x156
[   15.832358] [<        (ptrval)>] __register_sysctl_table+0x4a/0x450
[   15.838602] [<        (ptrval)>] register_sysctl+0x14/0x20
[   15.844129] [<        (ptrval)>] net_sysctl_init+0x1e/0x68
[   15.849564] [<        (ptrval)>] sock_init+0xa/0xa0
[   15.854437] [<        (ptrval)>] do_one_initcall+0x6c/0xf8
[   15.859921] [<        (ptrval)>] kernel_init_freeable+0x126/0x1be
[   15.866077] [<        (ptrval)>] kernel_init+0xe/0xf0
[   15.871079] [<        (ptrval)>] ret_from_syscall+0xa/0xe
[   15.876871] ---[ end trace 28977a436e0715df ]---
[   15.884523] NET: Registered protocol family 16
[   15.889207] Unable to handle kernel NULL pointer dereference at virtual address 0000000000000008
[   15.897452] Oops [#1]
[   15.899770] CPU: 3 PID: 1 Comm: swapper/3 Tainted: G        W        4.15.0-00044-g2b0aa1d #3
[   15.908256] sepc: ffffffe000b97290 ra : ffffffe000b97bfc sp : ffffffe03a679be0
[   15.915470]  gp : ffffffe000d3ea80 tp : ffffffe03a670000 t0 : ffffffe03a6460c0
[   15.922690]  t1 : 0000000200000022 t2 : ffffffe03a679c70 s0 : ffffffe03a679c00
[   15.929905]  s1 : ffffffe03a679c28 a0 : 0000000000000010 a1 : 0000000000000002
[   15.937126]  a2 : 0000000000000000 a3 : ffffffe03a679c28 a4 : 0000000000000000
[   15.944354]  a5 : 0000000000000000 a6 : ffffffe000deb770 a7 : 000000003a661000
[   15.951568]  s2 : 0000000000000002 s3 : 0000000000000000 s4 : 0000000000000000
[   15.958800]  s5 : ffffffe000d33430 s6 : ffffffe000d40050 s7 : 000000000000001f
[   15.966024]  s8 : ffffffe000c75270 s9 : 00000000000000d8 s10: ffffffe000d3eb68
[   15.973238]  s11: 0000000000000000 t3 : 000000000001e3c8 t4 : 000000000001e3c8
[   15.980446]  t5 : 0000000000000000 t6 : ffffffe03a646095
[   15.985774] sstatus: 0000000200000120 sbadaddr: 0000000000000008 scause: 000000000000000d
[   15.994327] ---[ end trace 28977a436e0715e0 ]---
[   15.998715] Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b
[   15.998715] 

An error occurred in the new version using make all

I downloaded the latest version, did not change Makefile, and then I used make all to build it with the following errors.
It looks like the library file could not be found while compiling the linux kernel. Where is the path configuration error?
How do I fix it?
qq 20180215175259
image
@jim-wilson Hi,jim.I need your help again,thank you.
And It's the new year in China now,happy new year to you.

how to use gdbserver in vc707

I want to debug my program with gdb in vc707. It seems I need to build a gdb in my host and a gdbserver on target board.
make buildroot-menuconfig in Toolchain , I selected Build cross gdb for the host (NEW) or Copy gdb server to the Target , but didn't see gdb or gdbserver generated. How should I do?

If I use the repository, riscv-binutils-gdb, how to generate riscv64 gdb and gdbserver ?

no console output after bootconsole disabled.

Just found that there is no output after bootconsole disabled by kernel.

$ make qemu
/data/riscv/freedom-u-sdk/work/riscv-qemu/prefix/bin/qemu-system-riscv64 -nographic -machine virt -kernel /data/riscv/freedom-u-sdk/work/riscv-pk/bbl \
	-drive file=/data/riscv/freedom-u-sdk/work/rootfs.bin,format=raw,id=hd0 -device virtio-blk-device,drive=hd0 \
	-netdev user,id=net0 -device virtio-net-device,netdev=net0
bbl loader

                SIFIVE, INC.

         5555555555555555555555555
        5555                   5555
       5555                     5555
      5555                       5555
     5555       5555555555555555555555
    5555       555555555555555555555555
   5555                             5555
  5555                               5555
 5555                                 5555
5555555555555555555555555555          55555
 55555           555555555           55555
   55555           55555           55555
     55555           5           55555
       55555                   55555
         55555               55555
           55555           55555
             55555       55555
               55555   55555
                 555555555
                   55555
                     5

           SiFive RISC-V Coreplex
[    0.000000] OF: fdt: Ignoring memory range 0x80000000 - 0x80200000
[    0.000000] Linux version 4.15.0-00044-g2b0aa1d (alex@alex-x230) (gcc version 7.2.0 (GCC)) #7 SMP Thu Mar 22 11:16:07 CST 2018
[    0.000000] bootconsole [early0] enabled
[    0.000000] Initial ramdisk at: 0x        (ptrval) (5672960 bytes)
[    0.000000] Zone ranges:
[    0.000000]   DMA32    [mem 0x0000000080200000-0x0000000087ffffff]
[    0.000000]   Normal   [mem 0x0000000088000000-0x0000087fffffffff]
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000080200000-0x0000000087ffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000080200000-0x0000000087ffffff]
[    0.000000] software IO TLB [mem 0x83e3d000-0x87e3d000] (64MB) mapped at [        (ptrval)-        (ptrval)]
[    0.000000] elf_hwcap is 0x112d
[    0.000000] percpu: Embedded 14 pages/cpu @        (ptrval) s28632 r0 d28712 u57344
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 31815
[    0.000000] Kernel command line: earlyprintk
[    0.000000] Dentry cache hash table entries: 16384 (order: 5, 131072 bytes)
[    0.000000] Inode-cache hash table entries: 8192 (order: 4, 65536 bytes)
[    0.000000] Sorting __ex_table...
[    0.000000] Memory: 50372K/129024K available (3055K kernel code, 214K rwdata, 827K rodata, 5695K init, 775K bss, 78652K reserved, 0K cma-reserved)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000] 	RCU event tracing is enabled.
[    0.000000] 	RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
[    0.000000] NR_IRQS: 0, nr_irqs: 0, preallocated irqs: 0
[    0.000000] riscv,cpu_intc,0: 64 local interrupts mapped
[    0.000000] riscv,plic0,c000000: mapped 10 interrupts to 1/2 handlers
[    0.000000] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[    0.000193] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[    0.004177] Calibrating delay loop (skipped), value calculated using timer frequency.. 20.00 BogoMIPS (lpj=100000)
[    0.006901] pid_max: default: 32768 minimum: 301
[    0.009112] Mount-cache hash table entries: 512 (order: 0, 4096 bytes)
[    0.010731] Mountpoint-cache hash table entries: 512 (order: 0, 4096 bytes)
[    0.036960] Hierarchical SRCU implementation.
[    0.046558] smp: Bringing up secondary CPUs ...
[    0.047811] smp: Brought up 1 node, 1 CPU
[    0.084107] devtmpfs: initialized
[    0.093955] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.096091] futex hash table entries: 256 (order: 2, 16384 bytes)
[    0.102939] random: get_random_u32 called from bucket_table_alloc+0xe6/0x276 with crng_init=0
[    0.105357] NET: Registered protocol family 16
[    0.139454] vgaarb: loaded
[    0.141203] SCSI subsystem initialized
[    0.144195] usbcore: registered new interface driver usbfs
[    0.145932] usbcore: registered new interface driver hub
[    0.147567] usbcore: registered new device driver usb
[    0.149665] pps_core: LinuxPPS API ver. 1 registered
[    0.150879] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <[email protected]>
[    0.153130] PTP clock support registered
[    0.161982] clocksource: Switched to clocksource riscv_clocksource
[    0.170369] NET: Registered protocol family 2
[    0.175418] TCP established hash table entries: 1024 (order: 1, 8192 bytes)
[    0.177069] TCP bind hash table entries: 1024 (order: 2, 16384 bytes)
[    0.178490] TCP: Hash tables configured (established 1024 bind 1024)
[    0.181621] UDP hash table entries: 256 (order: 1, 8192 bytes)
[    0.182795] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[    0.185023] NET: Registered protocol family 1
[    0.448495] Unpacking initramfs...
[    0.745703] Initialise system trusted keyrings
[    0.748555] workingset: timestamp_bits=62 max_order=14 bucket_order=0
[    0.774849] random: fast init done
[    0.805829] Key type asymmetric registered
[    0.806810] Asymmetric key parser 'x509' registered
[    0.807919] io scheduler noop registered
[    0.809979] io scheduler cfq registered (default)
[    0.811298] io scheduler mq-deadline registered
[    0.813097] io scheduler kyber registered
[    1.027782] libphy: Fixed MDIO Bus: probed
[    1.034595] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    1.036306] ehci-pci: EHCI PCI platform driver
[    1.038008] usbcore: registered new interface driver usb-storage
[    1.041234] usbcore: registered new interface driver usbhid
[    1.043040] usbhid: USB HID core driver
[    1.044963] NET: Registered protocol family 17
[    1.048917] bootconsole [early0] uses init memory and must be disabled even before the real one is ready
[    1.051654] bootconsole [early0] disabled

Kernel fault when running bash/coreutils

We're trying to upgrade the rocket-chip version for firesim, but are having trouble running buildroot+linux. Everything seems to work fine if we use busybox for the shell and core utilities, but if we use bash as the default shell or use some of the GNU coreutils, we get kernel faults or segfaults (respectively). This happens both on the FPGA and in Spike.

I used the "new" branch of freedom-u-sdk. You can replicate the issue if you configure buildroot to use bash as the default shell.

trying to fetch instructions from an MMIO page

I use these tools to make my bbl

riscv-gnu-toolchain @ b4dae89
linux @ 87cb3b7
riscv-pk @ e2aad2d
riscv-qemu @ cd2c21d

but when use the command to boot the bbl there is something wrong

./qemu-system-riscv64 -kernel /home/czh/riscv/riscv-tools/riscv-pk/build/bbl -nographic -machine spike_v1.10

qemu show the error information

unassigned address not implemented for riscv
are you trying to fetch instructions from an MMIO page?
unassigned Address: fffffffffffff800

I compile the kerne with defconfig, ues pk tool to make the bbl .
what should I do.

Thanks in advance for your inputs and help

Python build finished, but the necessary bits to build these modules were not found

This happened when I tried make qemu.

make -C /home/spaceboyross/TheBlueSystem/freedom-u-sdk/buildroot RISCV=/home/spaceboyross/TheBlueSystem/freedom-u-sdk/toolchain PATH=/home/spaceboyross/TheBlueSystem/freedom-u-sdk/toolchain/bin:/home/spaceboyross/.nvm/versions/node/v8.11.3/bin:/home/spaceboyross/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin O=/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs
make[1]: Entering directory '/home/spaceboyross/TheBlueSystem/freedom-u-sdk/buildroot'
>>> host-python 2.7.11 Building
PATH="/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/host/bin:/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/host/sbin:/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/host/usr/bin:/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/host/usr/sbin:/home/spaceboyross/TheBlueSystem/freedom-u-sdk/toolchain/bin:/home/spaceboyross/.nvm/versions/node/v8.11.3/bin:/home/spaceboyross/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin" PKG_CONFIG="/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/host/usr/bin/pkg-config" PKG_CONFIG_SYSROOT_DIR="/" PKG_CONFIG_LIBDIR="/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/host/usr/lib/pkgconfig"  /usr/bin/make -j1  -C /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/
make[2]: Entering directory '/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11'
running build
running build_ext
INFO: Can't locate Tcl/Tk libs and/or headers
building '_ssl' extension
/usr/bin/gcc -pthread -fPIC -fno-strict-aliasing -O2 -I/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/host/usr/include -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I. -IInclude -I./Include -I/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/host/usr/include -I/usr/include/x86_64-linux-gnu -I/usr/local/include -I/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Include -I/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11 -c /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c -o build/temp.linux-x86_64-2.7/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.o
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c: In function โ€˜_create_tuple_for_X509_NAMEโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:684:35: error: dereferencing pointer to incomplete type โ€˜X509_NAME_ENTRY {aka struct X509_name_entry_st}โ€™
             if (rdn_level != entry->set) {
                                   ^~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c: In function โ€˜_get_peer_alt_namesโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:804:16: error: dereferencing pointer to incomplete type โ€˜X509_EXTENSION {aka struct X509_extension_st}โ€™
         p = ext->value->data;
                ^~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:876:17: warning: โ€˜ASN1_STRING_dataโ€™ is deprecated [-Wdeprecated-declarations]
                 v = PyString_FromStringAndSize((char *)ASN1_STRING_data(as),
                 ^
In file included from /usr/include/openssl/bn.h:31:0,
                 from /usr/include/openssl/asn1.h:24,
                 from /usr/include/openssl/rsa.h:16,
                 from /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:56:
/usr/include/openssl/asn1.h:553:1: note: declared here
 DEPRECATEDIN_1_1_0(unsigned char *ASN1_STRING_data(ASN1_STRING *x))
 ^
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c: In function โ€˜_get_crl_dpโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:1029:22: error: dereferencing pointer to incomplete type โ€˜X509 {aka struct x509_st}โ€™
     dps = certificate->crldp;
                      ^~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c: In function โ€˜PySSL_compressionโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:1446:43: error: dereferencing pointer to incomplete type โ€˜COMP_METHOD {aka const struct comp_method_st}โ€™
     if (comp_method == NULL || comp_method->type == NID_undef)
                                           ^~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c: In function โ€˜context_newโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:1997:9: warning: โ€˜TLSv1_methodโ€™ is deprecated [-Wdeprecated-declarations]
         ctx = SSL_CTX_new(TLSv1_method());
         ^~~
In file included from /usr/include/openssl/ct.h:13:0,
                 from /usr/include/openssl/ssl.h:61,
                 from /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:61:
/usr/include/openssl/ssl.h:1624:1: note: declared here
 DEPRECATEDIN_1_1_0(__owur const SSL_METHOD *TLSv1_method(void)) /* TLSv1.0 */
 ^
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:2000:9: warning: โ€˜TLSv1_1_methodโ€™ is deprecated [-Wdeprecated-declarations]
         ctx = SSL_CTX_new(TLSv1_1_method());
         ^~~
In file included from /usr/include/openssl/ct.h:13:0,
                 from /usr/include/openssl/ssl.h:61,
                 from /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:61:
/usr/include/openssl/ssl.h:1630:1: note: declared here
 DEPRECATEDIN_1_1_0(__owur const SSL_METHOD *TLSv1_1_method(void)) /* TLSv1.1 */
 ^
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:2002:9: warning: โ€˜TLSv1_2_methodโ€™ is deprecated [-Wdeprecated-declarations]
         ctx = SSL_CTX_new(TLSv1_2_method());
         ^~~
In file included from /usr/include/openssl/ct.h:13:0,
                 from /usr/include/openssl/ssl.h:61,
                 from /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:61:
/usr/include/openssl/ssl.h:1636:1: note: declared here
 DEPRECATEDIN_1_1_0(__owur const SSL_METHOD *TLSv1_2_method(void)) /* TLSv1.2 */
 ^
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:2010:27: warning: implicit declaration of function โ€˜SSLv2_methodโ€™; did you mean โ€˜SSLv23_methodโ€™? [-Wimplicit-function-declaration]
         ctx = SSL_CTX_new(SSLv2_method());
                           ^~~~~~~~~~~~
                           SSLv23_method
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:2010:27: warning: passing argument 1 of โ€˜SSL_CTX_newโ€™ makes pointer from integer without a cast [-Wint-conversion]
In file included from /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:61:0:
/usr/include/openssl/ssl.h:1333:17: note: expected โ€˜const SSL_METHOD * {aka const struct ssl_method_st *}โ€™ but argument is of type โ€˜intโ€™
 __owur SSL_CTX *SSL_CTX_new(const SSL_METHOD *meth);
                 ^~~~~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c: In function โ€˜get_verify_flagsโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:2331:46: error: dereferencing pointer to incomplete type โ€˜X509_STORE {aka struct x509_store_st}โ€™
     flags = X509_VERIFY_PARAM_get_flags(store->param);
                                              ^~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c: In function โ€˜load_cert_chainโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:2529:48: error: dereferencing pointer to incomplete type โ€˜SSL_CTX {aka struct ssl_ctx_st}โ€™
     pem_password_cb *orig_passwd_cb = self->ctx->default_passwd_callback;
                                                ^~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c: In function โ€˜cert_store_statsโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:3156:20: error: dereferencing pointer to incomplete type โ€˜X509_OBJECT {aka struct x509_object_st}โ€™
         switch (obj->type) {
                    ^~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:3166:18: error: โ€˜X509_LU_PKEYโ€™ undeclared (first use in this function); did you mean โ€˜X509_PKEYโ€™?
             case X509_LU_PKEY:
                  ^~~~~~~~~~~~
                  X509_PKEY
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:3166:18: note: each undeclared identifier is reported only once for each function it appears in
At top level:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:3851:13: warning: โ€˜_ssl_thread_locking_functionโ€™ defined but not used [-Wunused-function]
 static void _ssl_thread_locking_function
             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_ssl.c:3838:1: warning: โ€˜_ssl_threadid_callbackโ€™ defined but not used [-Wunused-function]
 _ssl_threadid_callback(CRYPTO_THREADID *id)
 ^~~~~~~~~~~~~~~~~~~~~~
building '_hashlib' extension
/usr/bin/gcc -pthread -fPIC -fno-strict-aliasing -O2 -I/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/host/usr/include -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I. -IInclude -I./Include -I/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/host/usr/include -I/usr/include/x86_64-linux-gnu -I/usr/local/include -I/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Include -I/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11 -c /home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c -o build/temp.linux-x86_64-2.7/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.o
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:61:25: error: field โ€˜ctxโ€™ has incomplete type
     EVP_MD_CTX          ctx;    /* OpenSSL message digest context */
                         ^~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c: In function โ€˜EVP_deallocโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:129:5: warning: implicit declaration of function โ€˜EVP_MD_CTX_cleanupโ€™; did you mean โ€˜EVP_MD_CTX_createโ€™? [-Wimplicit-function-declaration]
     EVP_MD_CTX_cleanup(&self->ctx);
     ^~~~~~~~~~~~~~~~~~
     EVP_MD_CTX_create
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c: In function โ€˜EVP_digestโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:165:16: error: storage size of โ€˜temp_ctxโ€™ isnโ€™t known
     EVP_MD_CTX temp_ctx;
                ^~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:165:16: warning: unused variable โ€˜temp_ctxโ€™ [-Wunused-variable]
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c: In function โ€˜EVP_hexdigestโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:185:16: error: storage size of โ€˜temp_ctxโ€™ isnโ€™t known
     EVP_MD_CTX temp_ctx;
                ^~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:185:16: warning: unused variable โ€˜temp_ctxโ€™ [-Wunused-variable]
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c: In function โ€˜PKCS5_PBKDF2_HMAC_fastโ€™:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:521:14: error: storage size of โ€˜hctx_tplโ€™ isnโ€™t known
     HMAC_CTX hctx_tpl, hctx;
              ^~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:521:24: error: storage size of โ€˜hctxโ€™ isnโ€™t known
     HMAC_CTX hctx_tpl, hctx;
                        ^~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:527:5: warning: implicit declaration of function โ€˜HMAC_CTX_initโ€™; did you mean โ€˜HMAC_CTX_newโ€™? [-Wimplicit-function-declaration]
     HMAC_CTX_init(&hctx_tpl);
     ^~~~~~~~~~~~~
     HMAC_CTX_new
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:532:9: warning: implicit declaration of function โ€˜HMAC_CTX_cleanupโ€™; did you mean โ€˜HMAC_CTX_get_mdโ€™? [-Wimplicit-function-declaration]
         HMAC_CTX_cleanup(&hctx_tpl);
         ^~~~~~~~~~~~~~~~
         HMAC_CTX_get_md
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:521:24: warning: unused variable โ€˜hctxโ€™ [-Wunused-variable]
     HMAC_CTX hctx_tpl, hctx;
                        ^~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:521:14: warning: unused variable โ€˜hctx_tplโ€™ [-Wunused-variable]
     HMAC_CTX hctx_tpl, hctx;
              ^~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c: At top level:
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:73:23: error: storage size of โ€˜CONST_new_md5_ctxโ€™ isnโ€™t known
     static EVP_MD_CTX CONST_new_ ## Name ## _ctx; \
                       ^
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:76:1: note: in expansion of macro โ€˜DEFINE_CONSTS_FOR_NEWโ€™
 DEFINE_CONSTS_FOR_NEW(md5)
 ^~~~~~~~~~~~~~~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:73:23: error: storage size of โ€˜CONST_new_sha1_ctxโ€™ isnโ€™t known
     static EVP_MD_CTX CONST_new_ ## Name ## _ctx; \
                       ^
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:77:1: note: in expansion of macro โ€˜DEFINE_CONSTS_FOR_NEWโ€™
 DEFINE_CONSTS_FOR_NEW(sha1)
 ^~~~~~~~~~~~~~~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:73:23: error: storage size of โ€˜CONST_new_sha224_ctxโ€™ isnโ€™t known
     static EVP_MD_CTX CONST_new_ ## Name ## _ctx; \
                       ^
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:79:1: note: in expansion of macro โ€˜DEFINE_CONSTS_FOR_NEWโ€™
 DEFINE_CONSTS_FOR_NEW(sha224)
 ^~~~~~~~~~~~~~~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:73:23: error: storage size of โ€˜CONST_new_sha256_ctxโ€™ isnโ€™t known
     static EVP_MD_CTX CONST_new_ ## Name ## _ctx; \
                       ^
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:80:1: note: in expansion of macro โ€˜DEFINE_CONSTS_FOR_NEWโ€™
 DEFINE_CONSTS_FOR_NEW(sha256)
 ^~~~~~~~~~~~~~~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:73:23: error: storage size of โ€˜CONST_new_sha384_ctxโ€™ isnโ€™t known
     static EVP_MD_CTX CONST_new_ ## Name ## _ctx; \
                       ^
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:81:1: note: in expansion of macro โ€˜DEFINE_CONSTS_FOR_NEWโ€™
 DEFINE_CONSTS_FOR_NEW(sha384)
 ^~~~~~~~~~~~~~~~~~~~~
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:73:23: error: storage size of โ€˜CONST_new_sha512_ctxโ€™ isnโ€™t known
     static EVP_MD_CTX CONST_new_ ## Name ## _ctx; \
                       ^
/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/Modules/_hashopenssl.c:82:1: note: in expansion of macro โ€˜DEFINE_CONSTS_FOR_NEWโ€™
 DEFINE_CONSTS_FOR_NEW(sha512)
 ^~~~~~~~~~~~~~~~~~~~~

Python build finished, but the necessary bits to build these modules were not found:
_bsddb             _sqlite3           _tkinter        
bsddb185           bz2                dbm             
dl                 gdbm               imageop         
readline           sunaudiodev                        
To find the necessary bits, look in setup.py in detect_modules() for the module's name.


Failed to build these modules:
_hashlib           _ssl                               

Makefile:518: recipe for target 'sharedmods' failed
make[2]: *** [sharedmods] Error 1
make[2]: Leaving directory '/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11'
package/pkg-generic.mk:195: recipe for target '/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/.stamp_built' failed
make[1]: *** [/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/build/host-python-2.7.11/.stamp_built] Error 2
make[1]: Leaving directory '/home/spaceboyross/TheBlueSystem/freedom-u-sdk/buildroot'
Makefile:105: recipe for target '/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/images/rootfs.ext4' failed
make: *** [/home/spaceboyross/TheBlueSystem/freedom-u-sdk/work/buildroot_rootfs/images/rootfs.ext4] Error 2

gdb can not work on breakpoints.

Hi All,

  1. Use qemu to simulate riscv, and it works OK.
    qemu-system-riscv64 -nographic -machine virt -kernel bbl -drive file=rootfs.bin,format=raw,id=hd0 -device virtio-blk-device,drive=hd0 -netdev user,id=net0 -device virtio-net-device,netdev=net0 -S -gdb tcp::12345
  2. Use gdb to connect to it
    riscv64-unknown-linux-gnu-gdb
    target remote 127.0.0.1:12345
    symbol-file vmlinux
  3. But, when I add breakpoints, it can not beak at it and also print "Register 3921 is not available".
    (gdb) b start_kernel
    Register 3921 is not available

BR,
Peng

U-boot support?

Hi Does sifive have a plan to port uboot for freedom u540 or riscv-qemu ?

AndesTech summit thier patch for their n{x}25 cpus. U-boot link

Thanks.

PK in the 'new' branch is failing compilation

Trying to rebuild riscv-pk 'new' branch for running the vmlinux image in spike. Since the last few updates of the repository had been giving an error as indicated in the commit note, checked out the last working commit reported in git with the checksum as f08c82a.

This checkout version is also giving a compilation error as below:

$ git status
HEAD detached at f08c82a
$ build_project riscv-pk --prefix=$RISCV --host=riscv64-unknown-linux-gnu
Building project riscv-pk
./libmachine.a(mtrap.o): In function mcall_console_putchar.part.0': mtrap.c:(.text+0x8): undefined reference to platform__use_htif'
./libmachine.a(mtrap.o): In function .L0 ': mtrap.c:(.text+0x10a): undefined reference to platform__use_htif'
./libmachine.a(mtrap.o): In function .L36': mtrap.c:(.text+0x2f0): undefined reference to platform__use_htif'
collect2: error: ld returned 1 exit status

Is this a known issue? Kindly advice resolution.

RISCV-PK Non-CISA build

The architecture field (-march) in the configure script of riscv-pk is hardcoded to build only with rv64imafdc support. The global Makefile has already been modified to take care of both ISA and CISA support but this configure script also should be parametrized to build as per global Makefile -march parameter.

The relevant portion of the code in freedom-u-sdk/riscv-pk/configure script (Line #4084) is as follows:

case "${BUILD_32BIT}" in
yes|default)
echo "Building 32-bit pk"
CFLAGS="$default_CFLAGS -march=rv32imafdc -mabi=ilp32d"
LDFLAGS="-march=rv32imafdc -mabi=ilp32d"
install_subdir="riscv32-unknown-elf"
;;
*)
CFLAGS="$default_CFLAGS -march=rv64imafdc -mabi=lp64d"
LDFLAGS="-march=rv64imafdc -mabi=lp64d"
install_subdir="riscv64-unknown-elf"
;;
esac

linux failed to bringup on vc707 board

Hello,

I try to use tag: hifiveu-1.0-2018-03-20 (commit id: 0f03e51) to bring up linux on vc707 board.
My freedom sources are up to date (commit id: 397c395).

However, my terminal hangs as you can see in my terminal log below.
It seems that in both spi-sifive and serial-sifive, they require clock inputs from rocket-chip generated device tree but the clocks are not there. Has anyone encountered this issue before? How can I resolve this issue?

Here is terminal log I got:
INIT
CMD0
CMD8
ACMD41
CMD58
CMD16
CMD18
LOADING
BOOT
bbl loader

            SIFIVE, INC.

     5555555555555555555555555
    5555                   5555
   5555                     5555
  5555                       5555
 5555       5555555555555555555555
5555       555555555555555555555555

5555 5555
5555 5555
5555 5555
5555555555555555555555555555 55555
55555 555555555 55555
55555 55555 55555
55555 5 55555
55555 55555
55555 55555
55555 55555
55555 55555
55555 55555
555555555
55555
5

       SiFive RISC-V Coreplex

[ 0.000000] OF: fdt: Ignoring memory range 0x80000000 - 0x80200000
[ 0.000000] Linux version 4.15.0-00044-g2b0aa1d (shawn@shawn-VirtualBox) (gcc version 7.2.0 (GCC)) #1 SMP Thu Jun 28 18:13:44 PDT 2018
[ 0.000000] bootconsole [early0] enabled
[ 0.000000] Initial ramdisk at: 0x (ptrval) (9436160 bytes)
[ 0.000000] Zone ranges:
[ 0.000000] DMA32 [mem 0x0000000080200000-0x00000000bfffffff]
[ 0.000000] Normal [mem 0x00000000c0000000-0x00000bffffffffff]
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x0000000080200000-0x00000000bfffffff]
[ 0.000000] Initmem setup node 0 [mem 0x0000000080200000-0x00000000bfffffff]
[ 0.000000] software IO TLB [mem 0xbb1fd000-0xbf1fd000] (64MB) mapped at [ (ptrval)- (ptrval)]
[ 0.000000] elf_hwcap is 0x112d
[ 0.000000] percpu: Embedded 14 pages/cpu @ (ptrval) s28632 r0 d28712 u57344
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 258055
[ 0.000000] Kernel command line:
[ 0.000000] Dentry cache hash table entries: 131072 (order: 8, 1048576 bytes)
[ 0.000000] Inode-cache hash table entries: 65536 (order: 7, 524288 bytes)
[ 0.000000] Sorting __ex_table...
[ 0.000000] Memory: 950368K/1046528K available (3055K kernel code, 212K rwdata, 832K rodata, 9371K init, 775K bss, 96160K reserved, 0K cma-reserved)
[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[ 0.000000] Hierarchical RCU implementation.
[ 0.000000] RCU event tracing is enabled.
[ 0.000000] RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
[ 0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
[ 0.000000] NR_IRQS: 0, nr_irqs: 0, preallocated irqs: 0
[ 0.000000] riscv,cpu_intc,0: 64 local interrupts mapped
[ 0.000000] riscv,plic0,c000000: mapped 7 interrupts to 1/2 handlers
[ 0.000000] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x1d854df40, max_idle_ns: 3526361616960 ns
[ 0.000127] sched_clock: 64 bits at 1000kHz, resolution 1000ns, wraps every 2199023255500ns
[ 0.009031] Calibrating delay loop (skipped), value calculated using timer frequency.. 2.00 BogoMIPS (lpj=10000)
[ 0.019100] pid_max: default: 32768 minimum: 301
[ 0.025908] Mount-cache hash table entries: 2048 (order: 2, 16384 bytes)
[ 0.032878] Mountpoint-cache hash table entries: 2048 (order: 2, 16384 bytes)
[ 0.062473] Hierarchical SRCU implementation.
[ 0.077576] smp: Bringing up secondary CPUs ...
[ 0.081578] smp: Brought up 1 node, 1 CPU
[ 0.093534] devtmpfs: initialized
[ 0.115748] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[ 0.125610] futex hash table entries: 256 (order: 2, 16384 bytes)
[ 0.139039] random: get_random_u32 called from bucket_table_alloc+0xe6/0x276 with crng_init=0
[ 0.150190] NET: Registered protocol family 16
[ 0.265926] vgaarb: loaded
[ 0.273426] SCSI subsystem initialized
[ 0.284123] usbcore: registered new interface driver usbfs
[ 0.289795] usbcore: registered new interface driver hub
[ 0.295873] usbcore: registered new device driver usb
[ 0.301893] pps_core: LinuxPPS API ver. 1 registered
[ 0.306672] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti [email protected]
[ 0.315866] PTP clock support registered
[ 0.330469] clocksource: Switched to clocksource riscv_clocksource
[ 0.360712] NET: Registered protocol family 2
[ 0.375614] TCP established hash table entries: 8192 (order: 4, 65536 bytes)
[ 0.386077] TCP bind hash table entries: 8192 (order: 5, 131072 bytes)
[ 0.397154] TCP: Hash tables configured (established 8192 bind 8192)
[ 0.407362] UDP hash table entries: 512 (order: 2, 16384 bytes)
[ 0.413955] UDP-Lite hash table entries: 512 (order: 2, 16384 bytes)
[ 0.423733] NET: Registered protocol family 1
[ 1.883937] Unpacking initramfs...
[ 3.462752] Initialise system trusted keyrings
[ 3.468762] workingset: timestamp_bits=62 max_order=18 bucket_order=0
[ 3.615513] random: fast init done
[ 3.678553] Key type asymmetric registered
[ 3.682829] Asymmetric key parser 'x509' registered
[ 3.687341] io scheduler noop registered
[ 3.695994] io scheduler cfq registered (default)
[ 3.700701] io scheduler mq-deadline registered
[ 3.704670] io scheduler kyber registered
[ 3.724190] sifive_gpio 64002000.gpio: SiFive GPIO chip registered 4 GPIOs
[ 3.743100] xilinx-pcie 2000000000.pci: PCIe Link is UP
[ 3.747976] OF: PCI: host bridge /soc/pci@2000000000 ranges:
[ 3.753931] OF: PCI: No bus range found for /soc/pci@2000000000, using [bus 00-ff]
[ 3.761705] OF: PCI: MEM 0x40000000..0x5fffffff -> 0x40000000
[ 3.769263] xilinx-pcie 2000000000.pci: PCI host bridge to bus 0000:00
[ 3.775744] pci_bus 0000:00: root bus resource [bus 00-ff]
[ 3.781126] pci_bus 0000:00: root bus resource [mem 0x40000000-0x5fffffff]
[ 3.788637] pci 0000:00:00.0: enabling Extended Tags
[ 3.796827] pci 0000:00:00.0: bridge configuration invalid ([bus 00-00]), reconfiguring
[ 3.813347] pci 0000:00:00.0: BAR 8: assigned [mem 0x40000000-0x400fffff]
[ 3.820067] pci 0000:00:00.0: BAR 7: no space for [io size 0x1000]
[ 3.825918] pci 0000:00:00.0: BAR 7: failed to assign [io size 0x1000]
[ 3.832972] pci 0000:01:00.0: BAR 1: assigned [mem 0x40000000-0x4007ffff]
[ 3.839414] pci 0000:01:00.0: BAR 6: assigned [mem 0x40080000-0x400bffff pref]
[ 3.846911] pci 0000:01:00.0: BAR 0: assigned [mem 0x400c0000-0x400dffff]
[ 3.853696] pci 0000:01:00.0: BAR 3: assigned [mem 0x400e0000-0x400e3fff]
[ 3.860453] pci 0000:01:00.0: BAR 2: no space for [io size 0x0020]
[ 3.866369] pci 0000:01:00.0: BAR 2: failed to assign [io size 0x0020]
[ 3.873293] pci 0000:00:00.0: PCI bridge to [bus 01]
[ 3.877996] pci 0000:00:00.0: bridge window [mem 0x40000000-0x400fffff]
[ 4.944327] sifive-serial 64000000.serial: unable to find controller clock
[ 4.951349] sifive-serial: probe of 64000000.serial failed with error -2
[ 4.972274] sifive_spi 64001000.spi: Unable to find bus clock
[ 4.977800] sifive_spi: probe of 64001000.spi failed with error -2
[ 4.987075] libphy: Fixed MDIO Bus: probed
[ 4.995099] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 5.001463] ehci-pci: EHCI PCI platform driver
[ 5.007743] usbcore: registered new interface driver usb-storage
[ 5.022082] usbcore: registered new interface driver usbhid
[ 5.027072] usbhid: USB HID core driver
[ 5.036411] NET: Registered protocol family 17
[ 5.049572] bootconsole [early0] uses init memory and must be disabled even before the real one is ready
[ 5.058887] bootconsole [early0] disabled

"make all" Failure

Hi,
I am getting following compilation error after a git update.
Any suggestions?

In file included from /home/atish/freedom-u-sdk/toolchain/sysroot/usr/include/features.h:447:0,
                 from /home/atish/freedom-u-sdk/toolchain/sysroot/usr/include/bits/libc-header-start.h:33,
                 from /home/atish/freedom-u-sdk/toolchain/sysroot/usr/include/stdint.h:26,
                 from /home/atish/freedom-u-sdk/toolchain/lib/gcc/riscv64-unknown-linux-gnu/7.2.0/include/stdint.h:9,
                 from /home/atish/freedom-u-sdk/riscv-pk/softfloat/f32_to_i64.c:3:
/home/atish/freedom-u-sdk/toolchain/sysroot/usr/include/gnu/stubs.h:17:11: fatal error: gnu/stubs-lp64.h: No such file or directory
 # include <gnu/stubs-lp64.h>
           ^~~~~~~~~~~~~~~~~~
compilation terminated.
Makefile:320: recipe for target 'f32_to_i64_r_minMag.o' failed
make[1]: *** [f32_to_i64_r_minMag.o] Error 1
Makefile:320: recipe for target 'f32_sqrt.o' failed
make[1]: *** [f32_sqrt.o] Error 1
Makefile:320: recipe for target 'f32_to_i64.o' failed
make[1]: *** [f32_to_i64.o] Error 1
In file included from /home/atish/freedom-u-sdk/toolchain/sysroot/usr/include/features.h:447:0,
                 from /home/atish/freedom-u-sdk/toolchain/sysroot/usr/include/bits/libc-header-start.h:33,
                 from /home/atish/freedom-u-sdk/toolchain/sysroot/usr/include/stdint.h:26,
                 from /home/atish/freedom-u-sdk/toolchain/lib/gcc/riscv64-unknown-linux-gnu/7.2.0/include/stdint.h:9,
                 from /home/atish/freedom-u-sdk/riscv-pk/softfloat/f32_to_i32.c:3:
/home/atish/freedom-u-sdk/toolchain/sysroot/usr/include/gnu/stubs.h:17:11: fatal error: gnu/stubs-lp64.h: No such file or directory

Linux boot stuck up (bootconsole [early0] disabled)

After executing the command "make sim", Linux started booting and stuck up by showing the following lines.

[ 0.130295] io scheduler noop registered
[ 0.130855] io scheduler cfq registered (default)
[ 0.131405] io scheduler mq-deadline registered
[ 0.131935] io scheduler kyber registered
[ 0.353880] Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
[ 0.357210] libphy: Fixed MDIO Bus: probed
[ 0.357760] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 0.358520] ehci-pci: EHCI PCI platform driver
[ 0.359080] usbcore: registered new interface driver usb-storage
[ 0.359915] usbcore: registered new interface driver usbhid
[ 0.360565] usbhid: USB HID core driver
[ 0.361185] NET: Registered protocol family 17
[ 0.363445] bootconsole [early0] uses init memory and must be disabled even before the real one is ready
[ 0.364545] bootconsole [early0] disabled

Please some one help to resolve this problem.

Incorrect selection of kernel headers: expected 4.6.x, got 4.1.x

@palmer-dabbelt

The source code has been updated, but it still has the same problem.

According to the guide document, proceed as follows.

  1. git clone --recursive https://github.com/sifive/freedom-u-sdk.git

  2. cd freedom-u-sdk

  3. make
    -> Incorrect selection of kernel headers: expected 4.6.x, got 4.1.x


root@ubuntu:/risc-v/DIR/freedom-u-sdk# git submodule
672f627ce0fe9720b4a193fb9bd583518a990882 buildroot (2016.05-515-g672f627)
160fa8470d0f78b1571c04da8b9af50ac05be378 linux (v4.14-rc7-28-g160fa84)
f683e01542acf60e50774d061bcb396b628e3e67 riscv-fesvr (heads/master)
b4dae89f85bf882852c6186b1284df11065bfcd9 riscv-gnu-toolchain (v20171107)
092b464c06d2eba580b95a3ac7013449cb2687e4 riscv-isa-sim (remotes/origin/dtm_reset_error-33-g092b464)
57740d97cdec928c372d8e752c04a691418cbfa1 riscv-pk (remotes/origin/enable-32bit)

root@ubuntu:/risc-v/DIR/freedom-u-sdk# riscv64-unknown-linux-gnu-gcc --version
riscv64-unknown-linux-gnu-gcc (GCC) 6.1.0
Copyright (C) 2016 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

root@ubuntu:/risc-v/DIR/freedom-u-sdk# riscv64-unknown-elf-gcc --version
riscv64-unknown-elf-gcc (GCC) 6.1.0
Copyright (C) 2016 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Note: #6

failed to boot because of the large image size

Hi guys,
I can boot the Linux use the freedom-u-sdk(commit# af61d6d) on U500 (VC707 FPGA board).
However, when I am adding a simple test program, like helloworld in the ramdisk, it will hang after printing the "SiFive RISC-V Core IP" logo.
I checked that the compiled helloworld occupies 4MB (since I add -static flag during compilation). And the size of bbl.bin becomes from 16M to 20MB.
I have tried to add a simple hello.c file in the ramdisk, and it succeeds.

It seems the bbl has some requirement about the image size?
Any advices to solve this issue?

buildroot compilation fails with glibc-2.28

I'm building the freedom-u-sdk on Arch Linux, which ships with glibc-2.28. Compilation breaks while building buildroot:

/usr/bin/gcc  -I.   -I/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/host/usr/include  -O2 -I/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/host/usr/include -c -o fflush.o fflush.c
/usr/bin/gcc  -I.   -I/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/host/usr/include  -O2 -I/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/host/usr/include -c -o fpurge.o fpurge.c
/usr/bin/gcc  -I.   -I/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/host/usr/include  -O2 -I/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/host/usr/include -c -o freadahead.o freadahead.c
/usr/bin/gcc  -I.   -I/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/host/usr/include  -O2 -I/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/host/usr/include -c -o fseek.o fseek.c
/usr/bin/gcc  -I.   -I/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/host/usr/include  -O2 -I/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/host/usr/include -c -o fseeko.o fseeko.c
freadahead.c: In function 'freadahead':
freadahead.c:91:3: error: #error "Please port gnulib freadahead.c to your platform! Look at the definition of fflush, fread, ungetc on your system, then report this to bug-gnulib."
  #error "Please port gnulib freadahead.c to your platform! Look at the definition of fflush, fread, ungetc on your system, then report this to bug-gnulib."
   ^~~~~
make[5]: *** [Makefile:1842: freadahead.o] Error 1
make[5]: *** Waiting for unfinished jobs....
fseeko.c: In function 'rpl_fseeko':
fseeko.c:109:4: error: #error "Please port gnulib fseeko.c to your platform! Look at the code in fseeko.c, then report this to bug-gnulib."
   #error "Please port gnulib fseeko.c to your platform! Look at the code in fseeko.c, then report this to bug-gnulib."
    ^~~~~
make[5]: *** [Makefile:1842: fseeko.o] Error 1
make[5]: Leaving directory '/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/build/host-m4-1.4.17/lib'
make[4]: *** [Makefile:1602: all] Error 2
make[4]: Leaving directory '/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/build/host-m4-1.4.17/lib'
make[3]: *** [Makefile:1506: all-recursive] Error 1
make[3]: Leaving directory '/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/build/host-m4-1.4.17'
make[2]: *** [Makefile:1461: all] Error 2
make[2]: Leaving directory '/home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/build/host-m4-1.4.17'
make[1]: *** [package/pkg-generic.mk:198: /home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/build/host-m4-1.4.17/.stamp_built] Error 2
make[1]: Leaving directory '/home/anthony/riscv/freedom-u-sdk/buildroot'
make: *** [Makefile:91: /home/anthony/riscv/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar] Error 2

This is a known problem for buildroot; it stems from having to build m4, which in turn has an old version of gnulib. I believe the buildroot folks patched this in a more recent version -- see here.

It also affects bison, as described here.

The easiest solution problem involves upgrading the buildroot version shipped with the SDK; once I've got the current version working (by applying the patches), I'll try to spend some time seeing how tricky upgrading buildroot would be.

Compilation issue with 'make qemu'

I'm trying to build the qemu model with freedom sdk but I'm getting this error at the end:

libtirpc 1.0.1 Autoreconfiguring
libtoolize: putting auxiliary files in '.'.
libtoolize: copying file './ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
libtoolize: copying file 'm4/libtool.m4'
libtoolize: copying file 'm4/ltoptions.m4'
libtoolize: copying file 'm4/ltsugar.m4'
libtoolize: copying file 'm4/ltversion.m4'
libtoolize: copying file 'm4/lt~obsolete.m4'
Unescaped left brace in regex is illegal here in regex; marked by <-- HERE in m/${ <-- HERE ([^ \t=:+{}]+)}/ at /home/users/amaier/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/automake line 3936.
autoreconf: /home/users/amaier/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/automake failed with exit status: 255
package/pkg-generic.mk:185: recipe for target '/home/users/amaier/freedom-u-sdk/work/buildroot_initramfs/build/libtirpc-1.0.1/.stamp_configured' failed
make[1]: *** [/home/users/amaier/freedom-u-sdk/work/buildroot_initramfs/build/libtirpc-1.0.1/.stamp_configured] Error 1
make[1]: Leaving directory '/home/users/amaier/freedom-u-sdk/buildroot'
Makefile:90: recipe for target '/home/users/amaier/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar' failed
make: *** [/home/users/amaier/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar] Error 2

CONFIG_CMDLINE arguments not being passed to spike anymore?

Hi All

A clean 'make -j 32 sim' of freedom-u-sdk at 1dfb584 does not seem to pass CONFIG_CMDLINE arguments into spike anymore?

sbates@hades:~/freedom-u-sdk-2$ make -j 32 sim
/home/users/sbates/freedom-u-sdk-2/work/riscv-isa-sim/prefix/bin/spike --isa=rv64imafdc -p4 /home/users/sbates/freedom-u-sdk-2/work/riscv-pk/bbl
bbl loader


[ 0.000000] Kernel command line:

Changing things on CONFIG_CMDLINE in conf/linux_defconfig seems to cause a recompile of the bbl but no change to that line in the console and no impact on the booting kernel.

Stephen

PS The CONFIG_CMDLINE changes DO appear in the console in a QEMU boot and DO impact that kernel in that emulator.

Linux headers need to be updated in build process?

When I run a "make all" after updating the submodules, the script crashes with an

"Incorrect selection of kernel headers: expected 4.6.x, got 4.13.x
package/pkg-generic.mk:185: recipe for target '../freedom-u-sdk/work/buildroot_initramfs/build/toolchain-external-undefined/.stamp_configured' failed
make[1]: *** [../freedom-u-sdk/work/buildroot_initramfs/build/toolchain-external-undefined/.stamp_configured] Error 1
make[1]: Leaving directory '../freedom-u-sdk/buildroot'
Makefile:80: recipe for target '../freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar' failed
make: *** [../freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar] Error 2"

Any ideas?

Thank you!

error in linux booting for riscv

i am executing spike bbl vmlinux this command but got error like bootconsole [early0] disabled

give me solution for these.

root@priyanka-Veriton-M6650G:/home/priyanka/RISCV1/riscv-tools/riscv-pk/build# spike bbl vmlinux
OF: fdt: Ignoring memory range 0x80000000 - 0x80200000
Linux version 4.19.0-29675-g9d93e87 (priyanka@priyanka-Veriton-M6650G) (gcc version 7.2.0 (GCC)) #5 SMP Mon Nov 19 11:24:15 IST 2018
bootconsole [early0] enabled
initrd not found or empty - disabling initrd
Zone ranges:
DMA32 [mem 0x0000000080200000-0x00000000ffffffff]
Normal [mem 0x0000000100000000-0x00000fffffffffff]
Movable zone start for each node
Early memory node ranges
node 0: [mem 0x0000000080200000-0x00000000ffffffff]
Initmem setup node 0 [mem 0x0000000080200000-0x00000000ffffffff]
software IO TLB: mapped [mem 0xfa3fe000-0xfe3fe000] (64MB)
elf_hwcap is 0x112d
percpu: Embedded 17 pages/cpu @(ptrval) s29912 r8192 d31528 u69632
Built 1 zonelists, mobility grouping on. Total pages: 516615
Kernel command line:
Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes)
Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes)
Sorting __ex_table...
Memory: 1971260K/2095104K available (5453K kernel code, 329K rwdata, 1745K rodata, 17709K init, 807K bss, 123844K reserved, 0K cma-reserved)
SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
rcu: Hierarchical RCU implementation.
rcu: RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
rcu: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
NR_IRQS: 0, nr_irqs: 0, preallocated irqs: 0
clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
Console: colour dummy device 80x25
console [tty0] enabled
bootconsole [early0] disabled

No longer possible to check out the version that works with QEMU master

I know this isn't the intended use of this repository but the recent rebasing on sifive/riscv-linux make git submodule update fail for sifive/freedom-u-sdk@5d38ed:

fatal: reference is not a tree: 3989911d0071b93d2e529d22007b7ec783a57532
Unable to checkout '3989911d0071b93d2e529d22007b7ec783a57532' in submodule path 'linux'

(5d38ed is the last priv-1.9 freedom-u-sdk; the current rev is priv-1.9.1, which is not supported by qemu.)

Incorrect selection of kernel headers: expected 4.6.x, got 4.13.x

Trying to build a fresh checkout of freedom-u-sdk using make qemu.

$ git branch -v
* master 783c89a linux_defconfig: support software restart

QEMU builds okay, but then I get an error with buildroot. I've done git submodule update --init --recursive and everything is up-to-date.

$ make qemu
rm -rf /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/
mkdir -p /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/
cp /home/mclark/src/sifive/freedom-u-sdk/conf/buildroot_initramfs_config /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/.config
make -C /home/mclark/src/sifive/freedom-u-sdk/buildroot RISCV=/opt/riscv/toolchain PATH=/opt/riscv/toolchain/bin:/home/mclark/bin:/home/mclark/.local/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games:/opt/riscv/toolchain/bin:/opt/riscv/qemu/bin:/opt/riscv/musl-riscv-toolchain-7.2.0-7/bin O=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs olddefconfig
make[1]: Entering directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
mkdir -p /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/lxdialog
PKG_CONFIG_PATH="" make CC="/usr/bin/gcc" HOSTCC="/usr/bin/gcc" \
    obj=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config -C support/kconfig -f Makefile.br conf
make[2]: Entering directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot/support/kconfig'
/usr/bin/gcc -D_GNU_SOURCE -D_DEFAULT_SOURCE -DCURSES_LOC="<ncurses.h>" -DLOCALE  -I/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config -DCONFIG_=\"\"  -MM *.c > /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/.depend 2>/dev/null || :
/usr/bin/gcc -D_GNU_SOURCE -D_DEFAULT_SOURCE -DCURSES_LOC="<ncurses.h>" -DLOCALE  -I/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config -DCONFIG_=\"\"   -c conf.c -o /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/conf.o
/usr/bin/gcc -D_GNU_SOURCE -D_DEFAULT_SOURCE -DCURSES_LOC="<ncurses.h>" -DLOCALE  -I/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config -DCONFIG_=\"\"  -I. -c /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/zconf.tab.c -o /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/zconf.tab.o
/usr/bin/gcc -D_GNU_SOURCE -D_DEFAULT_SOURCE -DCURSES_LOC="<ncurses.h>" -DLOCALE  -I/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config -DCONFIG_=\"\"   /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/conf.o /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/zconf.tab.o  -o /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/conf
rm /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/zconf.tab.c
make[2]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot/support/kconfig'
  GEN     /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/Makefile
BR2_DEFCONFIG='' KCONFIG_AUTOCONFIG=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/auto.conf KCONFIG_AUTOHEADER=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/autoconf.h KCONFIG_TRISTATE=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/tristate.config BR2_CONFIG=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/.config BR2_EXTERNAL=support/dummy-external HOST_GCC_VERSION="6" SKIP_LEGACY= /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/conf --olddefconfig Config.in
#
# configuration written to /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/.config
#
make[1]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
make -C /home/mclark/src/sifive/freedom-u-sdk/buildroot RISCV=/opt/riscv/toolchain PATH=/opt/riscv/toolchain/bin:/home/mclark/bin:/home/mclark/.local/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games:/opt/riscv/toolchain/bin:/opt/riscv/qemu/bin:/opt/riscv/musl-riscv-toolchain-7.2.0-7/bin O=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs
make[1]: Entering directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
/usr/bin/make -j1 O=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs HOSTCC="/usr/bin/gcc" HOSTCXX="/usr/bin/g++" silentoldconfig
make[2]: Entering directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
  GEN     /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/Makefile
BR2_DEFCONFIG='' KCONFIG_AUTOCONFIG=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/auto.conf KCONFIG_AUTOHEADER=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/autoconf.h KCONFIG_TRISTATE=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/tristate.config BR2_CONFIG=/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/.config BR2_EXTERNAL=support/dummy-external HOST_GCC_VERSION="6" SKIP_LEGACY= /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/buildroot-config/conf --silentoldconfig Config.in
make[2]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
>>> host-mkpasswd buildroot-2016.08-git Extracting
>>> host-mkpasswd buildroot-2016.08-git Patching
>>> host-mkpasswd buildroot-2016.08-git Configuring
>>> host-mkpasswd buildroot-2016.08-git Building
/usr/bin/gcc -O2 -I/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/include -L/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/lib -L/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/lib -Wl,-rpath,/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/lib package/mkpasswd/mkpasswd.c package/mkpasswd/utils.c -o /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-mkpasswd-buildroot-2016.08-git/mkpasswd -lcrypt
In file included from /usr/include/stdio.h:27:0,
                 from package/mkpasswd/mkpasswd.c:24:
/usr/include/features.h:148:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
 # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
   ^~~~~~~
>>> host-mkpasswd buildroot-2016.08-git Installing to host directory
/usr/bin/install -D -m 755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/host-mkpasswd-buildroot-2016.08-git/mkpasswd /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/bin/mkpasswd
>>> skeleton undefined Extracting
>>> skeleton undefined Patching
>>> skeleton undefined Configuring
>>> skeleton undefined Building
>>> skeleton undefined Installing to staging directory
/usr/bin/install -d -m 0755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/riscv64-buildroot-linux-gnu/sysroot/usr/lib
/usr/bin/install -d -m 0755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/riscv64-buildroot-linux-gnu/sysroot/usr/bin
/usr/bin/install -d -m 0755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/riscv64-buildroot-linux-gnu/sysroot/usr/sbin
/usr/bin/install -d -m 0755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/riscv64-buildroot-linux-gnu/sysroot/usr/include
/usr/bin/install -d -m 0755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/riscv64-buildroot-linux-gnu/sysroot/bin
/usr/bin/install -d -m 0755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/riscv64-buildroot-linux-gnu/sysroot/sbin
/usr/bin/install -d -m 0755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/riscv64-buildroot-linux-gnu/sysroot/lib
ln -snf lib /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/riscv64-buildroot-linux-gnu/sysroot/lib64
ln -snf lib /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/host/usr/riscv64-buildroot-linux-gnu/sysroot/usr/lib64
>>> skeleton undefined Fixing libtool files
>>> skeleton undefined Installing to target
rsync -a --ignore-times --exclude .svn --exclude .git --exclude .hg --exclude .bzr --exclude CVS --chmod=u=rwX,go=rX --exclude .empty --exclude '*~' system/skeleton/ /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/target/
/usr/bin/install -d -m 0755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/target/bin
/usr/bin/install -d -m 0755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/target/sbin
/usr/bin/install -d -m 0755 /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/target/lib
ln -snf lib /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/target/lib64
ln -snf lib /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/target/usr/lib64
/usr/bin/install -m 0644 support/misc/target-dir-warning.txt /home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/target/THIS_IS_NOT_YOUR_ROOT_FILESYSTEM
>>> toolchain-external undefined Extracting
>>> toolchain-external undefined Patching
>>> toolchain-external undefined Configuring
Incorrect selection of kernel headers: expected 4.6.x, got 4.13.x
package/pkg-generic.mk:185: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/toolchain-external-undefined/.stamp_configured' failed
make[1]: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/build/toolchain-external-undefined/.stamp_configured] Error 1
make[1]: Leaving directory '/home/mclark/src/sifive/freedom-u-sdk/buildroot'
Makefile:87: recipe for target '/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar' failed
make: *** [/home/mclark/src/sifive/freedom-u-sdk/work/buildroot_initramfs/images/rootfs.tar] Error 2

make linux kernel is failing

If we do make CROSS_COMPILE=riscv64-unknown-linux-gnu- ARCH=riscv vmlinux

it is failing with the error message

CC drivers/tty/serial/earlycon.o
drivers/tty/serial/earlycon.c:30:10: fatal error: asm/serial.h: No such file or directory
#include <asm/serial.h>
^~~~~~~~~~~~~~
compilation terminated.

This is with EARLY_PRINTK macro enabled in the kernel .config file

Can not SSH to qemu?

Hello All,

I run "make qemu" the linux is boot with U/P=root/sifive.

The IP of qemu is configured by default as below
inet addr:10.0.2.15 Bcast:10.0.2.255 Mask:255.255.255.0

In host, I configure its IP as
inet addr:10.0.2.30 Bcast:10.0.2.255 Mask:255.255.255.0

From the host, I ping the qemu (and vice versa) and all packets are lost. When I do "ssh [email protected]", an error message showed below
ssh: connect to host 10.0.2.15 port 22: No route to host

Do you have any idea to resolve this issue? Many thanks !

/T

No console output after bootconsole disables

I'm having a similar issue to #44 .
I'm trying to run it with Spike.

Here's the console log:

ssr-risc-v@chisel:~/TestEnv/freedom-u-sdk> ./work/riscv-isa-sim/spike -p4 ./work/riscv-pk/bbl
bbl loader

                SIFIVE, INC.

         5555555555555555555555555
        5555                   5555
       5555                     5555
      5555                       5555
     5555       5555555555555555555555
    5555       555555555555555555555555
   5555                             5555
  5555                               5555
 5555                                 5555
5555555555555555555555555555          55555
 55555           555555555           55555
   55555           55555           55555
     55555           5           55555
       55555                   55555
         55555               55555
           55555           55555
             55555       55555
               55555   55555
                 555555555
                   55555
                     5

           SiFive RISC-V Coreplex
[    0.000000] OF: fdt: Ignoring memory range 0x80000000 - 0x80200000
[    0.000000] Linux version 4.15.0-00048-gfe92d7905c6e (ssr-risc-v@chisel) (gcc version 7.2.0 (GCC)) #3 SMP Tue Aug 7 14:15:13 PDT 2018
[    0.000000] bootconsole [early0] enabled
[    0.000000] Initial ramdisk at: 0x        (ptrval) (9436160 bytes)
[    0.000000] Zone ranges:
[    0.000000]   DMA32    [mem 0x0000000080200000-0x00000000ffffffff]
[    0.000000]   Normal   [mem 0x0000000100000000-0x00000fffffffffff]
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000080200000-0x00000000ffffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000080200000-0x00000000ffffffff]
[    0.000000] software IO TLB [mem 0xfa3fd000-0xfe3fd000] (64MB) mapped at [        (ptrval)-        (ptrval)]
[    0.000000] elf_hwcap is 0x112d
[    0.000000] percpu: Embedded 14 pages/cpu @        (ptrval) s28632 r0 d28712 u57344
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 516615
[    0.000000] Kernel command line: 
[    0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes)
[    0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes)
[    0.000000] Sorting __ex_table...
[    0.000000] Memory: 1982868K/2095104K available (3071K kernel code, 217K rwdata, 841K rodata, 9375K init, 777K bss, 112236K reserved, 0K cma-reserved)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000] 	RCU event tracing is enabled.
[    0.000000] 	RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=4.
[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=4
[    0.000000] NR_IRQS: 0, nr_irqs: 0, preallocated irqs: 0
[    0.000000] riscv,cpu_intc,0: 64 local interrupts mapped
[    0.000000] riscv,cpu_intc,1: 64 local interrupts mapped
[    0.000000] riscv,cpu_intc,2: 64 local interrupts mapped
[    0.000000] riscv,cpu_intc,3: 64 local interrupts mapped
[    0.000000] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[    0.000010] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[    0.000995] Calibrating delay loop (skipped), value calculated using timer frequency.. 20.00 BogoMIPS (lpj=100000)
[    0.002200] pid_max: default: 32768 minimum: 301
[    0.002805] Mount-cache hash table entries: 4096 (order: 3, 32768 bytes)
[    0.003590] Mountpoint-cache hash table entries: 4096 (order: 3, 32768 bytes)
[    0.005355] Hierarchical SRCU implementation.
[    0.007430] smp: Bringing up secondary CPUs ...
[    0.008570] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[    0.009880] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[    0.011640] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[    0.012950] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[    0.014690] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[    0.016000] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[    0.017145] smp: Brought up 1 node, 4 CPUs
[    0.018075] devtmpfs: initialized
[    0.019020] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.020160] futex hash table entries: 1024 (order: 4, 65536 bytes)
[    0.021110] random: get_random_u32 called from bucket_table_alloc+0xe6/0x276 with crng_init=0
[    0.022160] NET: Registered protocol family 16
[    0.025460] vgaarb: loaded
[    0.025900] SCSI subsystem initialized
[    0.026635] usbcore: registered new interface driver usbfs
[    0.027285] usbcore: registered new interface driver hub
[    0.028050] usbcore: registered new device driver usb
[    0.028665] pps_core: LinuxPPS API ver. 1 registered
[    0.029245] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <[email protected]>
[    0.030310] PTP clock support registered
[    0.031200] clocksource: Switched to clocksource riscv_clocksource
[    0.033115] NET: Registered protocol family 2
[    0.033905] TCP established hash table entries: 16384 (order: 5, 131072 bytes)
[    0.034945] TCP bind hash table entries: 16384 (order: 6, 262144 bytes)
[    0.035910] TCP: Hash tables configured (established 16384 bind 16384)
[    0.036705] UDP hash table entries: 1024 (order: 3, 32768 bytes)
[    0.037440] UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes)
[    0.038275] NET: Registered protocol family 1
[    0.061995] Unpacking initramfs...
[    0.089100] Initialise system trusted keyrings
[    0.089725] workingset: timestamp_bits=62 max_order=19 bucket_order=0
[    0.094880] random: fast init done
[    0.108685] jitterentropy: Initialization failed with host not compliant with requirements: 2
[    0.109675] Key type asymmetric registered
[    0.110155] Asymmetric key parser 'x509' registered
[    0.110725] io scheduler noop registered
[    0.111400] io scheduler cfq registered (default)
[    0.111950] io scheduler mq-deadline registered
[    0.112480] io scheduler kyber registered
[    0.171355] Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
[    0.173040] libphy: Fixed MDIO Bus: probed
[    0.173590] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    0.174350] ehci-pci: EHCI PCI platform driver
[    0.174910] usbcore: registered new interface driver usb-storage
[    0.175745] usbcore: registered new interface driver usbhid
[    0.176395] usbhid: USB HID core driver
[    0.177010] NET: Registered protocol family 17
[    0.177990] bootconsole [early0] uses init memory and must be disabled even before the real one is ready
[    0.179090] bootconsole [early0] disabled


Build without support of Compress ISA

We are trying to build the tool chain without the support of compression ISA set.

We did the following changes in the different files for this purpose:
a) In the Makefile @ freedom-u-sdk directory, we changed the rule for building bbl as follows:
$(bbl): $(pk_srcdir) $(vmlinux_stripped)
rm -rf $(pk_wrkdir)
mkdir -p $(pk_wrkdir)
cd $(pk_wrkdir) &amp;&amp; $&lt;/configure
--host=$(target)
--with-payload=$(vmlinux_stripped)
--enable-logo
--with-logo=$(abspath conf/sifive_logo.txt)
CFLAGS="-mabi=lp64d -march=rv64imafd" $(MAKE) -C $(pk_wrkdir)

  • Basically, replaced the architecture support of rv64imafdc to rv64imafd in the last line of the rule.

b) In the riscv-pk/configure script, made the change in the CFLAGS and LDFLAGS for a 64-bit architecture as follows:

case "${BUILD_32BIT}" in
yes|default)
echo "Building 32-bit pk"
CFLAGS="$default_CFLAGS -march=rv32imafdc -mabi=ilp32d"
LDFLAGS="-march=rv32imafdc -mabi=ilp32d"
install_subdir="riscv32-unknown-elf"
;;
*)
CFLAGS="$default_CFLAGS -march=rv64imafd -mabi=lp64d"
LDFLAGS="-march=rv64imafd -mabi=lp64d"
install_subdir="riscv64-unknown-elf"
;;
esac

  • Basically, replacing the architecture for the * case above as rv64imafd instead of what was set as rv64imafdc for the architecture in the repository.

After making the above changes in the files, did a 'make clean' and then issued a fresh make and then subsequently make sim. Verified that there was no reference of architecture as rv64imafdc and reference of architecture was only rv64imafd - in the entire make build output - thereby proving that the architecture was never getting set as rv64imafdc through out the entire repository build.

When the bbl has got built and appended with the vmlinux as payload as part of this make, and then spike started this bbl loading, there is an error message that is coming in as part of the load process as below:

       SiFive RISC-V Coreplex

[ 0.000000] OF: fdt: Ignoring memory range 0x80000000 - 0x80200000
[ 0.000000] Linux version 4.14.0-rc7-00028-g160fa84-dirty (admin1@admin) (gcc version 7.2.0 (GCC)) #1 SMP Mon Nov 13 14:19:43 IST 2017
[ 0.000000] bootconsole [early0] enabled
[ 0.000000] Initial ramdisk at: 0xffffffe00001e200 (6598656 bytes)
[ 0.000000] Zone ranges:
[ 0.000000] DMA [mem 0x0000000080200000-0x00000000ffffffff]
[ 0.000000] Normal empty
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x0000000080200000-0x00000000ffffffff]
[ 0.000000] Initmem setup node 0 [mem 0x0000000080200000-0x00000000ffffffff]
[ 0.000000] elf_hwcap is 0x112d
[ 0.000000] percpu: Embedded 14 pages/cpu @ffffffe07e1ee000 s28376 r0 d28968 u57344
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 516615
[ 0.000000] Kernel command line: earlyprintk
[ 0.000000] PID hash table entries: 4096 (order: 3, 32768 bytes)
[ 0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes)
[ 0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes)
[ 0.000000] Sorting __ex_table...
[ 0.000000] Memory: 2052044K/2095104K available (2826K kernel code, 239K rwdata, 758K rodata, 6599K init, 774K bss, 43060K reserved, 0K cma-reserved)
[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[ 0.000000] Hierarchical RCU implementation.
[ 0.000000] RCU event tracing is enabled.
[ 0.000000] RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
[ 0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
[ 0.000000] NR_IRQS: 0, nr_irqs: 0, preallocated irqs: 0
[ 0.000000] riscv,cpu_intc,0: 64 local interrupts mapped
[ 0.000000] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
/home/admin1/Desktop/riscv/new-freedom-u-sdk/freedom-u-sdk/riscv-pk/machine/mtrap.c:18: machine mode: unhandlable trap 4 @ 0x0000000080003434

On the disassembled bbl executable, 80003434 is having:
80003434: 00066703 lwu a4,0(a2) # 1000 <_ftext-0x7ffff000>


For having the support of RV64IMAFD and NOT having the support of RV64IMAFDC ISA, should there be anything else that is done for a successful load up in spike till the login prompt?

Thanks in advance for your inputs and help,

Vasan

Linux doesn't log into ash on Spike

Hello,

I'm trying to boot Linux on Spike with -p4 using make sim
It has booted but doesn't log in to busybox.
Any idea where the problem did come from? I waited a long time but no reaction.

Best regards,
Noureddine

                SIFIVE, INC.

         5555555555555555555555555
        5555                   5555
       5555                     5555
      5555                       5555
     5555       5555555555555555555555
    5555       555555555555555555555555
   5555                             5555
  5555                               5555
 5555                                 5555
5555555555555555555555555555          55555
 55555           555555555           55555
   55555           55555           55555
     55555           5           55555
       55555                   55555
         55555               55555
           55555           55555
             55555       55555
               55555   55555
                 555555555
                   55555
                     5

           SiFive RISC-V Coreplex

[    0.000000] OF: fdt: Ignoring memory range 0x80000000 - 0x80200000
[    0.000000] Linux version 4.15.0-00044-g2b0aa1d (noureddine-as@as) (gcc version 7.2.0 (GCC)) #1 SMP Wed Mar 28 11:21:01 CEST 2018
[    0.000000] bootconsole [early0] enabled
[    0.000000] Initial ramdisk at: 0x        (ptrval) (11025408 bytes)
[    0.000000] Zone ranges:
[    0.000000]   DMA32    [mem 0x0000000080200000-0x00000000ffffffff]
[    0.000000]   Normal   [mem 0x0000000100000000-0x00000fffffffffff]
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000080200000-0x00000000ffffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000080200000-0x00000000ffffffff]
[    0.000000] software IO TLB [mem 0xfa3fd000-0xfe3fd000] (64MB) mapped at [        (ptrval)-        (ptrval)]
[    0.000000] elf_hwcap is 0x1129
[    0.000000] percpu: Embedded 14 pages/cpu @        (ptrval) s28632 r0 d28712 u57344
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 516615
[    0.000000] Kernel command line: 
[    0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes)
[    0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes)
[    0.000000] Sorting __ex_table...
[    0.000000] Memory: 1980032K/2095104K available (4309K kernel code, 219K rwdata, 844K rodata, 10963K init, 780K bss, 115072K reserved, 0K cma-reserved)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000] 	RCU event tracing is enabled.
[    0.000000] 	RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=4.
[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=4
[    0.000000] NR_IRQS: 0, nr_irqs: 0, preallocated irqs: 0
[    0.000000] riscv,cpu_intc,0: 64 local interrupts mapped
[    0.000000] riscv,cpu_intc,1: 64 local interrupts mapped
[    0.000000] riscv,cpu_intc,2: 64 local interrupts mapped
[    0.000000] riscv,cpu_intc,3: 64 local interrupts mapped
[    0.000000] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[    0.000010] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[    0.000995] Calibrating delay loop (skipped), value calculated using timer frequency.. 20.00 BogoMIPS (lpj=100000)
[    0.002200] pid_max: default: 32768 minimum: 301
[    0.002805] Mount-cache hash table entries: 4096 (order: 3, 32768 bytes)
[    0.003590] Mountpoint-cache hash table entries: 4096 (order: 3, 32768 bytes)
[    0.005355] Hierarchical SRCU implementation.
[    0.007430] smp: Bringing up secondary CPUs ...
[    0.008570] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[    0.009880] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[    0.011640] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[    0.012950] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[    0.014690] clocksource: riscv_clocksource: mask: 0xffffffffffffffff max_cycles: 0x24e6a1710, max_idle_ns: 440795202120 ns
[    0.016000] sched_clock: 64 bits at 10MHz, resolution 100ns, wraps every 4398046511100ns
[    0.017145] smp: Brought up 1 node, 4 CPUs
[    0.018075] devtmpfs: initialized
[    0.019020] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.020160] futex hash table entries: 1024 (order: 4, 65536 bytes)
[    0.021110] random: get_random_u32 called from bucket_table_alloc+0x134/0x3c0 with crng_init=0
[    0.022170] NET: Registered protocol family 16
[    0.025470] vgaarb: loaded
[    0.025910] SCSI subsystem initialized
[    0.026645] usbcore: registered new interface driver usbfs
[    0.027295] usbcore: registered new interface driver hub
[    0.028060] usbcore: registered new device driver usb
[    0.028675] pps_core: LinuxPPS API ver. 1 registered
[    0.029255] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <[email protected]>
[    0.030320] PTP clock support registered
[    0.031210] clocksource: Switched to clocksource riscv_clocksource
[    0.033130] NET: Registered protocol family 2
[    0.033920] TCP established hash table entries: 16384 (order: 5, 131072 bytes)
[    0.034960] TCP bind hash table entries: 16384 (order: 6, 262144 bytes)
[    0.035925] TCP: Hash tables configured (established 16384 bind 16384)
[    0.036720] UDP hash table entries: 1024 (order: 3, 32768 bytes)
[    0.037455] UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes)
[    0.038290] NET: Registered protocol family 1
[    0.062985] Unpacking initramfs...
[    0.091610] Initialise system trusted keyrings
[    0.092325] workingset: timestamp_bits=62 max_order=19 bucket_order=0
[    0.097310] random: fast init done
[    0.111115] jitterentropy: Initialization failed with host not compliant with requirements: 2
[    0.112220] Key type asymmetric registered
[    0.112700] Asymmetric key parser 'x509' registered
[    0.113270] io scheduler noop registered
[    0.113830] io scheduler cfq registered (default)
[    0.114380] io scheduler mq-deadline registered
[    0.114910] io scheduler kyber registered
[    0.173790] Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
[    0.175490] libphy: Fixed MDIO Bus: probed
[    0.176045] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    0.176805] ehci-pci: EHCI PCI platform driver
[    0.177360] usbcore: registered new interface driver usb-storage
[    0.178195] usbcore: registered new interface driver usbhid
[    0.178845] usbhid: USB HID core driver
[    0.179455] NET: Registered protocol family 17
[    0.180435] bootconsole [early0] uses init memory and must be disabled even before the real one is ready
[    0.181645] bootconsole [early0] disabled


Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.