From 79efd33ba0964796d4dc4653b68435755b35f834 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Fri, 30 Oct 2026 00:01:29 -0300 Subject: 9p: a mount keeps its connection and sends each operation's walk, stat, open and first read or write in one flight, a new connection's version and attach before them: an operation through it is one round trip where it was six or seven (a directory, or a file of no stated length, two: 9P's only end is an empty read); a file whose stat gave its length is read ahead, its Treads 14 at a time; reads are timed by their progress, so a large remote file opens at 80 and 207 ms (1.3 MB timed out); a write refused unopened behind a truncating open that parked is sent again after it; Unmount lets the connection go; the CLI, --wait and Handover dial afresh, pipelined; reference.typ says how a session elsewhere mounts through ssh -L Co-Authored-By: Claude Opus 5.5 --- docs/typ/reference.typ | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'docs') diff --git a/docs/typ/reference.typ b/docs/typ/reference.typ index 2e395cc6..2d8658c6 100644 --- a/docs/typ/reference.typ +++ b/docs/typ/reference.typ @@ -338,7 +338,13 @@ nothing answers (`dial failed: no answer`, `timed out`, `hung up`); with no dial it is `wrong #args`, and any other `x!y` `bad dial address`, both EINVAL. There are eight named mounts; `os` and `self` are reserved. #word("Unmount") refuses a mount a pane, a working directory or a pending -#word("Save") still uses. Mounts are dumped. +#word("Save") still uses. Mounts are dumped. A mount keeps its connection, +and sends each walk, open and first read or write together: an operation +through it costs one round trip (a directory, or a file of no stated +length, one more to see its end). A session on another machine mounts +through a forwarded socket: `ssh -C -N -L /tmp/box.sock: host`, +then #word("Mount") `box /tmp/box.sock` (`-C`: a link far away carries +fewer bytes in each round trip). A session may open its own tree through a mount (a #word("Look") of `$m/pane/2/body` from the editor serving `$m`): requests are answered on the connection's -- cgit v1.3