From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: To: 9fans@cse.psu.edu Subject: Re: [9fans] Re: 9P, procedure calls, kernel, confusion. :( From: Charles Forsyth Date: Tue, 5 Feb 2008 16:41:24 +0000 In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Topicbox-Message-UUID: 46d6ae76-ead3-11e9-9d60-3106f5b1d025 > 9P is used universally in plan9 to deal with files. If the file is > present in the kernel resident file system, then a direct procedure > call is enough, else, the mount driver comes into picture. > If its in the kernel resident file system, then the channel of the > file is looked up for the Dev structure (the device driver > corresponding to the file being referred to by the channel) , which > defines all those procedures, that may be finally executed. yes, that seems fine. conventional device drivers are the main file servers that are built-in, but there are others. if you look at section 3 of the programmer's manual you'll see a representative set. notably, in plan 9, none of them deal with files on discs etc. that's all done by user-level servers, which are typically found in section 4 of the manual. >there is no client-side caching in the plan 9 kernel. see bind(2): Finally, the MCACHE flag, valid for mount only, turns on caching for files made available by the mount. By default, file contents are always retrieved from the server. With caching enabled, the kernel may instead use a local cache to satisfy read(5) requests for files accessible through this mount point. The currency of cached data for a file is ver- ified at each open(5) of the file from this client machine.