Skip to content

Comments and the README no longer say the kernel writes the log through toyos-fat32 or tell a deleted syscall's history - #1224

Merged
Japabu merged 1 commit into
mainfrom
hygiene-comments
Nov 11, 2026
Merged

Japabu merged 1 commit into
mainfrom
hygiene-comments

Conversation

@Japabu

@Japabu Japabu commented Nov 11, 2026 •

Copy link
Copy Markdown
Collaborator

Two records named comments that say something false: that the kernel uses toyos-fat32, and what syscalls the ABI no longer declares used to do. This corrects the comments, corrects the same false claim in root README.md, and deletes both records. Comments and README text only; no code changes.

record action evidence
three-comments-say-the-kernel-uses-toyos-fat32 two comments corrected (build/fatformat.rs module doc, populate's doc in build/image.rs); record deleted git grep -i fat32 -- kernel finds nothing. The third comment, lib/fat32/Cargo.toml's header, was already corrected on main
comments-still-name-syscalls-the-abi-deleted three module docs cut down to what is true of the test now (abuse_connect_flood.rs, abuse_pipe_owner.rs, shm_release_reclaims.rs); record deleted. shm_release_reclaims.rs's remaining claim about handle count was false too and is corrected The record's exit git grep -w -E 'SYS_WAITPID|SYS_CONNECT|SYS_AUDIO_SUBMIT|SYS_PIPE_OPEN|SYS_SOCKET_CREATE|SYS_LISTEN|SYS_RELEASE_SHARED' -- kernel system tests finds nothing. The fourth comment, on Pipe::backing, is gone with that function. A mapping holds the region (kernel/src/object/shm.rs header), on_zero_handles revokes only an aperture, and SharedMemory::drop unmaps before its handle closes, so the doc now says a region's frames go back once its last handle and last mapping have gone

Records: 752 on main at 34cb4c918, 750 on this branch.

Decisions a reviewer may want to question

  • abuse_pipe_owner.rs loses more than the syscall names. Its second and third paragraphs described the test by contrast with the sweep it replaced ("the property that replaced it", "the sweep cannot survive the fail-fast flip"). Without the first paragraph those have no referent, so they are rewritten to state the property and why each attack is a child of its own.
  • abuse_connect_flood.rs's opening history is cut too (the queue that had no depth, the eager 2 MiB rings), to the contract its assertions hold: a connect past the depth is ResourceExhausted, a full queue costs under a quarter of eager rings, and the first byte on a live connection takes a frame.
  • Root README.md is corrected here rather than recorded. Lines 199-201 said the running kernel appends its log through its own FAT32 write path, and lines 305-306 that the kernel writes a log file per boot. logkeeper writes it (system/logkeeper/src/store.rs, through the file server). It is the same false claim the first record names.

Checks

🤖 Generated with Claude Code

@Japabu

Japabu commented Nov 11, 2026

Copy link
Copy Markdown
Collaborator Author

Review of #1224 at 7a8f3202b (base 34cb4c918)

Assessment. +20/−90. Every changed line in build/ and tests/ is a //! or /// comment; no code token changed. Both records' exits hold:

  • git grep -i fat32 -- kernel finds nothing.
  • The SYS_* exit grep, widened to sdk lib build, finds nothing.
  • Pipe::backing is gone.
  • lib/fat32/Cargo.toml's header no longer names the kernel.

The two comments in build/ are now true: toyos-fat32 has no format path (lib/fat32/src/lib.rs, "No formatting"), and refused_writes.rs judges with toyos-fat32-check. One comment the PR keeps is false, and one discovery is left unrecorded.

Findings

BLOCKER: tests/guest/rust-tests/src/bin/shm_release_reclaims.rs:3-4 keeps "A region's life is its handle count, and the zero-handle hook is where the mappings go."

  • Both halves are false.
  • kernel/src/object/shm.rs:7-11: "A mapping holds the object, and a handle holds nothing of a mapping: the object's frames go back when the last of its handles and mappings has."
  • SharedMemObject::on_zero_handles calls revoke, which returns immediately for anything but an aperture (shm.rs:312-328).
  • The SDK unmaps in SharedMemory::drop before its handle closes (sdk/toyos/src/shm.rs:162-167).
  • The PR says these docs are cut "to what is true of the test now", and this sentence is the one that is not.
  • Fix: delete it, or say that a region's frames go back once its last handle and last mapping have gone.

BLOCKER: the root README.md discovery is not recorded.

  • The PR's "Not changed" section finds the same false claim this PR closes a record for: "the running kernel then appends its log … through its own FAT32 write path" (README.md:199-201), and "the kernel writes a log file per boot" (README.md:305-306).
  • logkeeper writes the log.
  • Leaving it out of scope is fine, but root CLAUDE.md requires an unrelated discovery to be recorded, and a PR body is not the tracker.
  • Fix: file a record, or correct the two sentences.

SUGGESTION: as the PR notes, abuse_connect_flood.rs:3-16 still tells history: the queue that had no depth, the discarded bool, the eager 2 MiB rings. Root CLAUDE.md puts history in commits. Cutting it to the contract (a connect past the depth is ResourceExhausted, and a pipe takes memory only as it holds bytes) costs a few lines now.

Checked and accepted:

SEND BACK

…gh toyos-fat32 or tell a deleted syscall's history

Comments and README text only; no code changes.

The kernel's dependency on `toyos-fat32` went with its USB storage path
(13ed7b4): `git grep -i fat32 -- kernel` finds nothing. Two comments
still named the kernel as the crate's user, `build/fatformat.rs`'s module
doc and `populate`'s doc in `build/image.rs`. The third the record listed,
`lib/fat32/Cargo.toml`'s header, had already been corrected.

Root README.md said the running kernel appends its log through its own
FAT32 write path and writes a log file per boot; logkeeper does
(system/logkeeper, `store`), through the file server.

Three test binaries' module docs told what a syscall the ABI no longer
declares used to do: `SYS_LISTEN` in abuse_connect_flood, `SYS_PIPE_OPEN`
and `SYS_SOCKET_CREATE` in abuse_pipe_owner, `SYS_RELEASE_SHARED` in
shm_release_reclaims. Each now says only what is true of its test. The
fourth the record listed, the doc of `Pipe::backing` in kernel/src/pipe.rs,
is gone with that function. `git grep -w -E 'SYS_WAITPID|SYS_CONNECT|
SYS_AUDIO_SUBMIT|SYS_PIPE_OPEN|SYS_SOCKET_CREATE|SYS_LISTEN|
SYS_RELEASE_SHARED' -- kernel system tests` finds nothing.

abuse_connect_flood's opening history (the queue with no depth, the eager
2 MiB rings) is cut to the contract its assertions hold: a connect past
the depth is `ResourceExhausted`, a full queue costs under a quarter of
what eager rings would, and the first byte on a live connection takes a
frame.

