!xmLtiCaAJxfhURjrXl:matrix.org

NixOS RISC-V

236 Members
NixOS on RISC-V https://wiki.nixos.org/wiki/RISC-V https://pad.lassul.us/NixOS-riscv64-linux https://github.com/orgs/NixOS/teams/risc-v70 Servers

Load older messages


SenderMessageTime
18 Mar 2026
@dramforever:matrix.orgdramforeverit "worked", but nobody got around to actually marking stuff...16:45:48
@qyliss:fairydust.spaceAlyssa Rossglobally disable checking if using binfmt imo 😈️16:49:41
@dramforever:matrix.orgdramforever i need to get nix --binfmt-misc pr'd into nix some time... 16:50:49
@dramforever:matrix.orgdramforeverif you haven't seen, https://github.com/dramforever/nix/pull/2516:51:16
@dramforever:matrix.orgdramforever it's just a little bit too hacky, and the rabbit hole got so deep i sent a patch to linux man-pagea 16:51:55
@dramforever:matrix.orgdramforever * it's just a little bit too hacky, and the rabbit hole got so deep i sent a patch to linux man-pages 16:52:02
@jammie:matrix.orgJamieMageeYeah, qemu-user17:39:14
19 Mar 2026
@jammie:matrix.orgJamieMageeI appreciate you taking the time to look into it with me. I've closed out my PR and I'll workaround it locally with an overlay.05:20:07
@alex:tunstall.xyzAlexFrankly, I'm surprised that QEMU continues to get RISC-V emulation subtly wrong.06:13:22
@alex:tunstall.xyzAlexOr is the issue unrelated to QEMU in that some things behave weirdly when userspace and kernelspace are on different architectures?06:15:15
@qyliss:fairydust.spaceAlyssa Rossoften qemu-user just doesn't implement certain stuff — remember it's not just emulating the architecture; it has to emulate the whole Linux API06:23:38
@dramforever:matrix.orgdramforever-ENOSYS is one of the least subtle wrongs qemu-user commits12:39:17
@dramforever:matrix.orgdramforeverbut yes usually you can expect user emulation to have a crap ton more problems than system emulation12:40:03
@colemickens:matrix.orgcolemickensIs there a branch y'all follow or maintain? Or just ride nixos-unstable and cross your fingers? :)19:17:42
@alex:tunstall.xyzAlex

Generally two options:

  1. Latest and pray
  2. Find someone else's (hopefully working) configuration and use the same revision as them
19:22:52
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)
In reply to @alex:tunstall.xyz
Or is the issue unrelated to QEMU in that some things behave weirdly when userspace and kernelspace are on different architectures?
Well, nix is one for example https://github.com/NixOS/nix/issues/15153
20:16:49
@alex:tunstall.xyzAlexYes, I ran into that issue myself a few weeks ago while doing binfmt emulation of aarch64.20:18:01
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)I guess it should be pretty easy to fix by just calling uname and using the appropriate arch for setting up seccomp?20:23:35
@alex:tunstall.xyzAlex

colemickens good news:

alex@alex-pc3 ~/r/O/n/ghc-cross-2 (ghc-cross-hadrian)> /nix/store/7kjpbn6fv6gqi9fx65ann5bqdsm3s9fi-riscv64-unknown-linux-gnu-ghc-9.10.3/bin/riscv64-unknown-linux-gnu-ghc --info | grep platform
 ,("target platform string","riscv64-unknown-linux")
 ,("Build platform","x86_64-unknown-linux")
 ,("Host platform","x86_64-unknown-linux")
 ,("Target platform","riscv64-unknown-linux")

I'm still double checking that the cross-compiler works, but I expect to PR the fix to Nixpkgs soon enough.

21:35:58
@alex:tunstall.xyzAlex

This alone is not enough to cross-compile cachix:

---> Starting interpreter on port 6072
Listening on port 6072
iserv-proxy-interpreter: tmp/nix/store/7kjpbn6fv6gqi9fx65ann5bqdsm3s9fi-riscv64-unknown-linux-gnu-ghc-9.10.3/lib/riscv64-unknown-linux-gnu-ghc-9.10.3/lib/riscv64-linux-ghc-9.10.3/ghc-prim-0.12.0-561f/libHSghc-prim-0.12.0-561f.a: RTS linker not implemented on riscv
iserv-proxy-interpreter: loadArchive "tmp/nix/store/7kjpbn6fv6gqi9fx65ann5bqdsm3s9fi-riscv64-unknown-linux-gnu-ghc-9.10.3/lib/riscv64-unknown-linux-gnu-ghc-9.10.3/lib/riscv64-linux-ghc-9.10.3/ghc-prim-0.12.0-561f/libHSghc-prim-0.12.0-561f.a": failed

iserv-proxy: <socket: 17>: hGetBufSome: resource vanished (Connection reset by peer)
HasCallStack backtrace:
  collectBacktraces, called at libraries/ghc-internal/src/GHC/Internal/Exception.hs:169:13 in ghc-internal:GHC.Internal.Exception
  toExceptionWithBacktrace, called at libraries/ghc-internal/src/GHC/Internal/IO.hs:260:11 in ghc-internal:GHC.Internal.IO
  throwIO, called at libraries/ghc-internal/src/GHC/Internal/IO/Exception.hs:315:19 in ghc-internal:GHC.Internal.IO.Exception
  ioException, called at libraries/ghc-internal/src/GHC/Internal/IO/Exception.hs:319:20 in ghc-internal:GHC.Internal.IO.Exception


/nix/store/vw5aaxwm2fppx1xarn7k41db5yr3rvww-iserv-wrapper-both/bin/iserv-wrapper: line 1: kill: (499) - No such process
<no location info>: error: External interpreter terminated (1)
21:43:39
@alex:tunstall.xyzAlex colemickens https://github.com/NixOS/nixpkgs/pull/501439 22:00:19
20 Mar 2026
@silvio:booq.org@silvio:booq.org left the room.09:01:21
18 Aug 2023
@shados:nixos.devShados joined the room.05:42:58
@misuzu:matrix.orgmisuzu
% cat /proc/mtd                            
dev:    size   erasesize  name
mtd0: 00080000 00001000 "spl"
mtd1: 00010000 00001000 "uboot-env"
mtd2: 00400000 00001000 "uboot"
mtd3: 00a00000 00001000 "reserved-data"

Looks like the visionfive2_fw_payload.img should be flashed to /dev/mtd2 instead of /dev/mtd1

08:29:39
20 Aug 2023
@erremilia:matrix.orgerremilia joined the room.17:53:34
@claesatwork:matrix.orgClaes joined the room.19:27:07
24 Aug 2023
@erremilia:matrix.orgerremilia1000004363.jpg
Download 1000004363.jpg
19:36:55
@erremilia:matrix.orgerremiliaThis should be fun to play with19:37:02
@hive:the-apothecary.clubDagn Hiveoooh nice19:38:17
@hive:the-apothecary.clubDagn Hivesame chip as starfive v2 iirc so it should be somewhat easy to use19:38:37

Show newer messages


Back to Room ListRoom Version: 10