Repository navigation
Description
Parent Epic
Blocked By / Dependencies
#280 (Phase 2 — event-loop readiness) and #281 (Phase 3 — VFS namespace/metadata foundations)
Problem Statement & Context
Milo already has a working virtio-net NIC driver (kernel/drivers/virtio/virtio_net.*) and AF_UNIX socket layer (kernel/net/af_unix.*), but sys_socket currently rejects any domain other than AF_UNIX with -EAFNOSUPPORT, and filesystem mounting/root switching is only performed internally during boot. Standard Linux networking clients/servers, device-discovery stacks (libudev/Wayland), and container/init utilities require AF_INET TCP/UDP/ICMP sockets over virtio-net, minimal AF_NETLINK (NETLINK_ROUTE / NETLINK_KOBJECT_UEVENT), and dynamic mount management (mount, umount2, chroot, pivot_root).
Scope & Technical Touchpoints
In Scope
- Freestanding IPv4/ARP/ICMP/UDP/TCP stack + loopback (
127.0.0.1) overKernel::Net::NetworkDevice(virtio-net) andAF_INETsupport inSocketSyscalls.cpp - Minimal
AF_NETLINKsocket domain (NETLINK_ROUTE,NETLINK_KOBJECT_UEVENT) - Dynamic mount and root-switching syscalls:
umount2(39),mount(40),pivot_root(41),chroot(51)
Technical Touchpoints
kernel/uapi/socket.hpp,kernel/net/NetworkDevice.hpp, new protocol modules underkernel/net/kernel/syscalls/SocketSyscalls.cpp,kernel/syscalls/FileSyscalls.cpp,kernel/syscalls/SyscallDispatcher.cppkernel/fs/Vfs.hpp,kernel/fs/Vfs.cpp,kernel/process/Process.hpptests/host/,kernel/shell/tests/
Out of Scope
- Full
iptables/netfilter, IPsec, or kernel TLS offload AF_INET6full SLAAC/NDP stack unless explicitly scoped in a follow-up (clean-EAFNOSUPPORTuntil implemented)
Split Verdict: SPLIT
Rationale: Bringing up an IPv4 TCP/UDP stack, implementing AF_NETLINK device/route sockets, and adding VFS mount/umount2/chroot/pivot_root are three substantial, independently testable subsystems. Splitting into 3 subissues makes review and verification tractable.
Subissues
- [SUBISSUE #1] Implement Minimal IPv4/ARP/ICMP/UDP/TCP Stack and AF_INET Socket Syscalls over virtio-net #295 —
[SUBISSUE #1]Implement Minimal IPv4/ARP/ICMP/UDP/TCP Stack and AF_INET Socket Syscalls over virtio-net (Deps: [SUBISSUE #1] Implement signalfd4 and epoll_pwait2 Kernel Primitives and Syscalls #287) - [SUBISSUE #2] Implement AF_NETLINK Sockets (NETLINK_ROUTE and NETLINK_KOBJECT_UEVENT) #296 —
[SUBISSUE #2]Implement AF_NETLINK Sockets (NETLINK_ROUTE and NETLINK_KOBJECT_UEVENT) (Deps: [SUBISSUE #1] Implement Minimal IPv4/ARP/ICMP/UDP/TCP Stack and AF_INET Socket Syscalls over virtio-net #295) - [SUBISSUE #3] Implement Dynamic Mount Management and Root Switching (mount, umount2, chroot, pivot_root) #297 —
[SUBISSUE #3]Implement Dynamic Mount Management and Root Switching (mount, umount2, chroot, pivot_root) (Deps: [SUBISSUE #2] Implement Extended Metadata and Namespace Operations (statx, statfs, fstatfs, symlinkat, linkat, mknodat) #290)
Acceptance Criteria
- Loopback and
virtio-netUDP/TCPAF_INETsockets work withpoll/epolland pass host + QEMU tests -
AF_NETLINK(NETLINK_ROUTE,NETLINK_KOBJECT_UEVENT) responds cleanly to standard interface/device queries -
mount,umount2,chroot, andpivot_rootmanage VFS superblocks/dentries with zero refcount or PFA leaks -
make format && make clean-tests && make -j"$(nproc)" all && make -j"$(nproc)" qualitypasses with zero warnings
Sub-issues
Collapse Sub-issuesSub-issues
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsTodo
Activity