ReleaseHandle docs and types.

geesefs-0-30-9
Aaron Jacobs 2015-02-27 09:52:34 +11:00
parent f306589a4e
commit 3e9e5fe09d
1 changed files with 16 additions and 4 deletions

View File

@ -28,9 +28,6 @@ type FileSystem interface {
// Forget an inode ID previously issued (e.g. by LookUpInode). The kernel
// calls this when removing an inode from its internal caches.
//
// The kernel guarantees that the node ID will not be used in further calls
// to the file system (unless it is reissued by the file system).
ForgetInode(
ctx context.Context,
req *ForgetInodeRequest) (*ForgetInodeResponse, error)
@ -42,7 +39,12 @@ type FileSystem interface {
ctx context.Context,
req *OpenDirRequest) (*OpenDirResponse, error)
// XXX: Comments
// Release a previously-minted handle. The kernel calls this when there are
// no more references to an open file: all file descriptors are closed and
// all memory mappings are unmapped.
//
// The kernel guarantees that the handle ID will not be used in further calls
// to the file system (unless it is reissued by the file system).
ReleaseHandle(
ctx context.Context,
req *ReleaseHandleRequest) (*ReleaseHandleResponse, error)
@ -212,3 +214,13 @@ type OpenDirResponse struct {
// ReleaseHandle.
Handle HandleID
}
type ReleaseHandleRequest struct {
// The handle ID to be released. The kernel guarantees that this ID will not
// be used in further calls to the file system (unless it is reissued by the
// file system).
Handle HandleID
}
type ReleaseHandleResponse struct {
}