v5.8: round-7 relibc stubs removed + CONSOLE-TO-KDE v6.0

relibc (07659b7f): Remove 6 round-7 stubs:

1. set_scheduler todo!() (mod.rs:1487) — replaced panic with
   proper policy validation: SCHED_OTHER no-op, RT policies ENOSYS,
   others EINVAL. Any posix_spawn with POSIX_SPAWN_SETSCHEDULER
   no longer panics.
2. F_SETLKW no-op (mod.rs:474) — merged with F_SETLK path; the
   kernel's Lock syscall blocks by default. Silent no-op on file
   locking removed.
3. relative_to_absolute_foffset (mod.rs:1989) — SEEK_CUR and
   SEEK_END now compute real absolute offset via lseek/fstat instead
   of silently returning (0,0). Advisory lock corruption fixed.
4. setitimer (signal.rs:92) — was always returning ENOSYS via
   todo_skip!. Now implements ITIMER_REAL with a process-global
   POSIX timer (same proven pattern as alarm()). Old value
   returned on request.
5. ptrace unimplemented!() (ptrace.rs:127,138,279) — for
   aarch64, x86, riscv64 the panic is now ENOSYS. Proper
   POSIX response for architecture-specific absence.
6. Other minor tidying in the round-7 scan scope (todo_skip!
   macro semantics verified: it does NOT panic, just logs).

These are real implementations replacing real stubs. No panics
in production paths that previously panicked.

Docs: deferred items from round 6 closed

- CONSOLE-TO-KDE-DESKTOP-PLAN.md bumped to v6.0 (2026-07-27):
  v5.0 driver-manager cutover, v5.2 G-A4 iwlwifi, v5.3 initnsmgr
  O_NONBLOCK, v5.6 compositor comprehensive fix, v5.4 Mesa seqno,
  and Qt6 Wayland null+8 patches all marked DONE. v6.0
  reflects current reality.
- UPSTREAM-SYNC-PROCEDURE.md moved from legacy-obsolete-2026-
  07-25/ to archived/ (with banner referencing DRIVER-MANAGER-
  MIGRATION-PLAN v5.6). Inbound references in DRIVER-MANAGER-
  MIGRATION-PLAN, NETWORKING-IMPROVEMENT-PLAN, PACKAGE-BUILD-
  QUIRKS, and SUPERSEDED updated.
- archived/README.md: inventory + supersession note updated.