shm_release_reclaims also said a region's life is its handle count and the
zero-handle hook unmaps it. Neither holds: a mapping holds the object
(kernel/src/object/shm.rs), `on_zero_handles` revokes only an aperture,
and the SDK unmaps in `SharedMemory::drop`. It now says a region's frames
go back once its last handle and last mapping have gone.

Closes issues/three-comments-say-the-kernel-uses-toyos-fat32.md and
issues/comments-still-name-syscalls-the-abi-deleted.md, which are deleted.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Japabu Japabu changed the title Comments no longer say the kernel uses toyos-fat32 or tell a deleted syscall's history Comments and the README no longer say the kernel writes the log through toyos-fat32 or tell a deleted syscall's history Nov 11, 2026
@Japabu

Japabu commented Nov 11, 2026

Copy link
Copy Markdown
Collaborator Author

Orchestrator verification at 42ffcad, after review r1's SEND BACK (comment-only blockers).

The diff against main changes no code token: every changed Rust line is a comment (checked by filtering the diff), the rest is README.md and two deleted issue records. Blocker 7 is resolved (shm_release_reclaims.rs now says a mapping keeps the region alive and the SDK unmaps before closing the handle); blocker 8 is resolved in the README (logkeeper writes the log, at both places). Clippy on toyos-build with warnings denied is clean at this head. Queueing.

@Japabu
Japabu marked this pull request as ready for review November 11, 2026 15:29
@Japabu
Japabu added this pull request to the merge queue Nov 11, 2026
Merged via the queue into main with commit f79df95 Nov 11, 2026
10 checks passed
@Japabu
Japabu deleted the hygiene-comments branch November 11, 2026 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant