diff options
| author | Jacob McDonnell <jacob@jacobmcdonnell.com> | 2026-04-26 16:38:00 -0400 |
|---|---|---|
| committer | Jacob McDonnell <jacob@jacobmcdonnell.com> | 2026-04-26 16:38:00 -0400 |
| commit | 97d5c458cfa039d857301e1ca7d5af3beb37131d (patch) | |
| tree | b460cd850d0537eb71806ba30358840377b27688 /static/plan9-4e/man3/0intro.3 | |
| parent | b89dc2331a50c63f8b33272a5c4c61ab98abdaa3 (diff) | |
build: Better Build System
Diffstat (limited to 'static/plan9-4e/man3/0intro.3')
| -rw-r--r-- | static/plan9-4e/man3/0intro.3 | 92 |
1 files changed, 92 insertions, 0 deletions
diff --git a/static/plan9-4e/man3/0intro.3 b/static/plan9-4e/man3/0intro.3 new file mode 100644 index 00000000..a1b30193 --- /dev/null +++ b/static/plan9-4e/man3/0intro.3 @@ -0,0 +1,92 @@ +.TH INTRO 3 +.SH NAME +intro \- introduction to the Plan 9 devices +.SH DESCRIPTION +A Plan 9 +.I device +implements a file tree for client processes. +A file name beginning with a pound sign, such as +.LR #c , +names the root of a file tree implemented by +a particular +.IR "kernel device driver" +identified by the character after the pound sign. +Such names are usually bound to conventional locations +in the name space. +For example, after +.IP +.EX +bind("#c", "/dev", MREPL) +.EE +.LP +an +.IR ls (1) +of +.B /dev +will list the files provided by the +.I console +device. +.PP +A kernel device driver is a +.I server +in the sense of the Plan 9 File Protocol, 9P (see Section 5), +but with the messages implemented by local +rather than remote procedure calls. +Also, several of the messages +.RI ( Nop , +.IR Session , +.IR Flush , +and +.IR Error ) +have no subroutine equivalents. +.PP +When a system call is passed a file name beginning with +.L "#" +it looks at the next character, and if that is a valid +.I device character +it performs an +.IR attach (5) +on the corresponding device to get a channel representing the +root of that device's file tree. +If there are any characters after the device character but +before the next +.L "/" +or end of string, those characters are passed as parameter +.I aname +to the attach. For example, +.IP +.EX +#I2 +.EE +.PP +identifies the number 2 IP protocol stack +(see +.IR ip (3)). +.PP +Each kernel device has a conventional place at which to be bound +to the name space. +The +.I SYNOPSIS +sections of the following pages includes a +.I bind +command to put the device in the conventional place. +Most of these binds are done automatically by +.IR init (8) +using +.B newns +(see +.IR auth (2)) +on the file +.B /lib/namespace +(see +.IR namespace (6)). +When typed to +.IR rc (1), +the +.I bind +commands will need quotes to protect the +.B # +characters. +.SH SEE ALSO +.IR intro (5), +.IR intro (2) |
