Commit graph

179 commits

Author SHA1 Message Date
Daniel Barlow
e6cb5e319b extract NETDEVICES kconfig to kernel.nix module 2023-11-05 11:31:23 +00:00
Daniel Barlow
e6ef4f78bb "ubimage" module contains ubifs image + instructions
Presently either you run this from U-Boot or you figure out for
yourself how to kexecboot into a recovery system :-)
2023-10-21 23:20:53 +01:00
Daniel Barlow
f3225c2bd5 delete dup outputs.systemConfiguration
perhaps this should go into initramfs.nix not jffs2.nix
2023-10-19 10:09:08 +01:00
Daniel Barlow
629914f65e initial support for ubifs 2023-10-16 19:55:17 +01:00
Daniel Barlow
364c5faf9e tftpboot: fix errors in phram partition size calc 2023-10-10 20:26:27 +01:00
Daniel Barlow
bd20f3e419 uimage: make fit optional 2023-10-09 19:47:57 +01:00
Daniel Barlow
f62ad0e1d7 use "tftpboot" instead of "tftp" in u-boot commands
openwrt's u-boot installation doesn't accept the short form
2023-10-09 19:47:57 +01:00
Daniel Barlow
c18f07f02f aarch64: make tftpboot work
- patch dtb to add reserved-memory stanza for the phram device to use
  (aarch64 does not accept memmap= command line option)

- patch phram driver to use memremap() instead of ioremap() as
  ioremap can't be used for system ram on arm devices
2023-10-09 19:47:57 +01:00
Daniel Barlow
dbc16edf96 don't use ttyAMA0 console on all aarch64, just qemu 2023-10-09 19:47:57 +01:00
Daniel Barlow
4df248323c use MTD_SPI_NOR_USE_4K_SECTORS only on MIPS 2023-10-07 22:41:15 +01:00
Daniel Barlow
caf8e85061 remove USE_OF from aarch64 2023-10-02 22:43:13 +01:00
Daniel Barlow
76f03ecf0f move OF and USE_OF to arch modules 2023-09-30 21:52:13 +01:00
Daniel Barlow
3a2f074199 disable 4k flash erase blocks everywhere 2023-09-27 22:10:17 +01:00
Daniel Barlow
ab147abd9b less padding in firmware.bin
we only need to align to erase block size, which may be
less than the 128k previously hard-coded
2023-09-26 16:43:03 +01:00
Daniel Barlow
c59a228955 this is the dhcp6c service we want 2023-09-26 16:43:03 +01:00
Daniel Barlow
94e51db649 tests: use run.sh instead of calling run-liminix-vm directly
this makes it easier to run tests on aarch64 where
qemu wants an Image file instead of a vmlinux
2023-09-24 00:24:48 +01:00
Daniel Barlow
be22fbbb0a bootable aarch64 liminux with qemu
I may have broken the run-liminix-vm command a bit for MIPS due to
necessary changes in how we pass the command line.  If CI isn't green
for this commit and youre trying the worked examples, I suggest
reverting to the commit before this one.
2023-09-20 22:55:51 +01:00
Daniel Barlow
4389fa15f7 rename mips-vm as run-liminix-vm 2023-09-20 18:33:20 +01:00
Daniel Barlow
4f29bdd3ed detect arch in kernel and uimage
also move kernel builder to pkgs/

