On Wed, Aug 17, 2022 at 4:39 PM Alyssa Ross <hi@alyssa.is> wrote:
Yeah, I agree something like this would be good. Especially when testing on hardware as you say. I would like to think more about exactly how this should work. Do you think that, if you it were possible to develop Spectrum on Spectrum, it would be acceptable to have to reboot into a new configuration if the host system was changed? (Assume that the process of actually building the new system is fast — the reboot would be the main overhead.)
Option to develop on the target system is something people (not vocal here) already expect. I think booting into a new configuration is MCU style development process and not a fast enough iteration cycle on Linux user space in all scenarios. Even in kernel driver development, one may want to unload/load module during development but even disable module loading as a security hardening mechanism in deployment/production configuration. Another example is security policies development (SELinux) - you want to iterate and test them in user space during development but you want to deploy them immutable. Then again, kernel or device tree changes will require rebooting. Point is - rebooting for everything is not development friendly enough mechanism alone.
You mean set it to your own, custom version of nixos-hardware that included WIP support for the board you were working on? Yeah, that
Yeah, like an own git repo as source for nix-channel to pick the nix-hardware module. Ideally, some of that could be easily contributed to nix-hardware upstream - currently it seems to accept different quality support for different HW so that should not be an issue.
wouldn't be a problem at all.
Sounds good.
In the medium term, I'd like to decouple nixos-hardware's custom kernel packages from NixOS configurations. But that would require somebody finding the time to sit down and make the change, and also convince other nixos-hardware users that it's the way to go. I don't think it would be a problem though, especially if it meant nixos-hardware getting more active maintenance, which it's lacking at the moment because it's not too well advertised and so not enough people are using it.
Ideally yes and I hope we could contribute to that effort. However, we need to focus on getting Spectrum running on aarch64 with imx8 for now. For that I'm reading that nixos-hardware approach is preferred.
Yeah, it's definitely the way to go. And if we can make nixos-hardware better in future, that would just be further progress on top of integrating nixos-hardware as described above.
Right. Even iMX8 dev board generic support might be interesting for other projects. I've seen iMX8M EVK being used at least with Zircon on Fuchsia. Best, -Ville