Commit Graph

93 Commits

Author SHA1 Message Date
a4cda932d2 Use old method to upload files to FPGA
Using a single dd command fails sometimes.
2024-03-07 12:34:54 +01:00
94eb71dd80 Add rootfs for lagarto hun 2024-03-07 12:05:10 +01:00
eeecd40882 Update lagarto-hun config 2024-03-07 12:04:40 +01:00
0c873307ae Add no compressed specific overlay 2024-03-07 12:04:05 +01:00
4d284ae315 Move qemu specific config to vm.nix 2024-03-07 12:03:02 +01:00
730e342bfe Add scripts to load FPGA system 2024-03-04 18:32:25 +01:00
ef29bb0681 Fix uboot attribute name in lagarto hun 2024-03-04 18:26:48 +01:00
Rodrigo Arias Mallo
cf94b5a46a Update fpgactl usage 2024-03-04 16:53:03 +01:00
Rodrigo Arias Mallo
bd2b8b1bc5 Update fpgactl tool 2024-03-04 16:31:07 +01:00
409d2caecc Add lagarto hun DTS file 2024-03-04 14:46:26 +01:00
7c58298de6 Add notes about kernel config file 2024-03-04 14:45:53 +01:00
023ad3de22 Split kernel configuration in files 2024-03-04 14:44:49 +01:00
0003f07ed4 Add FPGA documentation in readme 2024-03-01 18:43:24 +01:00
12237d6a79 Add fpgactl tool 2024-03-01 18:37:05 +01:00
3b68bfda47 Add Lagarto Hun configuration 2024-03-01 18:33:30 +01:00
eac68c64ec Disable nsncd daemon in no-compressed.nix 2024-03-01 18:31:57 +01:00
5bb469d1a4 Add FPGA OpenSBI and U-Boot 2024-03-01 18:19:59 +01:00
0c2cfbe38d Add comment to make GC root 2024-01-25 15:50:33 +01:00
31ec3245e9 Ignore qcow2 image from git 2024-01-25 15:39:15 +01:00
0d9e494ba6 Include vim in the guest to edit files 2024-01-25 15:38:22 +01:00
960badad9b Enable recommended options in the kernel 2024-01-25 15:37:50 +01:00
9db6d05222 Remove old stdenv hack for the kernel 2024-01-25 15:37:18 +01:00
b7251e7a84 Build OpenSBI and u-boot without vector extension 2024-01-25 15:36:39 +01:00
483ad2944b Format the qcow2 image with ext4
The image needs to be available to the guest with a partition table and
a partition with a label named "nixos" so the stage1 can mount it. By
enabling the virtualisation.diskImage option we now have a persistent
root filesystem, including /home.
2024-01-25 15:34:59 +01:00
6a8eadb037 Add gcc and objdump developer tools 2024-01-24 13:10:09 +01:00
d52db1d97c Correct style type in flake.nix 2024-01-24 13:09:49 +01:00
630b8ac90f Remove old files 2024-01-24 13:09:30 +01:00
9653377ba5 Remove unneeded flake dependencies 2024-01-24 12:53:30 +01:00
5b8a51fb19 Add qemu and qemu-nc NixOS configurations 2024-01-24 12:50:41 +01:00
d3f97dac58 Remove visionfive references 2024-01-24 12:41:57 +01:00
358184f869 flake.lock: Update
Flake lock file updates:

• Updated input 'nixpkgs':
    'github:nixos/nixpkgs/c3e128f3c0ecc1fb04aef9f72b3dcc2f6cecf370' (2024-01-15)
  → 'github:rodarima/nixpkgs/57e7c8fa4fdc414a936ce83afd0c70fb0a3a31d5' (2024-01-24)
