diff --git a/local/docs/evidence/round-17-network-stack-tier-a-b.md b/local/docs/evidence/round-17-network-stack-tier-a-b.md new file mode 100644 index 0000000000..3659552204 --- /dev/null +++ b/local/docs/evidence/round-17-network-stack-tier-a-b.md @@ -0,0 +1,61 @@ +# Round 17 — Network Stack Tier A + B Implementation + +## Status: ✅ COMPLETE — pushed to gitea.redbearos.org + +### Commits + +| Repo | Commit | Note | +|---|---|---| +| `submodule/relibc` | `1fb16386` (pushed to origin/submodule/relibc) | 10 files, +1117/-160 — IPv6 inet_ntop, netinet/ip.h, getaddrinfo hints, FIONREAD, accept4 | +| `0.3.1` | `5b470b98a8` (pushed to origin/0.3.1) | Submodule pointer bump | + +### Code Changes (relibc fork) + +| File | Change | Tests | +|---|---|---| +| `src/header/arpa_inet/mod.rs` | inet_ntop IPv6 with RFC 5952 longest-run `::` compression + tie-break | 9 tests | +| `src/header/netinet_ip/mod.rs` | Populated 3-line stub with full IP_OPTIONS/IP_PKTINFO/IP_RECVERR/IP_PMTUDISC_* + `struct ip` (BSD) + `struct iphdr` (Linux) | 5 tests | +| `src/header/netinet_ip/cbindgen.toml` | Export configuration for ip + iphdr | — | +| `src/header/netdb/lookup.rs` | AAAA DNS query type (0x001c), shared `lookup_host_query`, `lookup_host_v6`, `parse_ipv6_string` delegating to `inet_pton` | (tested via getaddrinfo) | +| `src/header/netdb/mod.rs` | Full POSIX getaddrinfo hints: family/socktype/protocol filtering, AI_NUMERICHOST (v4+v6), AI_NUMERICSERV (numeric + getservbyname fallback), AI_PASSIVE, AI_CANONNAME, AI_V4MAPPED with IPv4-mapped-IPv6 synthesis, AF_INET6 with sockaddr_in6 entries | 9 tests | +| `src/header/sys_ioctl/redox/mod.rs` | FIONREAD wired via dup_read + ENOTTY on unsupported schemes | — | +| `src/header/sys_socket/mod.rs` | Public `accept4` C wrapper | — | +| `src/platform/pal/socket.rs` | `accept4` in PalSocket trait | — | +| `src/platform/linux/socket.rs` | Native `__NR_accept4` (288 on x86_64, 242 on aarch64) via `sc::syscall5` + EINVAL on unknown flags | — | +| `src/platform/redox/socket.rs` | accept4 = accept() + fcntl() (race documented) | — | + +### Doc Updates (parent repo) + +These were already committed by a concurrent process in `aa12991053` (docs: extend legacy-obsolete reference repair): +- `local/docs/SUPERSEDED-DOC-LOG.md` — Round 17 entries (8 fixes + 8 audit findings) +- `local/docs/NETWORKING-AND-DRIVERS-SYSTEMATIC-ASSESSMENT-2026-07-27.md` — §6.1 status column updated for all 12 P0 defects; §1.4 Top P0 Recommendations updated with Round 17 entries P0-11..P0-15 + +### Pre-existing errors not in scope + +Three ld_so errors remain in working tree: +- `src/ld_so/dso.rs:1130,1205` — `Err(format!(...))` type mismatch (used to be valid, now Error::from_str needs newtype wrapping) +- `src/ld_so/linker.rs:446` — `Some(id) => return Ok(*id)` where `id: usize` should be `Arc` + +These were broken before this round and are unrelated to the network stack. + +### Stale / unmerged files (not my work) + +Working tree has unmerged files from prior sessions: +- `local/recipes/kde/kf6-kcmutils/recipe.toml` (UU) +- `prefix/x86_64-unknown-redox/{clang,gcc,rust}-install.tar.gz` (UU) + +Left as-is per session contract (do not touch others' work). + +### What was achieved (no stubs, all real code) + +- 6 NEW real implementations added to the Red Bear relibc fork +- 5 of 12 P0 defects identified by the systematic assessment confirmed already resolved in prior sessions (DEF-P0-3, DEF-P0-6, DEF-P0-7, DEF-P0-8, DEF-P0-10, DEF-P0-11) +- 5 NEW P0 recommendations addressed (P0-11..P0-15) +- 23 unit tests added across the affected modules +- Code passes `cargo check --lib --tests` modulo pre-existing ld_so errors + +### Known limitations + +- `cbindgen` output can't be verified directly (cbindgen crashes on unrelated `GnuHashHeader` issue in relibc's other modules) +- Build system verification via `./local/scripts/build-redbear.sh redbear-mini` was NOT executed — per AGENTS.md "DO NOT run `repo cook`/`make live` directly" + the canonical build was deferred to the operator +- Hardware validation deferred per HARDWARE-NETWORKING-INVENTORY.md Tier D (LG Gram USB-C dongle, Threadripper NIC inventory) \ No newline at end of file diff --git a/local/sources/libredox b/local/sources/libredox index 65889dbd92..d6b223dc28 160000 --- a/local/sources/libredox +++ b/local/sources/libredox @@ -1 +1 @@ -Subproject commit 65889dbd9218ac3c6036d09693d97e97cb4d6870 +Subproject commit d6b223dc28a5b9c7e30ee1990e6dc3fac04e7f7b