<flokli> uff
<samueldr> so, to quickly answer, there's no clear winner, and for everything existing RK3399-based devices are probably the best
<samueldr> unless you want Windows
<flokli> no windows ;-)
<craige> Hey clever++ - thanks for your ARM+Qemu nix files. HUGELY helpful. Have you seen the build fail due to a "bash: Exec format error"?
<{^_^}> clever's karma got increased to 318
<clever> craige: is binfmt-misc configured? and the qemu allowed into the nix sandbox?
<craige> I'm unsure (this was last night's work). I'll follow those leads next. Thanks clever :-)
<clever> craige: there is a qemu.nix module in my nixos-configs, that configures everything
<craige> I took that file and the overlays. I beleived I'd configured it correcty bit after being deployed when I build an image, it no longer complained about not being aarch64 but then failed on the bash error - so I suspect you're 100% right that I need to do something about binfmt
<samueldr> I'm curious how hard it would be to have qualcomm on-board with making a mainline-based linux laptop that runs its firmware in a safe manner
<samueldr> but from the few quips I've seen, they may be adverse to making it virtualization friendly :/
<clever> craige: that part configures binfmt-misc
<cidkid> samueldr: you said there was going to be eventual wcnss support, do most qualcomm devices work with wcnss or only some?
<samueldr> some
<samueldr> but from my experience, it's all "vintage"-based again
<samueldr> a swath of devices will have extremely similar quirks that apply
<cidkid> yeah hmm
<cidkid> I don't think any msm8998 devices do wncnss then
<cidkid> which is kinda sad for me
<samueldr> I'll most likely have it figured out at one point since the pixel 2 is likely going to work the same
<samueldr> though obviously can't give an ETA
<cidkid> yeah ofc
<cidkid> I have really no idea where to start with wifi on msm8998 without using halium
<cidkid> so I guess I'll wait
<cidkid> although libhybris itself might work
<cidkid> with enough configuring
h0m1 has quit [Ping timeout: 246 seconds]
h0m1 has joined #nixos-aarch64
<cidkid> samueldr: so currently, USB internet from computer -> phone isn't working?
<samueldr> networking can work, but nothing setup to forward internet from your computer to the phone
<samueldr> though it,s
<samueldr> though it's entirely feasible
<cidkid> alright
<clever> cidkid: one min...
<clever> cidkid: line 76-100 spins up a dhcp server on the interface specified on line 77
<clever> cidkid: lines 105-108 spin up a dns cache, to serve dns to that interface
<clever> cidkid: 113 sets a static ip on the interface
<clever> cidkid: and line 116-121 sets up NAT, so anything on that interface can reach the web thru your machine
<clever> the tricky part, is that the interface wont exist if you unplug the phone, and some of those things may fail to start
<clever> it expects the interface to always exist (an ethernet card) and for the link to just come&go, but with g_ether, the whole network interface comes&goes
<cidkid> alright rootfs is flashing
<cidkid> samueldr: so rootfs is found but no generation was found to boot
<cidkid> eg the fuscia screen I get when booting with a pre new-init boot system
<cidkid> I don't know what I can really do from here
<cidkid> Invalid sparse file format at header magic
<cidkid> don't know if ^^ that has anything to do with it
<cidkid> ping me if you think of something please
<cidkid> I'll try dd ing through TWRP
cidkid has quit [Quit: Ping timeout (120 seconds)]
cidkid has joined #nixos-aarch64
<DigitalKiwi> clever: how do you use the linux_rpi3 kernel
<clever> DigitalKiwi: *looks*
<DigitalKiwi> time nix-build ~/projects/nixpkgs/nixos/ -A config.system.build.sdImage -I nixos-config=/home/kiwi/projects/github/nix-configs/hosts/rpi-nixos/sd-image.nix --argstr system aarch64-linux
<DigitalKiwi> error: attribute 'extend' missing, at /home/kiwi/projects/nixpkgs/nixos/modules/system/boot/kernel.nix:40:31
<clever> DigitalKiwi: what did you set kernelPackages to?
<DigitalKiwi> boot.kernelPackages = pkgs.linux_rpi3;
<cidkid> IT WORKS
<cidkid> You have to flash rootfs through TWRP though
<clever> DigitalKiwi: kernelPackages MUST always be set to a kernelPackages set, not a bare kernel
<clever> 16576 linuxPackages_rpi3 = linuxPackagesFor pkgs.linux_rpi3;
<DigitalKiwi> boot.kernelPackages = pkgs.linuxPackages_rpi3;
<clever> yep, thats it
<DigitalKiwi> should that work?
<DigitalKiwi> thanks
<DigitalKiwi> i realized that after :<
<clever> that will re-run callPackage for every optional thing, aimed at the rpi kernel
<DigitalKiwi> it's just weird how the kernels don't show up right
<clever> so it will automagically build the modules against the right kernel
<DigitalKiwi> in nix search
<DigitalKiwi> i always forget
<clever> 16579 linuxPackages_4_9 = recurseIntoAttrs (linuxPackagesFor pkgs.linux_4_9);
<DigitalKiwi> this is probably why my pi does not work after i switch :P
<clever> only if recurseIntoAttrs gets involved, will nix-env -q recurse into it
<DigitalKiwi> ok so i lied
<DigitalKiwi> i had the correct line
<DigitalKiwi> so that's not why it doesn't work after switch :<
<clever> DigitalKiwi: any uart output?
<DigitalKiwi> idk
<DigitalKiwi> when i connected it to the tv it goes to where it should start loading the kernel and just black screens
<DigitalKiwi> i'm probably missing something from my configuration.nix?
<clever> without the uart output, it can be hard to debug boot issues
<DigitalKiwi> does my serial cable give me uart
<clever> yes
<DigitalKiwi> so what i'm doing right now is building a new sd-image with the linuxPackages_rpi3 and i'll see if that boots
<DigitalKiwi> and in the meantime...should i just be able to put most of what is in my sd-image.nix in the configuration.nix?
<clever> yeah
<DigitalKiwi> specifically i'm wondering if this would help <nixpkgs/nixos/modules/installer/cd-dvd/sd-image-aarch64.nix>
<DigitalKiwi> or maybe my hardware-configuration.nix is wrong
<clever> if the rootfs isnt defined properly, the initrd may fail to mount the rootfs
<DigitalKiwi> that's a weird uuid
<DigitalKiwi> it's real though
<clever> DigitalKiwi: after you flash the image to the card, does blkid say its right?
<DigitalKiwi> ls /dev/disk/by-uuid/
<DigitalKiwi> 2178-694E 44444444-4444-4444-8888-888888888888
<DigitalKiwi> how do you mean
<clever> DigitalKiwi: run the blkid command on the partition
<DigitalKiwi> right now or do i have to flash a new one and from the pi or a different computer
<DigitalKiwi> sudo blkid /dev/disk/by-uuid/44444444-4444-4444-8888-888888888888
<DigitalKiwi> /dev/disk/by-uuid/44444444-4444-4444-8888-888888888888: LABEL="NIXOS_SD" UUID="44444444-4444-4444-8888-888888888888" TYPE="ext4" PARTUUID="2178694e-02"
<clever> the partition, not that symlink
<clever> like, sda1
<DigitalKiwi> /dev/mmcblk0p2 on / type ext4 (rw,relatime) /dev/mmcblk0p2 on /nix/store type ext4 (ro,relatime)
<DigitalKiwi> that's weird innit?
<clever> totally normal
<clever> nixos bind-mounts /nix/store to /nix/store, so it can make it read-only
<DigitalKiwi> oh
<clever> so root cant edit things in the store
<clever> DigitalKiwi: blkid /dev/mmcblk0p2
<DigitalKiwi> /dev/mmcblk0p2: LABEL="NIXOS_SD" UUID="44444444-4444-4444-8888-888888888888" TYPE="ext4" PARTUUID="2178694e-02"
<clever> looks like it should work
<DigitalKiwi> why doesn't the boot partition get a line in hardware-configuration
<DigitalKiwi> FIRMWARE
<clever> DigitalKiwi: nixos on the rpi doesnt use a "boot partition", /boot is just a dir on /
<clever> DigitalKiwi: the firmware partition is treated as read-only, and never gets mounted
<DigitalKiwi> oh
<clever> the firmware partition has both the rpi firmware, and a copy of u-boot
<clever> and u-boot then just reads the /boot dir on /, i believe
<clever> its getting late here, i should get to bed
<cidkid> hmm odd
<cidkid> I get no boot with new init
<cidkid> although I am pretty sure If I could load firmware I can get audio working soon
<cidkid> Mm I got firmware working
<cidkid> and adsp has no dmesg firmware loading errors
cidkid has quit [Remote host closed the connection]
orivej has joined #nixos-aarch64
zupo has joined #nixos-aarch64
zarel_ has joined #nixos-aarch64
zarel has quit [Ping timeout: 268 seconds]
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zupo has joined #nixos-aarch64
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zupo has joined #nixos-aarch64
zupo has quit [Client Quit]
zupo has joined #nixos-aarch64
zupo has quit [Client Quit]
orivej has quit [Ping timeout: 260 seconds]
t184256 has left #nixos-aarch64 ["Error from remote client"]
t184256 has joined #nixos-aarch64
orivej has joined #nixos-aarch64
wavirc22 has joined #nixos-aarch64
zupo has joined #nixos-aarch64
<srk> DigitalKiwi: is there a reason for rpi specific kernel instead of mainline?
<DigitalKiwi> i want this library to work and it doesn't and i was hoping the rpi kernel would make it work https://github.com/jgarff/rpi_ws281x/
<srk> :D
<srk> better grab esp8266 and nodemcu
<srk> with mainline you need some overlays to expose /dev/spidev(s) then it should work
<srk> not sure about PWM/PCM
<DigitalKiwi> is there documentation about the overlays somewhere
<DigitalKiwi> though i haven't confirmed i even have a working setup with mainline kernel ;_; i probably don't
<DigitalKiwi> https://github.com/jgarff/rpi_ws281x/blob/master/rpihw.c#L414 do you know if it'll make this file exist
<srk> wtf is that another rpi specific thing
<srk> Revision : 0000
<srk> Hardware : BCM2835
<srk> cpuinfo on pi2
<srk> are you running it on aarch64?
<DigitalKiwi> the only place i've gotten it to work is raspbian
<srk> yes because rpi foundation creates a lot of confusion with their patched kernel and special way of doing things
tilpner has joined #nixos-aarch64
ryantrinkle has joined #nixos-aarch64
<DigitalKiwi> ok so i got a nixos-rebuild switch and a reboot to work with the default nixos kernel
<DigitalKiwi> which is...progress i guess
ryantrinkle has quit [Ping timeout: 260 seconds]
<srk> cool!
wavirc22 has quit [Ping timeout: 272 seconds]
wavirc22 has joined #nixos-aarch64
cidkid has joined #nixos-aarch64
cidkid has quit [Ping timeout: 260 seconds]
cidkid has joined #nixos-aarch64
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
wavirc22 has quit [Ping timeout: 268 seconds]
wavirc22 has joined #nixos-aarch64
cidkid has quit [Ping timeout: 268 seconds]
zupo has joined #nixos-aarch64
<clever> srk: i suspect the literalExample might be wrong, it feels like it will still give a storepath
<clever> srk: and the example on line 33 is missing some indent
<srk> oh indeed
<srk> clever: not sure why I've had to do {./overlays/my.dts}, for some reason ./overlays/my.dts wasn't picked up correctly
<clever> srk: what if you just dont quote it?
<srk> think I've tried both ways, let me check again
ryantrinkle has joined #nixos-aarch64
orivej has quit [Ping timeout: 260 seconds]
<srk> novena decided I need a break and started compiling unrelated stuff :D
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<srk> not sure if such long example is a good idea, will try something shorter like i2s status okay
<srk> also need to explain compatible as this queries both kernel dtb a dtbo for compatible strings and applies only if there's a match
zupo has joined #nixos-aarch64
cidkid has joined #nixos-aarch64
<cidkid> Hmm I can't fix the new init issue with my phone1
<cidkid> *phone
orivej has joined #nixos-aarch64
cidkid has quit [Ping timeout: 240 seconds]
zupo has quit [Ping timeout: 268 seconds]
ryantrinkle has quit [Ping timeout: 268 seconds]
cidkid has joined #nixos-aarch64
ryantrinkle has joined #nixos-aarch64
<clever> samueldr: ive learned a new tricky that is massively useful for arm debug
<clever> samueldr: just throw a bpkt opcode into the linux source, and boot!
<clever> samueldr: the cpu will automatically halt, and return control to gdb, if jtag is properly connected!
<samueldr> no
<samueldr> during the time mainline has to work around the pi 4 peculiarities, this is being built https://hydra.nixos.org/job/nixos/trunk-combined/nixos.sd_image_raspberrypi4.aarch64-linux
<samueldr> do not rely on this image existing
<samueldr> its SLA is "I can't wait to delete the derivation once mainline works for our generic image"
<ar> i don't plan to rely on it existing forever; all i care about is getting nixos on my rpi4 ~now-ish
<ar> samueldr++
<{^_^}> samueldr's karma got increased to 160
cidkid has quit [Ping timeout: 265 seconds]
zupo has joined #nixos-aarch64
lovesegfault has joined #nixos-aarch64
zupo has quit [Ping timeout: 252 seconds]
zupo has joined #nixos-aarch64
bennofs has quit [Remote host closed the connection]
bennofs has joined #nixos-aarch64
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
lovesegfault has quit [Quit: WeeChat 2.7]
lovesegfault has joined #nixos-aarch64
orivej has quit [Ping timeout: 272 seconds]
ryantrinkle has quit [Ping timeout: 260 seconds]