2024-01-24 12:21:48 +01:00
8df89867f3 Switch nixpkgs to a custom repository
There is a problem in the way pkgsStatic is constructed, causing our
-march argument to be missed, leading to binaries that fail to run. This
affects only security wrappers so far (mount, sudo, ...) but it will
likely affect any pkgsStatic binary.
2024-01-24 12:20:27 +01:00
c0ecd32173 Remove unneeded override of stdenv
The march and mtune flags are passed by the crossSystem gcc attributes,
which are placed *before* the flags to gcc. This may end up causing some
packages to break, but it is working fine so far.
2024-01-24 10:00:19 +01:00
eff49c6ee3 Disable vector extensions in march and mtune 2024-01-24 09:59:44 +01:00
8ce6523c07 Install neofetch too 2024-01-24 09:58:57 +01:00
befd6e9e17 Enable autologin 2024-01-24 09:58:41 +01:00
4c413864b3 Add gdb and comment about nscd daemon 2024-01-22 16:05:38 +01:00
85eb9c63e3 Move notes out of readme 2024-01-22 13:42:49 +01:00
6de338a178 Remove old u-boot instructions 2024-01-22 13:42:00 +01:00
f8472b79e6 Disable compressed instructions in QEMU 2024-01-22 13:40:51 +01:00
f63408f361 Disable nsncd daemon for now as it fails to load
It is currently causing a trap, but the reason is not clear:

nsncd[1179]: unhandled signal 7 code 0x1 at 0x00ffffff8184e920 in libc.so.6[ffffff81824000+1aa000]
CPU: 3 PID: 1179 Comm: nsncd Not tainted 6.1.72 #1-NixOS
Hardware name: riscv-virtio,qemu (DT)
epc : 00ffffff8184e920 ra : 00ffffff8184e868 sp : 00ffffffef6ab610
 gp : 00aaaaaac0f07db8 tp : 00ffffff81822780 t0 : 00ffffffef6ab1f0
 t1 : 00aaaaaac0e5283c t2 : 0000000000000b56 s0 : 00ffffffef6ab668
 s1 : 0000000000000001 a0 : 0000000000000001 a1 : 00ffffffef6ab668
 a2 : 00ffffffef6ab678 a3 : 00aaaaaac0f06e40 a4 : 0000000100000000
 a5 : 00aaaaaac0eac296 a6 : 00ffffff819d3048 a7 : 00ffffffef6ab8c0
 s2 : 0000000000000000 s3 : 00aaaaaac0efac40 s4 : 00aaaaaac0e6755a
 s5 : 00ffffffef6ab678 s6 : 00aaaaaac0efac48 s7 : 00ffffff81a2fd58
 s8 : 00ffffff81a30030 s9 : 00ffffffd7386ef0 s10: 0000000000000000
 s11: 0000000000000000 t3 : 00ffffff8184e818 t4 : 0000000000000028
 t5 : 00ffffff81a24380 t6 : 00ffffff81a074c8
status: 0000000200004020 badaddr: 00aaaaaac0eac296 cause: 0000000000000000
2024-01-22 13:37:26 +01:00
3707e5708e Disable EFI in the kernel and use normal stdenv
In order to build the kernel without compressed instructions we need to
disable EFI support. We also need to leave the kernel to figure the
proper -march and -mabi flags, as otherwise it fails to build. Using the
option "CONFIG_RISCV_ISA_C n" disables the use of compressed
instructions.
2024-01-22 13:37:00 +01:00
a333210fdc Only change cross stdenv
Prevents mass rebuilds in x86, where the envvar doesn't have any effect.
2024-01-19 17:10:22 +01:00
635935cd09 Build packages without compressed instructions 2024-01-19 16:35:45 +01:00
98d04ee398 Also build u-boot ELF file for debugging 2024-01-19 16:32:40 +01:00
819c7e6e93 Build u-boot and the kernel without compressed 2024-01-19 16:31:53 +01:00
1acf425974 Add notes about compressed instructions 2024-01-19 16:27:58 +01:00
1fda5d7710 Set the bootcmd in u-boot
In QEMU the kernel is loaded at the ${kernel_addr_r} address and we need
to use booti instead of bootm.
2024-01-19 14:29:23 +01:00
bd80b0fefb Add default user and serial boot parameters 2024-01-19 13:43:32 +01:00
1e054892fc Increase SMP CPUs to 32 2024-01-19 13:43:14 +01:00