OpenAFS
OpenAFS distributed network file system
/cygdrive/c/src/openafs/openafs.git/repo/src/ubik/ubik.p.h
00001 /*
00002  * Copyright 2000, International Business Machines Corporation and others.
00003  * All Rights Reserved.
00004  *
00005  * This software has been released under the terms of the IBM Public
00006  * License.  For details, see the LICENSE file in the top-level source
00007  * directory or online at http://www.openafs.org/dl/license10.html
00008  */
00009 
00010 #ifndef UBIK_H
00011 #define UBIK_H
00012 
00013 #include <stdarg.h>
00014 
00015 #include <ubik_int.h>
00016 
00018 #define UBIK_READTRANS      0
00019 #define UBIK_WRITETRANS     1
00020 /*\}*/
00021 
00023 #define LOCKREAD            1
00024 #define LOCKWRITE           2
00025 #define LOCKWAIT            3
00026 /*\}*/
00027 
00029 #define UPUBIKONLY          1   
00030 #define UBIK_CALL_NEW       2   
00031 /*\}*/
00032 
00034 #define VOTE_SERVICE_ID     50
00035 #define DISK_SERVICE_ID     51
00036 #define USER_SERVICE_ID     52  
00037 /*\}*/
00038 
00039 #define UBIK_MAGIC      0x354545
00040 
00042 #define MAXSERVERS          20  
00043 /*\}*/
00044 
00046 #define vcmp(a,b) ((a).epoch == (b).epoch? ((a).counter - (b).counter) : ((a).epoch - (b).epoch))
00047 
00049 #define CFLastFailed        1   
00050 /*\}*/
00051 
00052 #ifdef AFS_PTHREAD_ENV
00053 #include <pthread.h>
00054 #else
00055 #include <lwp.h>
00056 #endif
00057 
00061 struct ubik_client {
00062     short initializationState;  
00063     short states[MAXSERVERS];   
00064     struct rx_connection *conns[MAXSERVERS];
00065     afs_int32 syncSite;
00066 #ifdef AFS_PTHREAD_ENV
00067     pthread_mutex_t cm;
00068 #endif
00069 };
00070 
00071 #ifdef AFS_PTHREAD_ENV
00072 #define LOCK_UBIK_CLIENT(client) MUTEX_ENTER(&client->cm)
00073 #define UNLOCK_UBIK_CLIENT(client) MUTEX_EXIT(&client->cm)
00074 #else
00075 #define LOCK_UBIK_CLIENT(client)
00076 #define UNLOCK_UBIK_CLIENT(client)
00077 #endif
00078 
00079 #define ubik_GetRPCConn(astr,aindex)    ((aindex) >= MAXSERVERS? 0 : (astr)->conns[aindex])
00080 #define ubik_GetRPCHost(astr,aindex)    ((aindex) >= MAXSERVERS? 0 : (astr)->hosts[aindex])
00081 
00085 struct ubik_hdr {
00086     afs_int32 magic;            
00087     short pad1;                 
00088     short size;                 
00089     struct ubik_version version;        
00090 };
00091 
00095 struct ubik_trans {
00096     struct ubik_dbase *dbase;   
00097     struct ubik_trans *next;    
00098     afs_int32 locktype;         
00099     struct ubik_trunc *activeTruncs;    
00100     struct ubik_tid tid;        
00101     afs_int32 minCommitTime;    
00102     afs_int32 seekFile;         
00103     afs_int32 seekPos;          
00104     short flags;                
00105     char type;                  
00106     iovec_wrt iovec_info;
00107     iovec_buf iovec_data;
00108 };
00109 
00113 struct ubik_trunc {
00114     struct ubik_trunc *next;
00115     afs_int32 file;             
00116     afs_int32 length;           
00117 };
00118 
00119 struct ubik_stat {
00120     afs_int32 size;
00121     afs_int32 mtime;
00122 };
00123 
00124 #if defined(UKERNEL)
00125 #include "afs/lock.h"
00126 #else /* defined(UKERNEL) */
00127 #include <lock.h>               /* just to make sure we've got this */
00128 #endif /* defined(UKERNEL) */
00129 
00136 struct ubik_dbase {
00137     char *pathName;             
00138     struct ubik_trans *activeTrans;     
00139     struct ubik_version version;        
00140 #ifdef AFS_PTHREAD_ENV
00141     pthread_mutex_t versionLock;        
00142 #elif defined(UKERNEL)
00143     struct afs_lock versionLock;        
00144 #else                           /* defined(UKERNEL) */
00145     struct Lock versionLock;    
00146 #endif                          /* defined(UKERNEL) */
00147     afs_int32 tidCounter;       
00148     afs_int32 writeTidCounter;  
00149     afs_int32 flags;            
00150     /* physio procedures */
00151     int (*read) (struct ubik_dbase * adbase, afs_int32 afile, void *abuffer,
00152                  afs_int32 apos, afs_int32 alength);
00153     int (*write) (struct ubik_dbase * adbase, afs_int32 afile, void *abuffer,
00154                   afs_int32 apos, afs_int32 alength);
00155     int (*truncate) (struct ubik_dbase * adbase, afs_int32 afile,
00156                      afs_int32 asize);
00157     int (*sync) (struct ubik_dbase * adbase, afs_int32 afile);
00158     int (*stat) (struct ubik_dbase * adbase, afs_int32 afid,
00159                  struct ubik_stat * astat);
00160     void (*open) (struct ubik_dbase * adbase, afs_int32 afid);
00161     int (*setlabel) (struct ubik_dbase * adbase, afs_int32 afile, struct ubik_version * aversion);      
00162     int (*getlabel) (struct ubik_dbase * adbase, afs_int32 afile, struct ubik_version * aversion);      
00163     int (*getnfiles) (struct ubik_dbase * adbase);      
00164     short readers;              
00165     struct ubik_version cachedVersion;  
00166 #ifdef UKERNEL
00167     struct afs_lock cache_lock;
00168 #else
00169     struct Lock cache_lock; 
00170 #endif
00171 #ifdef AFS_PTHREAD_ENV
00172     pthread_cond_t version_cond;    
00173     pthread_cond_t flags_cond;      
00174 #endif
00175 };
00176 
00186 typedef int (*ubik_updatecache_func) (struct ubik_trans *atrans, void *rock);
00187 
00189 extern int (*ubik_CRXSecurityProc) (void *, struct rx_securityClass **,
00190                                     afs_int32 *);
00191 extern void *ubik_CRXSecurityRock;
00192 extern int (*ubik_SRXSecurityProc) (void *, struct rx_securityClass **,
00193                                     afs_int32 *);
00194 extern void *ubik_SRXSecurityRock;
00195 extern int (*ubik_CheckRXSecurityProc) (void *, struct rx_call *);
00196 extern void *ubik_CheckRXSecurityRock;
00197 
00198 extern void ubik_SetClientSecurityProcs(int (*scproc)(void *,
00199                                                       struct rx_securityClass **,
00200                                                       afs_int32 *),
00201                                         int (*checkproc) (void *),
00202                                         void *rock);
00203 extern void ubik_SetServerSecurityProcs
00204                 (void (*buildproc) (void *,
00205                                     struct rx_securityClass ***,
00206                                     afs_int32 *),
00207                  int (*checkproc) (void *, struct rx_call *),
00208                  void *rock);
00209 
00210 /*\}*/
00211 
00212 /*
00213  * For applications that make use of ubik_BeginTransReadAnyWrite, writing
00214  * processes must not update the application-level cache as they write,
00215  * or else readers can read the new cache before the data is committed to
00216  * the db. So, when a commit occurs, the cache must be updated right then.
00217  * If set, this function will be called during commits of write transactions,
00218  * to update the application-level cache after a write. This will be called
00219  * immediately after the local disk commit succeeds, and it will be called
00220  * with a lock held that prevents other threads from reading from the cache
00221  * or the db in general.
00222  *
00223  * Note that this function MUST be set in order to make use of
00224  * ubik_BeginTransReadAnyWrite.
00225  */
00226 extern int (*ubik_SyncWriterCacheProc) (void);
00227 
00228 /****************INTERNALS BELOW ****************/
00229 
00230 #ifdef UBIK_INTERNALS
00231 
00232 #define UBIK_PAGESIZE       1024        
00233 #define UBIK_LOGPAGESIZE    10  
00234 #define NBUFFERS            20  
00235 #define HDRSIZE             64  
00236 /*\}*/
00237 
00239 #define DBWRITING           1   
00240 /*\}*/
00241 
00243 #define TRDONE              1   
00244 #define TRABORT             2   
00245 #define TRREADANY           4   
00246 #define TRCACHELOCKED       32  
00249 #define TRREADWRITE         64  
00251 /*\}*/
00252 
00254 #define LWANT               1
00255 /*\}*/
00256 
00258 #define LOGFILE             (-1)
00259 /*\}*/
00260 
00262 #define LOGNEW              100 
00263 #define LOGEND              101 
00264 #define LOGABORT            102 
00265 #define LOGDATA             103 
00266 #define LOGTRUNCATE         104 
00267 /*\}*/
00268 
00279 #define MAXSKEW 10
00280 #define POLLTIME 15
00281 #define RPCTIMEOUT 20
00282 #define BIGTIME 75
00283 #define SMALLTIME 60
00284 /*\}*/
00285 
00289 struct ubik_server {
00290     struct ubik_server *next;   
00291     afs_uint32 addr[UBIK_MAX_INTERFACE_ADDR];   
00292     afs_int32 lastVoteTime;     
00293     afs_int32 lastBeaconSent;   
00294     struct ubik_version version;        
00295     struct rx_connection *vote_rxcid;   
00296     struct rx_connection *disk_rxcid;   
00297     char lastVote;              
00298     char up;                    
00299     char beaconSinceDown;       
00300     char currentDB;             
00301     char magic;                 
00302     char isClone;               
00303 };
00304 
00306 #ifdef AFS_PTHREAD_ENV
00307 # define        DBHOLD(a)       MUTEX_ENTER(&((a)->versionLock))
00308 # define        DBRELE(a)       MUTEX_EXIT(&((a)->versionLock))
00309 #else /* !AFS_PTHREAD_ENV */
00310 # define        DBHOLD(a)       ObtainWriteLock(&((a)->versionLock))
00311 # define        DBRELE(a)       ReleaseWriteLock(&((a)->versionLock))
00312 #endif /* !AFS_PTHREAD_ENV */
00313 /*\}*/
00314 
00315 /* globals */
00316 
00318 extern struct ubik_server *ubik_servers;
00319 extern char amIClone;
00320 /*\}*/
00321 
00323 extern short ubik_callPortal;
00324 /*\}*/
00325 
00327 #define UBIK_RECSYNCSITE        1       /* am sync site */
00328 #define UBIK_RECFOUNDDB         2       /* found acceptable dbase from quorum */
00329 #define UBIK_RECHAVEDB          4       /* fetched best dbase */
00330 #define UBIK_RECLABELDB         8       /* relabelled dbase */
00331 #define UBIK_RECSENTDB          0x10    /* sent best db to *everyone* */
00332 #define UBIK_RECSBETTER         UBIK_RECLABELDB /* last state */
00333 /*\}*/
00334 
00335 extern afs_int32 ubik_quorum;   /* min hosts in quorum */
00336 extern struct ubik_dbase *ubik_dbase;   /* the database handled by this server */
00337 extern afs_uint32 ubik_host[UBIK_MAX_INTERFACE_ADDR];   /* this host addr, in net order */
00338 extern int ubik_amSyncSite;     /* sleep on this waiting to be sync site */
00339 extern struct ubik_stats {      /* random stats */
00340     afs_int32 escapes;
00341 } ubik_stats;
00342 extern afs_int32 urecovery_state;       /* sync site recovery process state */
00343 extern struct ubik_trans *ubik_currentTrans;    /* current trans */
00344 extern afs_int32 ubik_debugFlag;        /* ubik debug flag */
00345 extern int ubikPrimaryAddrOnly; /* use only primary address */
00346 
00347 /*
00348  * Lock ordering
00349  *
00350  * Any of the locks may be acquired singly; when acquiring multiple locks, they
00351  * should be acquired in the listed order:
00352  *      application cache lock  (dbase->cache_lock)
00353  *      database lock           DBHOLD/DBRELE
00354  *      beacon lock             UBIK_BEACON_LOCK/UNLOCK
00355  *      vote lock               UBIK_VOTE_LOCK/UNLOCK
00356  *      version lock            UBIK_VERSION_LOCK/UNLOCK
00357  *      server address lock     UBIK_ADDR_LOCK/UNLOCK
00358  */
00359 
00369 struct beacon_data {
00370 #ifdef AFS_PTHREAD_ENV
00371     pthread_mutex_t beacon_lock;
00372 #endif
00373     int ubik_amSyncSite;                
00374     afs_int32 syncSiteUntil;            
00375 };
00376 
00377 #define UBIK_BEACON_LOCK MUTEX_ENTER(&beacon_globals.beacon_lock)
00378 #define UBIK_BEACON_UNLOCK MUTEX_EXIT(&beacon_globals.beacon_lock)
00379 
00383 struct vote_data {
00384 #ifdef AFS_PTHREAD_ENV
00385     pthread_mutex_t vote_lock;
00386 #endif
00387     struct ubik_version ubik_dbVersion; /* sync site's dbase version */
00388     struct ubik_tid ubik_dbTid;         /* sync site's tid, or 0 if none */
00389     /* Used by all sites in nominating new sync sites */
00390     afs_int32 ubik_lastYesTime;         /* time we sent the last yes vote */
00391     afs_uint32 lastYesHost;             /* host to which we sent yes vote */
00392     /* Next is time sync site began this vote: guarantees sync site until this + SMALLTIME */
00393     afs_int32 lastYesClaim;
00394     int lastYesState;                   /* did last site we voted for claim to be sync site? */
00395     /* Used to guarantee that nomination process doesn't loop */
00396     afs_int32 lowestTime;
00397     afs_uint32 lowestHost;
00398     afs_int32 syncTime;
00399     afs_int32 syncHost;
00400 };
00401 
00402 #define UBIK_VOTE_LOCK MUTEX_ENTER(&vote_globals.vote_lock)
00403 #define UBIK_VOTE_UNLOCK MUTEX_EXIT(&vote_globals.vote_lock)
00404 
00412 struct addr_data {
00413 #ifdef AFS_PTHREAD_ENV
00414     pthread_mutex_t addr_lock;
00415 #endif
00416     afs_int32 ubikSecIndex;
00417     struct rx_securityClass *ubikSecClass;
00418 };
00419 
00420 #define UBIK_ADDR_LOCK MUTEX_ENTER(&addr_globals.addr_lock)
00421 #define UBIK_ADDR_UNLOCK MUTEX_EXIT(&addr_globals.addr_lock)
00422 
00427 struct version_data {
00428 #ifdef AFS_PTHREAD_ENV
00429     pthread_mutex_t version_lock;
00430 #endif
00431     afs_int32 ubik_epochTime;   /* time when this site started */
00432 };
00433 
00434 #define UBIK_VERSION_LOCK MUTEX_ENTER(&version_globals.version_lock)
00435 #define UBIK_VERSION_UNLOCK MUTEX_EXIT(&version_globals.version_lock)
00436 
00437 /* phys.c */
00438 extern int uphys_stat(struct ubik_dbase *adbase, afs_int32 afid,
00439                       struct ubik_stat *astat);
00440 extern int uphys_read(struct ubik_dbase *adbase, afs_int32 afile,
00441                       void *abuffer, afs_int32 apos,
00442                       afs_int32 alength);
00443 extern int uphys_write(struct ubik_dbase *adbase, afs_int32 afile,
00444                        void *abuffer, afs_int32 apos,
00445                        afs_int32 alength);
00446 extern int uphys_truncate(struct ubik_dbase *adbase, afs_int32 afile,
00447                           afs_int32 asize);
00448 extern int uphys_getnfiles(struct ubik_dbase *adbase);
00449 extern int uphys_getlabel(struct ubik_dbase *adbase, afs_int32 afile,
00450                           struct ubik_version *aversion);
00451 extern int uphys_setlabel(struct ubik_dbase *adbase, afs_int32 afile,
00452                           struct ubik_version *aversion);
00453 extern int uphys_sync(struct ubik_dbase *adbase, afs_int32 afile);
00454 extern void uphys_invalidate(struct ubik_dbase *adbase,
00455                              afs_int32 afid);
00456 
00458 extern int urecovery_ResetState(void);
00459 extern int urecovery_LostServer(struct ubik_server *server);
00460 extern int urecovery_AllBetter(struct ubik_dbase *adbase,
00461                                int areadAny);
00462 extern int urecovery_AbortAll(struct ubik_dbase *adbase);
00463 extern int urecovery_CheckTid(struct ubik_tid *atid, int abortalways);
00464 extern int urecovery_Initialize(struct ubik_dbase *adbase);
00465 extern void *urecovery_Interact(void *);
00466 extern int DoProbe(struct ubik_server *server);
00467 /*\}*/
00468 
00470 extern afs_int32 ContactQuorum_NoArguments(afs_int32 (*proc)
00471                                                        (struct rx_connection *,
00472                                                         ubik_tid *),
00473                                            struct ubik_trans *atrans,
00474                                            int aflags);
00475 
00476 extern afs_int32 ContactQuorum_DISK_Lock(struct ubik_trans *atrans,
00477                                          int aflags,
00478                                          afs_int32 file, afs_int32 position,
00479                                          afs_int32 length, afs_int32 type);
00480 
00481 extern afs_int32 ContactQuorum_DISK_Write(struct ubik_trans *atrans,
00482                                           int aflags,
00483                                           afs_int32 file, afs_int32 position,
00484                                           bulkdata *data);
00485 
00486 extern afs_int32 ContactQuorum_DISK_Truncate(struct ubik_trans *atrans,
00487                                              int aflags,
00488                                              afs_int32 file, afs_int32 length);
00489 
00490 extern afs_int32 ContactQuorum_DISK_WriteV(struct ubik_trans *atrans,
00491                                            int aflags,
00492                                            iovec_wrt * io_vector,
00493                                            iovec_buf *io_buffer);
00494 
00495 extern afs_int32 ContactQuorum_DISK_SetVersion(struct ubik_trans *atrans,
00496                                                int aflags,
00497                                                ubik_version *OldVersion,
00498                                                ubik_version *NewVersion);
00499 
00500 extern void panic(char *format, ...)
00501     AFS_ATTRIBUTE_FORMAT(__printf__, 1, 2);
00502 
00503 extern afs_uint32 ubikGetPrimaryInterfaceAddr(afs_uint32 addr);
00504 
00505 extern int ubik_CheckAuth(struct rx_call *);
00506 
00507 /*\}*/
00508 
00510 struct afsconf_cell;
00511 extern void ubeacon_InitSecurityClass(void);
00512 extern void ubeacon_ReinitServer(struct ubik_server *ts);
00513 extern void ubeacon_Debug(struct ubik_debug *aparm);
00514 extern int ubeacon_AmSyncSite(void);
00515 extern int ubeacon_InitServerListByInfo(afs_uint32 ame,
00516                                         struct afsconf_cell *info,
00517                                         char clones[]);
00518 extern int ubeacon_InitServerList(afs_uint32 ame, afs_uint32 aservers[]);
00519 extern void *ubeacon_Interact(void *);
00520 extern int ubeacon_updateUbikNetworkAddress(afs_uint32 ubik_host[]);
00521 extern struct beacon_data beacon_globals;
00522 extern struct addr_data addr_globals;
00523 
00524 /*\}*/
00525 
00527 extern int udisk_Init(int nBUffers);
00528 extern void udisk_Debug(struct ubik_debug *aparm);
00529 extern int udisk_Invalidate(struct ubik_dbase *adbase, afs_int32 afid);
00530 extern int udisk_read(struct ubik_trans *atrans, afs_int32 afile,
00531                       void *abuffer, afs_int32 apos, afs_int32 alen);
00532 extern int udisk_truncate(struct ubik_trans *atrans, afs_int32 afile,
00533                           afs_int32 alength);
00534 extern int udisk_write(struct ubik_trans *atrans, afs_int32 afile,
00535                        void *abuffer, afs_int32 apos, afs_int32 alen);
00536 extern int udisk_begin(struct ubik_dbase *adbase, int atype,
00537                        struct ubik_trans **atrans);
00538 extern int udisk_commit(struct ubik_trans *atrans);
00539 extern int udisk_abort(struct ubik_trans *atrans);
00540 extern int udisk_end(struct ubik_trans *atrans);
00541 /*\}*/
00542 
00544 extern void ulock_Init(void);
00545 extern int  ulock_getLock(struct ubik_trans *atrans, int atype, int await);
00546 extern void ulock_relLock(struct ubik_trans *atrans);
00547 extern void ulock_Debug(struct ubik_debug *aparm);
00548 /*\}*/
00549 
00551 extern int uvote_ShouldIRun(void);
00552 extern afs_int32 uvote_GetSyncSite(void);
00553 extern int uvote_Init(void);
00554 extern void ubik_vprint(const char *format, va_list ap)
00555     AFS_ATTRIBUTE_FORMAT(__printf__, 1, 0);
00556 
00557 extern void ubik_print(const char *format, ...)
00558     AFS_ATTRIBUTE_FORMAT(__printf__, 1, 2);
00559 
00560 extern void ubik_dprint(const char *format, ...)
00561     AFS_ATTRIBUTE_FORMAT(__printf__, 1, 2);
00562 
00563 extern void ubik_dprint_25(const char *format, ...)
00564     AFS_ATTRIBUTE_FORMAT(__printf__, 1, 2);
00565 extern struct vote_data vote_globals;
00566 extern void uvote_set_dbVersion(struct ubik_version);
00567 extern int uvote_eq_dbVersion(struct ubik_version);
00568 extern int uvote_HaveSyncAndVersion(struct ubik_version);
00569 /*\}*/
00570 
00571 #endif /* UBIK_INTERNALS */
00572 
00573 extern afs_int32 ubik_nBuffers;
00574 
00580 struct afsconf_cell;
00581 extern int ubik_ServerInitByInfo(afs_uint32 myHost, short myPort,
00582                                  struct afsconf_cell *info, char clones[],
00583                                  const char *pathName,
00584                                  struct ubik_dbase **dbase);
00585 extern int ubik_ServerInit(afs_uint32 myHost, short myPort,
00586                            afs_uint32 serverList[],
00587                            const char *pathName, struct ubik_dbase **dbase);
00588 extern int ubik_BeginTrans(struct ubik_dbase *dbase,
00589                            afs_int32 transMode, struct ubik_trans **transPtr);
00590 extern int ubik_BeginTransReadAny(struct ubik_dbase *dbase,
00591                                   afs_int32 transMode,
00592                                   struct ubik_trans **transPtr);
00593 extern int ubik_BeginTransReadAnyWrite(struct ubik_dbase *dbase,
00594                                        afs_int32 transMode,
00595                                        struct ubik_trans **transPtr);
00596 extern int ubik_AbortTrans(struct ubik_trans *transPtr);
00597 
00598 extern int ubik_EndTrans(struct ubik_trans *transPtr);
00599 extern int ubik_Read(struct ubik_trans *transPtr, void *buffer,
00600                      afs_int32 length);
00601 extern int ubik_Flush(struct ubik_trans *transPtr);
00602 extern int ubik_Write(struct ubik_trans *transPtr, void *buffer,
00603                       afs_int32 length);
00604 extern int ubik_Seek(struct ubik_trans *transPtr, afs_int32 fileid,
00605                      afs_int32 position);
00606 extern int ubik_Tell(struct ubik_trans *transPtr, afs_int32 * fileid,
00607                      afs_int32 * position);
00608 extern int ubik_Truncate(struct ubik_trans *transPtr,
00609                          afs_int32 length);
00610 extern int ubik_SetLock(struct ubik_trans *atrans, afs_int32 apos,
00611                         afs_int32 alen, int atype);
00612 extern int ubik_WaitVersion(struct ubik_dbase *adatabase,
00613                             struct ubik_version *aversion);
00614 extern int ubik_GetVersion(struct ubik_trans *atrans,
00615                            struct ubik_version *avers);
00616 extern int ubik_CheckCache(struct ubik_trans *atrans,
00617                            ubik_updatecache_func check,
00618                            void *rock);
00619 extern struct version_data version_globals;
00620 /*\}*/
00621 
00624 extern int ubik_ParseClientList(int argc, char **argv, afs_uint32 * aothers);
00625 extern unsigned int afs_random(void);
00626 extern int ubik_ClientInit(struct rx_connection **serverconns,
00627                            struct ubik_client **aclient);
00628 extern afs_int32 ubik_ClientDestroy(struct ubik_client *aclient);
00629 extern struct rx_connection *ubik_RefreshConn(struct rx_connection *tc);
00630 #ifdef UBIK_LEGACY_CALLITER
00631 extern afs_int32 ubik_CallIter(int (*aproc) (), struct ubik_client *aclient,
00632                                afs_int32 aflags, int *apos, long p1, long p2,
00633                                long p3, long p4, long p5, long p6, long p7,
00634                                long p8, long p9, long p10, long p11, long p12,
00635                                long p13, long p14, long p15, long p16);
00636 extern afs_int32 ubik_Call_New(int (*aproc) (), struct ubik_client
00637                                *aclient, afs_int32 aflags, long p1, long p2,
00638                                long p3, long p4, long p5, long p6, long p7,
00639                                long p8, long p9, long p10, long p11, long p12,
00640                                long p13, long p14, long p15, long p16);
00641 #endif
00642 /*\}*/
00643 
00644 /* \name ubikcmd.c */
00645 extern int ubik_ParseServerList(int argc, char **argv, afs_uint32 *ahost,
00646                                 afs_uint32 *aothers);
00647 /*\}*/
00648 
00649 /* \name uinit.c */
00650 
00651 struct rx_securityClass;
00652 struct afsconf_dir;
00653 extern int ugen_ClientInitCell(struct afsconf_dir *dir,
00654                                struct afsconf_cell *info,
00655                                int secFlags,
00656                                struct ubik_client **uclientp,
00657                                int maxservers, const char *serviceid,
00658                                int deadtime);
00659 extern int ugen_ClientInitServer(const char *confDir, char *cellName,
00660                                  int secFlags, struct ubik_client **uclientp,
00661                                  int maxservers, char *serviceid,
00662                                  int deadtime, afs_uint32 server,
00663                                  afs_uint32 port);
00664 extern int ugen_ClientInitFlags(const char *confDir, char *cellName,
00665                                 int secFlags, struct ubik_client **uclientp,
00666                                 int (*secproc) (struct rx_securityClass *,
00667                                                 afs_int32),
00668                                 int maxservers, char *serviceid,
00669                                 int deadtime);
00670 extern afs_int32 ugen_ClientInit(int noAuthFlag, const char *confDir,
00671                                  char *cellName, afs_int32 sauth,
00672                                  struct ubik_client **uclientp,
00673                                  int (*secproc) (struct rx_securityClass *sc,
00674                                                  afs_int32 scIndex),
00675                                  char *funcName,
00676                                  afs_int32 gen_rxkad_level,
00677                                  afs_int32 maxservers, char *serviceid,
00678                                  afs_int32 deadtime, afs_uint32 server,
00679                                  afs_uint32 port, afs_int32 usrvid);
00680 
00681 #endif /* UBIK_H */
 All Data Structures Files Functions Variables