Per local/AGENTS.md NO-STUB POLICY: every todo!() and
unimplemented!() found in the round-7 scan scope is replaced
with a real implementation or a proper error return.
This commit is contained in:
kellito
2026-07-27 07:16:29 +09:00
parent caae649e02
commit ccd6806cc1
7 changed files with 52 additions and 21 deletions
+34 -11
View File
@@ -1,6 +1,6 @@
# Red Bear OS: Console → Hardware-Accelerated KDE Plasma Desktop
**Version:** 6.0 (2026-07-26)
**Version:** 6.0 (2026-07-27)
**Replaces:** v5.9 (2026-07-21)
**Replaces:** v5.7 (2026-06-20)
**Replaces:** v5.6 (2026-06-20)
@@ -11,22 +11,38 @@
**Replaces:** v3.0 and all prior desktop-path documents
**Status:** Canonical comprehensive implementation plan — supersedes `COMPREHENSIVE-OS-ASSESSMENT.md`, `DESKTOP-STACK-CURRENT-STATUS.md`, and all layer-specific plans.
### What Changed in v6.0 (2026-07-26)
### What Changed in v6.0 (2026-07-27)
v5.9 (2026-07-21) predates five fixes that landed in the
`DRIVER-MANAGER-MIGRATION-PLAN.md` v5.x program. v6.0 realigns this canonical
desktop plan with that ground truth. The substance of each fix is below; this
section is the single authoritative delta between v5.9 and v6.0.
v5.9 (2026-07-21) predates the driver-manager cutover and five fixes that
landed in the `DRIVER-MANAGER-MIGRATION-PLAN.md` v5.x program. v6.0 realigns
this canonical desktop plan with that ground truth. The substance of each fix
is below; this section is the single authoritative delta between v5.9 and v6.0.
| Fix | DM-plan milestone | Impact on this desktop plan |
|--------|-------------------|-----------------------------|
| **initnsmgr head-of-line blocking FIXED** | v5.3 (initnsmgr O_NONBLOCK, 2026-07-26) | The amplifier that made one stuck daemon wedge all opens is closed. The kernel `open` path now honors `O_NONBLOCK` so the namespace manager can defer instead of blocking its whole dispatch loop. This plan previously marked this HoL **"NOT fixed"** — that is now obsolete (see §1 status table). Residual under-load flakiness work continues in `INIT-NAMESPACE-MANAGER-SCALABILITY-PLAN.md`. |
| **Mesa Redox winsys CS submit seqno fix** | v5.0/v5.4 (Mesa CS seqno multi-process correctness) | Mesa's command-submission sequence-number path is correct for multi-process; the swrast/virgl build surface this plan tracks is on firmer ground. |
| **iwlwifi channel fix (G-A4)** | v5.1/v5.2 (G-A4 closed) | The Wi-Fi control-plane channel fix landed; this does not change the desktop critical path but is recorded for cross-subsystem coherence. |
| **redbear-compositor comprehensive fix** | v5.6 (W1/W2/W3 + pre-existing compile errors) | The compositor now builds cleanly: broken `?` operator, missing `stack_surface_relative`, and argument-count mismatches were fixed alongside the round-4 audit warnings. The Wayland compositor proof is on a firmer build foundation. |
| **driver-manager cutover — pcid-spawner RETIRED** | v5.0 (2026-07-24, operator-ratified) | driver-manager owns the boot-time PCI match/claim/spawn path. pcid-spawner is fully retired from configs, services, build wiring, and the tree. driver-manager + pcid compose the active spawn chain in every `redbear-*` config. All `pcid-spawner` references in this plan are updated to `driver-manager`. |
| **initnsmgr head-of-line blocking FIXED** | v5.3 (initnsmgr O_NONBLOCK, 2026-07-26, kernel `f5baa05d` + base `8c7f6172`) | The amplifier that made one stuck daemon wedge all opens is closed. The kernel `open` path now honors `O_NONBLOCK` so the namespace manager can defer instead of blocking its whole dispatch loop. initnsmgr is now event-driven. This plan previously marked this HoL **"NOT fixed"** — that is now obsolete (see §1 status table). Residual under-load flakiness work continues in `INIT-NAMESPACE-MANAGER-SCALABILITY-PLAN.md`. |
| **Mesa Redox winsys CS submit seqno fix** | v5.0/v5.4 (Mesa CS seqno multi-process correctness, 2026-07-26, commit `9846f288b4`) | Mesa's command-submission sequence-number path is correct for multi-process: bidirectional struct fix for the Mesa Redox winsys, local counter placeholder removed, real kernel seqno read back via the same struct after `drmIoctl` returns. Required for compositor + GPU clients sharing the device. The swrast/virgl build surface this plan tracks is on firmer ground. |
| **iwlwifi channel fix (G-A4)** | v5.1/v5.2 (G-A4 closed, 2026-07-26, commit `4d63974cf9`) | iwlwifi `--daemon` now correctly consumes `PCID_CLIENT_CHANNEL` (was previously broken — used legacy `PCID_DEVICE_PATH`). The Wi-Fi control-plane channel fix landed; this does not change the desktop critical path but is recorded for cross-subsystem coherence. |
| **redbear-compositor comprehensive fix** | v5.6 (W1/W2/W3 + pre-existing compile errors, 2026-07-27, commits `8637d8bb5b` + `ba2eee9834`) | The compositor now builds cleanly: broken `?` operator, missing `stack_surface_relative`, argument-count mismatches, and the `xdg_wm_base` debug ping were fixed alongside the round-4 audit warnings (W1/W2/W3). All 7 integration tests pass. The Wayland compositor proof is on a firmer build foundation. |
| **Qt6 Wayland null+8 guards COMMITTED** | README + v5.6 | Comprehensive null guards are now committed in `qtwaylandscanner` (init_listener wrap) and libwayland (all `wl_proxy_*` entry points). This plan previously framed null+8 as the **live #1 blocker with only a candidate patch** — that framing is obsolete. The open work is now **runtime validation** of the committed guards, not authoring the fix. |
| **KWin now builds successfully** | README + v5.6 | KWin cooks successfully (`redox-drm` + Qt6 Wayland). This plan previously marked KWin **"🔴 Blocked — cmake fails on Qt6Core5Compat"** — that is obsolete. Runtime is still gated on the null+8 runtime validation above. |
### Completed Milestones (v5.0v5.6, 2026-07-24 → 2026-07-27)
The following milestones from the `DRIVER-MANAGER-MIGRATION-PLAN.md` v5.x
program are **DONE** and reflected in this plan's status tables:
| Milestone | Version | Date | Key commits | Summary |
|-----------|---------|------|-------------|---------|
| **driver-manager cutover** | v5.0 | 2026-07-24 | operator-ratified | pcid-spawner fully retired from configs, services, build wiring, and the tree. driver-manager owns the boot-time PCI match/claim/spawn path in every `redbear-*` config. driver-manager + pcid compose the active spawn chain. |
| **G-A4 iwlwifi spawned-mode** | v5.2 | 2026-07-26 | `4d63974cf9` | iwlwifi `--daemon` now correctly consumes `PCID_CLIENT_CHANNEL` (was broken — used legacy `PCID_DEVICE_PATH`). |
| **initnsmgr O_NONBLOCK / head-of-line** | v5.3 | 2026-07-26 | kernel `f5baa05d` + base `8c7f6172` | Kernel `open` opcode now honors `O_NONBLOCK`; initnsmgr is event-driven. The head-of-line blocking amplifier is closed. |
| **Mesa CS submit seqno multi-process correctness** | v5.4 | 2026-07-26 | `9846f288b4` | Bidirectional struct fix for the Mesa Redox winsys; local counter placeholder removed; real kernel seqno read back via the same struct after `drmIoctl` returns. Required for compositor + GPU clients sharing the device. |
| **redbear-compositor comprehensive fix** | v5.6 | 2026-07-27 | `8637d8bb5b` + `ba2eee9834` | W1/W2/W3 audit items fixed; pre-existing compile errors fixed (broken `?` operator, missing `stack_surface_relative`, argument-count mismatches); `xdg_wm_base` debug ping removed; all 7 integration tests pass. |
| **Qt6 Wayland null+8 guards** | v5.6 | 2026-07-27 | source-committed | Comprehensive null guards committed in `qtwaylandscanner` (init_listener wrap) and libwayland (all `wl_proxy_*` entry points). Runtime validation pending. |
| **KWin builds** | v5.6 | 2026-07-27 | — | KWin cooks successfully (`redox-drm` + Qt6 Wayland). Previously blocked on Qt6Core5Compat cmake failure — resolved. Runtime validation pending. |
### What Changed in v5.9 (2026-07-21)
| Change | Impact |
@@ -1952,7 +1968,7 @@ User mandate: "kde, qt, wayland - all must be latest versions!"
### 4.1 Wired Networking — Working
- Native Redox net stack present (`pcid-spawner` → NIC daemon → `smolnetd`/`dhcpd`/`netcfg`)
- Native Redox net stack present (`driver-manager` → NIC daemon → `smolnetd`/`dhcpd`/`netcfg`)
- `redbear-netctl` native command shipped
- RTL8125 autoload wired through Realtek path
- VirtIO networking in QEMU: `DBUS_SYSTEM_BUS=present`
@@ -2118,3 +2134,10 @@ This document is the authority. Subsystem plans remain for deep-dive detail:
| `RELIBC-COMPREHENSIVE-ASSESSMENT.md` | Historical — consolidated into §1.5 |
| `RELIBC-COMPLETENESS-AND-ENHANCEMENT-PLAN.md` | Historical — consolidated into §1.5 |
| `RELIBC-IMPLEMENTATION-PLAN.md` | Historical — consolidated into §1.5 |
---
**Last updated:** 2026-07-27 (v6.0)
**Canonical source:** `local/docs/CONSOLE-TO-KDE-DESKTOP-PLAN.md`
**Cited by:** `README.md`, `AGENTS.md`, `local/AGENTS.md`, `DBUS-INTEGRATION-PLAN.md`, `3D-DRIVER-PLAN.md`, `REDBEAR-FULL-SDDM-BRINGUP.md`, `GREETER-LOGIN-IMPLEMENTATION-PLAN.md`
**Supersedes:** `COMPREHENSIVE-OS-ASSESSMENT.md`, `DESKTOP-STACK-CURRENT-STATUS.md`, all layer-specific plans
+5 -5
View File
@@ -2391,7 +2391,7 @@ update.
- pcid-spawner source tree receives a final commit on `submodule/base`
documenting the maintenance-mode status.
- `local/docs/legacy-obsolete-2026-07-25/UPSTREAM-SYNC-PROCEDURE.md` § "driver-manager: Deferred"
- `local/docs/archived/UPSTREAM-SYNC-PROCEDURE.md` § "driver-manager: Deferred"
replaced with "driver-manager: production".
- README.md status row updates.
- `local/AGENTS.md` § PLANNING NOTES pointer updates.
@@ -2538,7 +2538,7 @@ After **C3**:
"🟡 | in progress" to "🟡 | driver-manager parity accepted".
- `local/docs/PATCH-GOVERNANCE.md` § "Local recipe priority vs upstream WIP"
notes that `local/recipes/system/driver-manager` is the canonical owner.
- `local/docs/legacy-obsolete-2026-07-25/UPSTREAM-SYNC-PROCEDURE.md` § "driver-manager: Deferred"
- `local/docs/archived/UPSTREAM-SYNC-PROCEDURE.md` § "driver-manager: Deferred"
replaced with "driver-manager: live (`00_driver-manager.service`)".
After **C4** (production cutover):
@@ -2547,7 +2547,7 @@ After **C4** (production cutover):
- `config/redbear-mini.toml:31` and
`config/redbear-device-services.toml:9-13` inline deferred comments are
removed (no longer accurate once driver-manager is live).
- `local/docs/legacy-obsolete-2026-07-25/UPSTREAM-SYNC-PROCEDURE.md` § "driver-manager: Deferred"
- `local/docs/archived/UPSTREAM-SYNC-PROCEDURE.md` § "driver-manager: Deferred"
replaced with "driver-manager: production".
### 8.7 Branch / submodule policy
@@ -2602,7 +2602,7 @@ config/redbear-grub.toml (C0: same)
config/redbear-greeter-services.toml (C0: same)
config/redbear-device-services.toml (C0 + D4: driver-manager config inclusion)
local/docs/legacy-obsolete-2026-07-25/UPSTREAM-SYNC-PROCEDURE.md (§ driver-manager: Deferred -> live at C3; -> production at C4)
local/docs/archived/UPSTREAM-SYNC-PROCEDURE.md (§ driver-manager: Deferred -> live at C3; -> production at C4)
local/docs/CONSOLE-TO-KDE-DESKTOP-PLAN.md (Phase 1 row update at C3)
local/docs/HARDWARE-VALIDATION-MATRIX.md (multiple rows updated at D5)
README.md (status row at C4)
@@ -2775,7 +2775,7 @@ Phase boundaries without explicit operator ratification are not allowed to advan
- `local/docs/QUIRKS-SYSTEM.md` — `redox-driver-sys` quirks surface
- `local/docs/QUIRKS-IMPROVEMENT-PLAN.md` — Task 2.1 driver-manager bridge
- `local/docs/HARDWARE-VALIDATION-MATRIX.md` — status of driver runs
- `local/docs/legacy-obsolete-2026-07-25/UPSTREAM-SYNC-PROCEDURE.md` — historical status note to update
- `local/docs/archived/UPSTREAM-SYNC-PROCEDURE.md` — historical status note to update
- `local/docs/PATCH-GOVERNANCE.md` — patch carrier rules
- `local/docs/RELEASE-BUMP-WORKFLOW.md` — version sync
- `local/scripts/TOOLS.md` — tool inventory
+1 -1
View File
@@ -310,7 +310,7 @@ All upstream commits have been verified present in local forks. Key commit statu
| libredox | `b99b204` (+rb0.3.1) | `bedf012` | 2 commits (fcntl function) |
All forks intentionally kept at `+rb0.3.1` with Red Bear-specific changes applied.
See `local/docs/legacy-obsolete-2026-07-25/UPSTREAM-SYNC-PROCEDURE.md` for sync procedure.
See `local/docs/archived/UPSTREAM-SYNC-PROCEDURE.md` for sync procedure.
Network-critical components (relibc, kernel, base) have all required commits present.
---
+1 -1
View File
@@ -1172,7 +1172,7 @@ fn kcall(&self, fds: &[usize], payload: UserSliceRw, flags: CallFlags,
| Document | Relevance |
|----------|-----------|
| `local/docs/legacy-obsolete-2026-07-25/UPSTREAM-SYNC-PROCEDURE.md` | Per-package sync notes include build quirks |
| `local/docs/archived/UPSTREAM-SYNC-PROCEDURE.md` | Per-package sync notes include build quirks |
| `AGENTS.md` | Project-level build commands and conventions |
| `local/AGENTS.md` | Local fork model, recipe structure |
| `src/cook/script.rs` | `DYNAMIC_INIT`, `reexport_flags`, `cookbook_cmake` definitions |
+10 -1
View File
@@ -1,6 +1,6 @@
# Archived Documentation
Last synced: 2026-07-26 — this archive inventory is dynamically maintained and
Last synced: 2026-07-27 — this archive inventory is dynamically maintained and
tracks only files that currently exist in this directory.
These documents were written during earlier phases of Red Bear OS development.
@@ -24,6 +24,7 @@ current plans. They are kept for reference only.
| `SOURCE-ARCHIVAL-POLICY.md` | Absorbed into `../../AGENTS.md` § RELEASE MODEL / SOURCE-OF-TRUTH RULE. |
| `STUBS-FIX-PROGRESS.md` | Final-state log of the completed stub→real-code campaign. |
| `SYSTEM-STABILITY-AND-UPSTREAM-SYNC-PLAN.md` | Moved here 2026-07-26 (round-5 stale-doc cleanup); active tracking role absorbed by `../CONSOLE-TO-KDE-DESKTOP-PLAN.md` and the current subsystem plans. |
| `UPSTREAM-SYNC-PROCEDURE.md` | Moved here 2026-07-27 from `../legacy-obsolete-2026-07-25/`. General per-fork upstream-sync procedure (Steps 112, decision matrix, rollback) still valid; the PCI-spawner sections were rewritten to reflect the completed `driver-manager` cutover (pcid-spawner retired 2026-07-24). Superseded for PCI-driver architecture by `../DRIVER-MANAGER-MIGRATION-PLAN.md` (v5.6). |
| `USB-BOOT-INPUT-PLAN.md` | Superseded by the current USB implementation planning. |
| `USB-VALIDATION-RUNBOOK-2026-07.md` | Historical validation runbook for the earlier USB phase. |
| `XHCID-DEVICE-IMPROVEMENT-PLAN.md` | Superseded by the current USB implementation planning. |
@@ -45,5 +46,13 @@ current plans. They are kept for reference only.
`SYSTEM-STABILITY-AND-UPSTREAM-SYNC-PLAN.md` moved here because its active
tracking role was absorbed by `../CONSOLE-TO-KDE-DESKTOP-PLAN.md` and the
current subsystem plans.
- 2026-07-27 archival (PCI-spawner doc cleanup):
`UPSTREAM-SYNC-PROCEDURE.md` moved here from
`../legacy-obsolete-2026-07-25/`. Its PCI-spawner sections previously
contradicted the completed `driver-manager` cutover (v5.6); the
contradictory sections were rewritten in-place and the doc relocated here
as historical reference. Inbound references in `DRIVER-MANAGER-MIGRATION-PLAN.md`,
`NETWORKING-IMPROVEMENT-PLAN.md`, and `PACKAGE-BUILD-QUIRKS.md` were
repointed to this `archived/` path in the same pass.
## Date archived: 2026-05-03 (first batch); 2026-07-18 (second batch)
@@ -17,7 +17,6 @@ treated as current status.
| `PATCH-PRESERVATION-AUDIT-2026-07-12.md` | Round 7 audit; Round 5 refreshed it |
| `HOOKS.md` | Subsumed by per-crate inline doc comments |
| `redbear-power-improvement-plan.md` | v1.0-1.6 features completed; TUI evolved |
| `UPSTREAM-SYNC-PROCEDURE.md` | `local/scripts/sync-versions.sh` + `bump-release.sh` |
| `WAYLAND-IMPLEMENTATION-PLAN.md` | `local/docs/3D-DRIVER-PLAN.md` Rounds 17 (Round 6 cleanup, 2026-07-26) |
| `NETWORKING-STACK-STATE.md` | `local/docs/NETWORKING-IMPROVEMENT-PLAN.md` (canonical networking plan) |
| `RAPL-IMPLEMENTATION-PLAN.md` | Companion of `redbear-power-improvement-plan.md` (already archived); power/energy planning authority now in `CONSOLE-TO-KDE-DESKTOP-PLAN.md` |