FIXME we need to straighten out the mess in calling
dtb.nix/uimage.nix
2023-09-20 18:26:33 +01:00
Daniel Barlow
f1c04c7979 extract mips kernel options to module 2023-09-20 17:50:21 +01:00
Daniel Barlow
f75995e895 introduce modules/arch/{mipsel,mipseb}.nix
for settings that are common to all mipse[lb] but would not be shared
with e.g. aarch64 or x86
2023-09-20 17:30:05 +01:00
Daniel Barlow
b36272f99e add outputs for vlan service 2023-09-17 17:00:31 +01:00
Daniel Barlow
0abe4f96a7 ssh ensure we create /run/dropbear
this is required if we don't have persistent store (jffs2)
2023-09-17 17:00:26 +01:00
Daniel Barlow
4fd1b5f08b er, "input" != output" 2023-09-13 18:01:50 +01:00
Daniel Barlow
899f096346 dnsmasq static hosts defaults to empty attrset 2023-09-04 23:02:17 +01:00
Daniel Barlow
0cf4733327 add placeholders for missing module docs 2023-09-04 22:19:22 +01:00
Daniel Barlow
0a6af46364 support dhcp static leases 2023-09-04 22:08:07 +01:00
Daniel Barlow
3bdc986dd7 extract "mount filesystem" to module 2023-09-04 21:17:52 +01:00
Daniel Barlow
83092b7b73 add watchdog service 2023-09-02 17:28:40 +01:00
Daniel Barlow
7ad848cb77 add service to enable packet forwarding
might be worth looking into adding RA config to this
2023-09-01 17:34:47 +01:00
Daniel Barlow
e04ec2e959 move SWCONFIG defn into per-device files
it doesn't work on qemu
2023-08-31 23:50:07 +01:00
Daniel Barlow
d60aab728d reinstate loopback network (oops) 2023-08-31 23:29:30 +01:00
Daniel Barlow
3609d8d5ee implement route as module-based-service 2023-08-31 23:24:23 +01:00
Daniel Barlow
e577caa15f extneder: use bridge module 2023-08-31 18:29:45 +01:00
Daniel Barlow
7faf620c0b move loopback config from base to netowrk module 2023-08-31 18:28:35 +01:00
Daniel Barlow
f1dfb1f976 BRIDGE_VLAN_FILTERING depends on bridge _and_ vlan
I'm half-pleased with this. It demonstrates how we can have complex
conditional kernel config, but the way we detect if vlan exists is
tacky.
2023-08-31 18:24:09 +01:00
Daniel Barlow
333327be75 make a module for vlan
Acked-by: Daniel Barlow <<dan@telent.net>>
2023-08-30 23:26:44 +01:00
Daniel Barlow
efa1919e04 move squashfs kernel options into module 2023-08-30 22:59:28 +01:00
Daniel Barlow
de77635490 move bridge-related kernel config to the module 2023-08-30 17:29:42 +01:00
Daniel Barlow
aecbe08f08 add o+x permission on service-state directories
this is needed for resolvconf, which writes resolv.conf as
an output and wants to make it world-readable
2023-08-28 22:02:28 +01:00
Daniel Barlow
ff2d3e1a63 TODO comments 2023-08-28 22:02:28 +01:00
Daniel Barlow
e86daf9bbc default value for services.default
as a default default target, start all the services
2023-08-28 22:02:28 +01:00
Daniel Barlow
00c8ea66ea add service fir dhcp v4 client 2023-08-28 22:02:28 +01:00
Daniel Barlow
31f0213b6f convert network link/address to module-based-service
... and make bridge use it.

We also had to convert bridge back into a pair of services.
Downstreams want to depend on the bridge it self being configured
even if not necessarily all the members are up. e.g. don't want
to break ssh on lan if there's a misconfigured wlan device
2023-08-28 22:02:28 +01:00
Daniel Barlow
540a1dfd76 remove interface.device
build-time uses can mostly be replaced with interface.name

for runtime uses, switch to $(output ${interface} name)
2023-08-28 22:02:28 +01:00
Daniel Barlow
6b28f5dd79 chrony: drop privileges 2023-08-27 22:40:49 +01:00
Daniel Barlow
f4ad4d3ce1 update bridge service doc 2023-08-18 23:58:06 +01:00
Daniel Barlow
6f92f8fa8b merge bridge services into one 2023-08-16 23:29:53 +01:00
Daniel Barlow
a019e59a80 improve doc 2023-08-16 22:52:16 +01:00
Daniel Barlow
1b8536ff81 describe hostname option 2023-08-16 22:26:40 +01:00