c40dec90bda08d364beb8e7a17bd970c9dc18c2c
Hibernation powers off the Lattice USBIO bridge that the ov08x40 sensor and Intel CVS sit behind. usbio has no reset_resume callback, so on restore the USB core unbinds and rebinds it, which re-creates the sensor and CVS I2C clients. The new clients lack the fwnode graph that ipu-bridge built at boot, and ipu-bridge never rebuilds it, so the camera stays dead until a cold boot. Patch usbio to redo the bridge handshake in reset_resume instead of being rebound, and patch gpio-usbio to restore its pin configuration and output values after such a reset. Both are built from the kernel source and installed under updates/, sharing the build recipe with the patched ipu6-isys module.
config-manager
./config-manager is a module that contains a script to make usage of this flake easier.
To install it
- first add the module to the nixOS system connfiguration
- set
config-manager.flakePath = <path to this flake> - run
nixos-rebuild switch --flake .#<configuration>after thatcmwill be available on$PATH.
Secrets
Secrets are managed by agenix (https://github.com/ryantm/agenix).
Creating new secrets
-
Update
secrets/secrets.nixwith the new secret. -
When inside
./secrets:
EDITOR=vim agenix -e "some-secret.age"
This will create a new secret. To view its content one can do:
EDITOR=vim agenix -d "some-secret.age" -i ~/.ssh/alex.pinwheel
Or use some other SSH key that is has been used to key the secret.
Test VM
Build the test VM with the command:
cm --build-test-vm
and test it with:
cm --run-test-vm
Languages
Nix
71.8%
HTML
16.5%
Python
7.3%
Shell
3.6%
Emacs Lisp
0.8%