/[hurd]/hurd/libnetfs/netfs.h
ViewVC logotype

Diff of /hurd/libnetfs/netfs.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.29 by marcus, Tue Jan 30 00:50:25 2001 UTC revision 1.30 by roland, Wed May 8 09:21:35 2002 UTC
# Line 1  Line 1 
1  /*  /*
2    
3     Copyright (C) 1994, 1995, 1996, 1997, 1999, 2000 Free Software Foundation     Copyright (C) 1994,95,96,97,99,2000,02 Free Software Foundation, Inc.
4    
5     This program is free software; you can redistribute it and/or     This program is free software; you can redistribute it and/or
6     modify it under the terms of the GNU General Public License as     modify it under the terms of the GNU General Public License as
# Line 25  Line 25 
25  #include <assert.h>  #include <assert.h>
26    
27  /* This library supports client-side network file system  /* This library supports client-side network file system
28     implementations.  It is analogous to the diskfs library provided for     implementations.  It is analogous to the diskfs library provided for
29     disk-based filesystems.  */     disk-based filesystems.  */
30    
31  struct argp;  struct argp;
# Line 33  struct argp; Line 33  struct argp;
33  struct protid  struct protid
34  {  {
35    struct port_info pi;    struct port_info pi;
36      
37    /* User identification */    /* User identification */
38    struct iouser *user;    struct iouser *user;
39      
40    /* Object this refers to */    /* Object this refers to */
41    struct peropen *po;    struct peropen *po;
42      
43    /* Shared memory I/O information. */    /* Shared memory I/O information. */
44    memory_object_t shared_object;    memory_object_t shared_object;
45    struct shared_io *mapped;    struct shared_io *mapped;
# Line 68  struct peropen Line 68  struct peropen
68  struct node  struct node
69  {  {
70    struct node *next, **prevp;    struct node *next, **prevp;
71      
72    /* Protocol specific stuff; defined by user.  */    /* Protocol specific stuff; defined by user.  */
73    struct netnode *nn;    struct netnode *nn;
74    
75    /* The stat information for this particular node.  */    /* The stat information for this particular node.  */
76    struct stat nn_stat;    struct stat nn_stat;
77      
78    struct mutex lock;    struct mutex lock;
79      
80    /* The number of references to this node.  */    /* The number of references to this node.  */
81    int references;    int references;
82      
83    mach_port_t sockaddr;    mach_port_t sockaddr;
84    
85    int owner;    int owner;
86      
87    struct transbox transbox;    struct transbox transbox;
88    
89    struct lock_box userlock;    struct lock_box userlock;
# Line 184  error_t netfs_attempt_syncfs (struct iou Line 184  error_t netfs_attempt_syncfs (struct iou
184     name was not found, then return ENOENT.  On any error, clear *NP.     name was not found, then return ENOENT.  On any error, clear *NP.
185     (*NP, if found, should be locked and a reference to it generated.     (*NP, if found, should be locked and a reference to it generated.
186     This call should unlock DIR no matter what.)  */     This call should unlock DIR no matter what.)  */
187  error_t netfs_attempt_lookup (struct iouser *user, struct node *dir,  error_t netfs_attempt_lookup (struct iouser *user, struct node *dir,
188                                char *name, struct node **np);                                char *name, struct node **np);
189    
190  /* The user must define this function.  Delete NAME in DIR (which is  /* The user must define this function.  Delete NAME in DIR (which is
# Line 196  error_t netfs_attempt_unlink (struct iou Line 196  error_t netfs_attempt_unlink (struct iou
196     directory FROMDIR to TODIR. Note that neither of the specific nodes     directory FROMDIR to TODIR. Note that neither of the specific nodes
197     are locked.  */     are locked.  */
198  error_t netfs_attempt_rename (struct iouser *user, struct node *fromdir,  error_t netfs_attempt_rename (struct iouser *user, struct node *fromdir,
199                                char *fromname, struct node *todir,                                char *fromname, struct node *todir,
200                                char *toname, int excl);                                char *toname, int excl);
201    
202  /* The user must define this function.  Attempt to create a new  /* The user must define this function.  Attempt to create a new
# Line 207  error_t netfs_attempt_mkdir (struct ious Line 207  error_t netfs_attempt_mkdir (struct ious
207    
208  /* The user must define this function.  Attempt to remove directory  /* The user must define this function.  Attempt to remove directory
209     named NAME in DIR (which is locked) for USER.  */     named NAME in DIR (which is locked) for USER.  */
210  error_t netfs_attempt_rmdir (struct iouser *user,  error_t netfs_attempt_rmdir (struct iouser *user,
211                               struct node *dir, char *name);                               struct node *dir, char *name);
212    
213    
# Line 309  error_t netfs_set_options (char *argz, s Line 309  error_t netfs_set_options (char *argz, s
309  /* Append to the malloced string *ARGZ of length *ARGZ_LEN a NUL-separated  /* Append to the malloced string *ARGZ of length *ARGZ_LEN a NUL-separated
310     list of the arguments to this translator.  The default definition of this     list of the arguments to this translator.  The default definition of this
311     routine simply calls netfs_append_std_options.  */     routine simply calls netfs_append_std_options.  */
312  error_t netfs_append_args (char **argz, unsigned *argz_len);  error_t netfs_append_args (char **argz, size_t *argz_len);
313    
314  /* If this is defined or set to a pointer to an argp structure, it will be  /* If this is defined or set to a pointer to an argp structure, it will be
315     used by the default netfs_set_options to handle runtime option parsing.     used by the default netfs_set_options to handle runtime option parsing.

Legend:
Removed from v.1.29  
changed lines
  Added in v.1.30

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26