libafs: Flush vcaches in afs_shutdown
[openafs.git] / src / afs / afs_prototypes.h
index 9a340a5..efcf622 100644 (file)
@@ -11,8 +11,9 @@
 #define _AFS_PROTOTYPES_H_
 
 /* afs_analyze.c */
-extern int afs_Analyze(struct afs_conn *aconn, afs_int32 acode,
-                      struct VenusFid *afid, struct vrequest *areq,
+extern int afs_Analyze(struct afs_conn *aconn, struct rx_connection *rxconn,
+                       afs_int32 acode, struct VenusFid *afid,
+                       struct vrequest *areq,
                       int op, afs_int32 locktype, struct cell *cellp);
 
 /* afs_axscache.c */
@@ -176,20 +177,25 @@ extern afs_rwlock_t afs_xinterface;
 extern afs_rwlock_t afs_xconn;
 extern struct afs_conn *afs_Conn(struct VenusFid *afid,
                             struct vrequest *areq,
-                            afs_int32 locktype);
+                            afs_int32 locktype,
+                             struct rx_connection **rxconn);
 extern struct afs_conn *afs_ConnBySA(struct srvAddr *sap, unsigned short aport,
                                 afs_int32 acell, struct unixuser *tu,
                                 int force_if_down, afs_int32 create,
-                                afs_int32 locktype);
+                                afs_int32 locktype,
+                                struct rx_connection **rxconn);
 extern struct afs_conn *afs_ConnByMHosts(struct server *ahosts[],
                                     unsigned short aport, afs_int32 acell,
                                     struct vrequest *areq,
-                                    afs_int32 locktype);
+                                    afs_int32 locktype,
+                                    struct rx_connection **rxconn);
 extern struct afs_conn *afs_ConnByHost(struct server *aserver,
                                   unsigned short aport, afs_int32 acell,
                                   struct vrequest *areq, int aforce,
-                                  afs_int32 locktype);
-extern void afs_PutConn(struct afs_conn *ac, afs_int32 locktype);
+                                  afs_int32 locktype,
+                                  struct rx_connection **rxconn);
+extern void afs_PutConn(struct afs_conn *ac, struct rx_connection *rxconn,
+                        afs_int32 locktype);
 extern void afs_ReleaseConns(struct sa_conn_vector *tcv);
 extern void afs_ReleaseConnsUser(register struct unixuser *au);
 extern void ForceNewConnections(struct srvAddr *sap);
@@ -496,7 +502,8 @@ extern int afs_CacheStoreVCache(struct dcache **dcList, struct vcache *avc,
                                unsigned int high, unsigned int moredata,
                                afs_hyper_t *anewDV,
                                  afs_size_t *amaxStoredLength);
-extern int afs_CacheFetchProc(struct afs_conn *tc, struct osi_file *fP,
+extern int afs_CacheFetchProc(struct afs_conn *tc, struct rx_connection *rxconn,
+                                struct osi_file *fP,
                                afs_size_t abase, struct dcache *adc,
                                struct vcache *avc, afs_int32 size,
                                struct afs_FetchOutput *tsmall);
@@ -514,7 +521,7 @@ extern int afs_MemWriteBlk(struct osi_file *fP, int offset,
                           void *src, int size);
 extern int afs_MemWritevBlk(struct memCacheEntry *mceP, int offset,
                            struct iovec *iov, int nio, int size);
-extern int afs_MemWriteUIO(afs_dcache_id_t *ainode, struct uio *uioP);
+extern int afs_MemWriteUIO(struct vcache *, afs_dcache_id_t *, struct uio *);
 extern int afs_MemCacheTruncate(struct osi_file *fP,
                                int size);
 extern void shutdown_memcache(void);
@@ -1060,6 +1067,7 @@ extern struct vcache *afs_LookupVCache(struct VenusFid *afid,
                                       struct vrequest *areq,
                                       afs_int32 * cached, struct vcache *adp,
                                       char *aname);
+extern void afs_FlushAllVCaches(void);
 extern int afs_FlushVCache(struct vcache *avc, int *slept);
 extern struct vcache *afs_GetRootVCache(struct VenusFid *afid,
                                        struct vrequest *areq,
@@ -1243,8 +1251,7 @@ extern int afs_open(struct vcache **avcp, afs_int32 aflags,
 
 /* VNOPS/afs_vnop_read.c */
 extern int afs_read(struct vcache *avc, struct uio *auio,
-                   afs_ucred_t *acred, daddr_t albn,
-                   struct buf **abpp, int noLock);
+                   afs_ucred_t *acred, int noLock);
 
 extern int afs_UFSReadUIO(afs_dcache_id_t *cacheId, struct uio *tuiop);
 
@@ -1305,12 +1312,13 @@ extern int afs_readlink(OSI_VC_DECL(avc), struct uio *auio,
                        afs_ucred_t *acred);
 
 /* VNOPS/afs_vnop_write.c */
-extern int afs_MemWrite(struct vcache *avc, struct uio *auio,
-                       int aio, afs_ucred_t *acred, int noLock);
+extern int afs_write(struct vcache *avc, struct uio *auio, int aio,
+                    afs_ucred_t *acred, int noLock);
+
+extern int afs_UFSWriteUIO(struct vcache *, afs_dcache_id_t *, struct uio *);
+
 extern int afs_StoreOnLastReference(struct vcache *avc,
                                    struct vrequest *treq);
-extern int afs_UFSWrite(struct vcache *avc, struct uio *auio,
-                       int aio, afs_ucred_t *acred, int noLock);
 extern int afs_DoPartialWrite(struct vcache *avc,
                              struct vrequest *areq);
 extern int afs_closex(struct file *afd);