wavirc22 has joined #nixos-aarch64
vika_nezrimaya has quit [Ping timeout: 256 seconds]
samrose has quit [Ping timeout: 250 seconds]
wavirc22 has quit [Ping timeout: 265 seconds]
h0m1 has quit [Ping timeout: 265 seconds]
h0m1 has joined #nixos-aarch64
wavirc22 has joined #nixos-aarch64
orivej has quit [Ping timeout: 240 seconds]
FRidh has joined #nixos-aarch64
FRidh2 has joined #nixos-aarch64
FRidh has quit [Ping timeout: 258 seconds]
zupo_ has joined #nixos-aarch64
orivej has joined #nixos-aarch64
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…]
syd has joined #nixos-aarch64
syd has quit [Quit: Connection closed]
zupo has joined #nixos-aarch64
samrose has joined #nixos-aarch64
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ryantrinkle1 has quit [Ping timeout: 250 seconds]
ryantrinkle has joined #nixos-aarch64
zupo has joined #nixos-aarch64
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zupo has joined #nixos-aarch64
wavirc22 has quit [Read error: Connection reset by peer]
wavirc22 has joined #nixos-aarch64
FRidh has joined #nixos-aarch64
FRidh2 has quit [Ping timeout: 256 seconds]
ryantrinkle has quit [Ping timeout: 240 seconds]
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
orivej has quit [Ping timeout: 256 seconds]
ryantrinkle has joined #nixos-aarch64
<Danct12[m]> samueldr: which is the environment you use in your tweet?
<samueldr> examples/demo configuration
<samueldr> but, briefly said, it's based on preconfigured XFCE, with awesome as WM
<samueldr> it's not an actual environment
wavirc22_ has joined #nixos-aarch64
<samueldr> it's something I threw together rather quickly last year that's better than using the desktop environment
<samueldr> trying to wrangle XFWM windows on a touch screen that's high DPI is... pretty much impossible :)
wavirc22 has quit [Ping timeout: 256 seconds]
zupo has joined #nixos-aarch64
v0|d` has joined #nixos-aarch64
v0|d has quit [Ping timeout: 265 seconds]
v0|d` has quit [Ping timeout: 265 seconds]
<samueldr> Danct12[m]: anything more you wanted to know about that?
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zupo has joined #nixos-aarch64
<lordcirth> When I try to enable xserver on my PBP, it won't build; complains that the vmware driver can't be built. I tried to override videoDrivers to [ "vesa" ] but that doesn't detect the Mali GPU. I can't figure out which of these drivers I need?
<samueldr> "modesetting"
FRidh has quit [Quit: Konversation terminated!]
<lordcirth> I was just trying that, great
<lordcirth> samueldr, I get a black screen with a single _.
<samueldr> I'm still on 19.09 from an older build, been a couple (2) months since I touched the pinebook pro
<samueldr> so I cannot say if it should or shouldn't work right now
<samueldr> but it did at one point
<samueldr> you may want to look at the Xorg logs, somewhere under /var for lightdm, likely in the journal for other DM
<lordcirth> Yeah, I can switch to tty1, at least
<samueldr> if it ends up more convenient, ssh could be good too :)
<lordcirth> sddm-helper exited 11
<samueldr> hopefully there's a log
<lordcirth> It's empty :P
<lordcirth> seems it coredumped
<lordcirth> I bet it's trying to write something to the store
<samueldr> that's a weird bet to do
<samueldr> that wouldn't really lead to a coredump
<samueldr> and it would likely fail on other systems too
<samueldr> I'm not saying that's not it, but that's not something my gut would feel :)
Darkmatter66 has joined #nixos-aarch64
<samueldr> you may want to try fbdev as a videoDriver, as a stop-gap solution
<lordcirth> Well, I'm looking at this: https://bbs.archlinux.org/viewtopic.php?id=222486
<samueldr> obviously that's not going to have any kind of acceleration
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<lordcirth> For them, it was /var being noexec
Darkmatter66_ has quit [Ping timeout: 256 seconds]
<lordcirth> I will try the fix that worked for them
<lordcirth> What is the NixOS equivalent of changing /etc/environment?
<lordcirth> thanks!
Darkmatter66 has quit [Client Quit]
Darkmatter66 has joined #nixos-aarch64
vika_nezrimaya has joined #nixos-aarch64
zupo has joined #nixos-aarch64
zupo has quit [Client Quit]
zupo has joined #nixos-aarch64
<samueldr> I'm trying to think of a way to count valid boots on android-based systems without A/B
<samueldr> I have this fun idea, well two
<samueldr> 1) assuming we don't fill the boot partition, keep a couple bytes at the end to store a counter and maybe a signature
<samueldr> (signature in the sense of a magic number)
<samueldr> e.g. MNBOOTxx where xx would be uint32_t so it'd be 8 bytes
<samueldr> or, assuming the boot image isn't checksummed and validated at boot, what if it was self-modifying the kernel command-line?
<samueldr> the only issue with that is when boot has a kernel that boot just enough, but panics, it would still boot loop
<samueldr> which... we could maybe add to the panic handler support for that? where it would set the next "boot command" to recovery
<samueldr> there is value in that even for newer android-based devices, as not all of them use A/B schemes
<lordcirth> samueldr, your goal is to make all borked boots reboot to previous?
<samueldr> not necessarily to previous, but at the very least to the recovery boot menu
<samueldr> assuming that on-device you would flash only the boot partition with a fresh build
<samueldr> the kernel/stage-1 of recovery should hopefully still be one that boots
<samueldr> I want to enable mostly-fearless tinkering on-device
<danielrf[m]> samueldr: My thoughts aren't fully formed yet, but I've been experimenting with systemd-boot counting and thinking how similar mobile-nixos should be: https://github.com/NixOS/nixpkgs/pull/84204
<{^_^}> #84204 (by danielfullmer, 5 days ago, open): [WIP] nixos/systemd-boot: boot counting and automatic fallback
<danielrf[m]> I don't think we should use android's A/B boot counting
<lordcirth> samueldr, seems it is a known issue: https://github.com/NixOS/nixpkgs/issues/61840
<{^_^}> #61840 (by ambrop72, 46 weeks ago, open): SDDM crashes in nixos-unstable
<samueldr> we'll need to interact with android's A/B, danielrf[m]
<danielrf[m]> once we mark the slot as "successfully booting" it then ignores boot counters and will always boot into normal mode (not recovery)
<danielrf[m]> even if it starts failing
<samueldr> I assumed we had to mark it successfully booting every time
<danielrf[m]> I think we should just mark it once--and use another mechanism for counting boots per generation
<samueldr> but still, that only solves the stage-2 situation
<danielrf[m]> nope, I thought so too initially
<samueldr> I'm not following
<samueldr> systemd is not involved until stage-2
<samueldr> but I do agree that if we handle counting in some cases, we should handle counting in all cases
<danielrf[m]> I'm not saying we should use all the systemd stuff in mobile-nixos (maybe just targets like "boot-complete.target")
<samueldr> ah
<samueldr> yeah, I didn't have any opinions yet about declaring a successful boot, and that makes sense here
<danielrf[m]> we'll still need to keep our own counters somewhere
<samueldr> yeah
<samueldr> I am focusing on the machinery that the boot-complete bits would interact with
<danielrf[m]> is it possible to have them in userdata instead of boot.img? I'd like if boot.img was read-only
<samueldr> main issue with that is userdata may be encrypted
<danielrf[m]> ah true
<samueldr> that's why I like the 8 bytes at the end of boot partition idea
<danielrf[m]> but don't you mount it to get the list of generations anway?
<samueldr> at some point decryption will be added to the stage-1
<danielrf[m]> (I haven't looked through how your boot.img works in detail yet)
<lordcirth> lightdm didn't work either, trying fbdev
<samueldr> lordcirth: chances are it's simply the same symptoms for SDDM, without details on both issues it's hard to say
<samueldr> likely different resolutions
<samueldr> considering that issue is using nvidia+prime
<samueldr> danielrf[m]: with the 8 bytes at the end of the boot partition, the partition is not read-only, but the image would stay verifiable
<samueldr> danielrf[m]: imagine you implement some verified boot in linux, you'd have to account for those last bytes
<samueldr> that makes me think self-modifying the kernel command line is a terrible idea for that reason
<samueldr> and I'm seeing we actually have the need for two counters
<samueldr> one for stage-1, one for stage-2
<lordcirth> lightDM + fbdev worked, trying sddm + fbdev
<danielrf[m]> So I believe that AVB wouldn't work if any modifications are made to the data in the boot partition, as the whole thing gets hashed
<samueldr> oh, right
<samueldr> maybe with A/B we have more leeway somewhere else we can use
<samueldr> or maybe we make system or userdata smaller by a couple bytes and handle it there
<samueldr> unless AVB handles verifying system
<samueldr> (that it's not done by the kernel)
<samueldr> or maybe we need to investigate all partitions and see what can be used
<samueldr> though I think that in that case, we have to rely on the A/B counter for stage-1, and what you're thinking for stage-2
<danielrf[m]> I agree
<samueldr> and we have the self-modifying boot partition counter to reboot in recovery in non A/B devices
<samueldr> though if we always reboot to recovery in panics, and always fail in a panic
<samueldr> we might not even need it there
<samueldr> ah, no, since boot_as_recovery is implied for A/B so we need to wait on the counter
<danielrf[m]> So, as far as counters for stage-2: you could have a single counter--or a counter for each generation
<danielrf[m]> the way systemd-boot would work is effectively a different counter for each entry (nixos generation)
<samueldr> yeah, I'm far less concerned by stage-2 counters
<samueldr> but knowing we want to handle each separately helps immensely
<danielrf[m]> for stage-1 I think just using the a/b counter is fine (and your idea for non a/b devices)
<danielrf[m]> I can't think of any issues with that at the moment
<samueldr> the issues will be about making plumbing around all that :)
<danielrf[m]> definitely
<samueldr> depthcharge and u-boot need that too
<samueldr> u-boot I already set some breadcrumb trail
<danielrf[m]> if we ever want to flash a new boot.img from inside nixos the a/b system would be very nice
<samueldr> I want to enable fearless-on-device-tinkering
<ashkitten> i wish there was a way to change boot slots from fastboot on the device itself
<ashkitten> you can set the active slot from a connected computer but not from the device itself
<ashkitten> (or a booted os/recovery can do it as well)
<samueldr> true, in the field you'd be left with a hard-to-deal-with situation :(
<ashkitten> at the very least maybe the mobile nixos recovery could give an option to set the boot slot?
<ashkitten> then if there's some issue where you can get into the mobile-nixos recovery but can't boot into the os then you can switch the boot slot
<ashkitten> pretty niche scenario, yes, but...
<samueldr> hmm, I need to look again if I can find an OTG dongle where I can also inject power
<samueldr> for type-B
<samueldr> micro
<samueldr> ashkitten: you're right, that would be a desirable feature
<ashkitten> hmm btw can the system and userdata partitions on a device be merged?
<samueldr> with LVM, likely
<ashkitten> i'm not sure if that's allowed by the android bootloader
<samueldr> but touching partitions is a big no-no
<ashkitten> oh i see
<samueldr> as with most devices you could brick them hard
<samueldr> you'd need the qualcomm firehose thing
<ashkitten> oof
<samueldr> which needs a per-model signed program
<samueldr> though, that's half-a-lie
<samueldr> new devices may be different
* samueldr digs for docs
<samueldr> "resizable partitions" is the keyword
<samueldr> otherwise called dynamic partitions https://source.android.com/devices/tech/ota/dynamic_partitions
<ashkitten> interesting
<samueldr> you're still left with a split super/userdata
<samueldr> super, though, AFAIUI is freely tinkerable with
<ashkitten> i don't know if that's something we necessarily care about though, since i assume we'd like a one-size-fits-all solution for all devices yeah?
<samueldr> though they're entirely relying on device mapper to setup the partitions
<samueldr> we need to care about it in some way
<samueldr> since fastboot will now allow flashing system when fastbootd exists
<samueldr> though I *think* we may be able to simply take the whole super partition as one part of the LVM volume
<samueldr> and userdata as the other
<samueldr> though that does leave us unable to use the vendor partitions
<samueldr> but it might not be a huge deal
<samueldr> oop!
<samueldr> oops!*
<samueldr> I might have accidentally started a firefox build on my asus-z00t
<ashkitten> the only thing that we need to be actually separate a/b for our purposes is the boot partition, yeah? that way we have one bootloader
<ashkitten> LOL
<ashkitten> er, that way we have two stage-1s
<samueldr> yep, that's what I've been thinking about, that we don't really care about system
<samueldr> we really only care about boot
<ashkitten> i got distracted, lol
<ashkitten> so if we can just merge system_a, system_b, and userdata somehow, we'd have a lot more space to work with
<samueldr> yes
<samueldr> in a sense, it shouldn't be any different than merging system and userdata
<ashkitten> the bootloader should only care about which boot partition it hands off to, anyways. anything further is out of its scope
<samueldr> depends on how AVB works
<samueldr> there's that uncertainty
<ashkitten> oh, hm
<samueldr> if the bootloader validates the system partition with AVB, then it won't ever be usable really
<danielrf[m]> yeah, my current thought it just to use AVB for boot.img, and something else for the remainder
<samueldr> but if it's the kernel/dm-verity that does, then everything's alright
<danielrf[m]> I think (but would need to check) that the bootloader only validates boot.img
<samueldr> >> /dev/disk/by-label/NIXOS_SYSTEM 11G
* samueldr weeps
<danielrf[m]> and the kernel validates everything else afterward
<samueldr> danielrf[m]: that's my assumption too
<ashkitten> i can't wait until i get my cosmo and port nixos to it....
<ashkitten> that would seem to not be happening for quite a while though
<ashkitten> i can only hope it'll arrive soon after the pandemic clears up
<samueldr> drat, I really need to figure out an MTK device I should try and get for a target to port to
<samueldr> hopefully one which can be flashed with the flashing tools, so nothing recent from xiaomi
<samueldr> and hopefully one with trivial bootloader unlock
<samueldr> oh, and hard mode, with sources :)
<samueldr> it's so great using a usb ethernet adapter to rebuild on device
<ashkitten> the only mediatek device i have is a steam link
<samueldr> an android-based MTK device **
<ashkitten> :p
<samueldr> I do have one MTK phone, but no sources even after getting in touch multiple times
<samueldr> (jelly phone)
<ashkitten> ugh, gpl violations
<samueldr> I would love to be able to port Mobile NixOS to it
<ashkitten> *shakes fist*
<samueldr> yeah :(
<samueldr> chinese OEMs + MTK gonna do what they do best
v0|d has joined #nixos-aarch64
<ashkitten> i wish non-phone android devices were generally unlockable
<samueldr> ah, TWRP ships with a prebuilt kernel
<samueldr> oh boy
<ashkitten> like the chromecast, how cool would that be?
<samueldr> they are not also non-compliant with GPL :(
<samueldr> they are now*
<samueldr> chromecast is not really android-based, but I do agree
<samueldr> nothing should be locked
<ashkitten> i wanna run nixos on my tv
<samueldr> I should be able to change the firmware of my washing machine even
<samueldr> I want to fix the dang problems of that bad firmware
<samueldr> yes, a washing machine is garbage purely from its firmware bugs :(
<samueldr> and it's not even a "smart" washing machine
<samueldr> it's pretending to be an electro-mechanical model from like the 80s in looks and features
<ashkitten> my tv shows me ads for installable software on its home screen, even though it's never been connected to the internet
<samueldr> but it's "smart"
<colemickens> I want not-os/nixiosk + plex-mpv-shim (uses mpv as a plex player) on a chromecast form-factor $10 ARM hdmi plug thing.
<ashkitten> ALSO this tv doesn't even support hdmi-cec remote passthrough :<
<ashkitten> apparently the non-roku version of this tv does
<samueldr> ouch
<samueldr> oh, that's the jelly pro I have, I'm forgetful, but still, no sources, prebuilt kernels.... bad :(
* samueldr laughs in Nix
<ashkitten> i assume the uh, whatever it's called free software organization that does legal action, doesn't care about android devices?
<samueldr> they do
<samueldr> but they need to sue on behalf of projects that work with them
<samueldr> e.g. the SFC, the one "bad mofo" that are actually aggressive do
<samueldr> e.g. if there's busybox in there, they will
<ashkitten> so you can't just point them at a gpl violation and say go get em
<samueldr> no :(
<samueldr> I should really contribute to the kernel ASAP so in a couple years my contributions end up on MTK devices
<samueldr> then *I* could do it
<ashkitten> haha
<ashkitten> the long game
<ashkitten> honestly though, go for it
<samueldr> well, that does mean I need to find something to contribute
<samueldr> and probably not something trivial like a typo correction
<samueldr> (even though technically it would work)
<samueldr> and to a subsystem that ends up being part of a built kernel for those devices
<ashkitten> you might end up doing it by accident if you keep porting devices, yeah?
<samueldr> hopefully!
<ashkitten> we'll see :p
<samueldr> like, I actually have meaningful changes to some kernels as shipped by Mobile NixOS
<samueldr> but that's the catch
<samueldr> they're not mainline, and not sources used by MTK
<ashkitten> ah yeah
<ashkitten> so if you upstream changes..
<srk> reminds me I need to poke the last few patches for my armv7 laptop graphics
<samueldr> I hate OEMs
<samueldr> 201M partition for an "in-store demo" partition
<samueldr> for files
<samueldr> I'll need to extract that to see what it is exactly
<samueldr> oh!
<samueldr> the persist partition is how some settings like timezone seems to be saved
<samueldr> at least that's where TWRP ends up saving settings, and I *think* I see other relevant settings
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
orivej has joined #nixos-aarch64
<samueldr> welp, "F" me
<samueldr> spent like an hour searching for something
<samueldr> until I found that I already did it
<craige> :-)