2 * Copyright 2000, International Business Machines Corporation and others.
5 * This software has been released under the terms of the IBM Public
6 * License. For details, see the LICENSE file in the top-level source
7 * directory or online at http://www.openafs.org/dl/license10.html
12 * Definition of the AFS File Server RPC interface.
15 #include "common.xg" /*Common structures & definitions*/
17 %#define VICECONNBAD 1234
18 %#define VICETOKENDEAD 1235
19 %#define AFS_LOCKWAIT (5*60)
21 customized struct CBS {
26 customized struct BBS {
32 customized struct AFSAccessList {
38 typedef AFSFid ViceFid;
40 typedef afs_int32 ViceDataType;
45 %#define SymbolicLink 3
48 %#define xdr_array(a,b,c,d,e,f) xdr_arrayN(a,b,c,d,e,f)
66 struct AFSOldFetchStatus {
67 afs_uint32 InterfaceVersion;
71 afs_uint32 DataVersion;
74 afs_uint32 CallerAccess;
75 afs_uint32 AnonymousAccess;
76 afs_uint32 UnixModeBits;
77 afs_uint32 ParentVnode;
78 afs_uint32 ParentUnique;
80 afs_uint32 ClientModTime;
81 afs_uint32 ServerModTime;
85 struct AFSFetchStatus {
86 afs_uint32 InterfaceVersion;
90 afs_uint32 DataVersion;
93 afs_uint32 CallerAccess;
94 afs_uint32 AnonymousAccess;
95 afs_uint32 UnixModeBits;
96 afs_uint32 ParentVnode;
97 afs_uint32 ParentUnique;
99 afs_uint32 ClientModTime;
100 afs_uint32 ServerModTime;
102 afs_uint32 SyncCounter;
103 afs_uint32 dataVersionHigh; /* For AFS/DFS translator, hi bits of dvn */
104 afs_uint32 lockCount;
106 afs_uint32 errorCode;
109 struct AFSStoreStatus {
111 afs_uint32 ClientModTime;
114 afs_uint32 UnixModeBits;
118 %#define AFS_SETMODTIME 1
119 %#define AFS_SETOWNER 2
120 %#define AFS_SETGROUP 4
121 %#define AFS_SETMODE 8
122 %#define AFS_SETSEGSIZE 16
123 %#define AFS_FSYNC 1024
125 typedef afs_int32 ViceVolumeType;
132 afs_int32 BlocksAvailable;
133 afs_int32 TotalBlocks;
137 struct ViceStatistics {
138 afs_uint32 CurrentMsgNumber;
139 afs_uint32 OldestMsgNumber;
140 afs_uint32 CurrentTime;
142 afs_uint32 StartTime;
143 afs_int32 CurrentConnections;
144 afs_uint32 TotalViceCalls;
145 afs_uint32 TotalFetchs;
146 afs_uint32 FetchDatas;
147 afs_uint32 FetchedBytes;
148 afs_int32 FetchDataRate;
149 afs_uint32 TotalStores;
150 afs_uint32 StoreDatas;
151 afs_uint32 StoredBytes;
152 afs_int32 StoreDataRate;
153 afs_uint32 TotalRPCBytesSent;
154 afs_uint32 TotalRPCBytesReceived;
155 afs_uint32 TotalRPCPacketsSent;
156 afs_uint32 TotalRPCPacketsReceived;
157 afs_uint32 TotalRPCPacketsLost;
158 afs_uint32 TotalRPCBogusPackets;
166 afs_int32 EtherNetTotalErrors;
167 afs_int32 EtherNetTotalWrites;
168 afs_int32 EtherNetTotalInterupts;
169 afs_int32 EtherNetGoodReads;
170 afs_int32 EtherNetTotalBytesWritten;
171 afs_int32 EtherNetTotalBytesRead;
172 afs_int32 ProcessSize;
173 afs_int32 WorkStations;
174 afs_int32 ActiveWorkStations;
195 struct VolumeStatus {
205 afs_int32 BlocksInUse;
206 afs_int32 PartBlocksAvail;
207 afs_int32 PartMaxBlocks;
210 struct AFSFetchVolumeStatus {
220 afs_int32 BlocksInUse;
221 afs_int32 PartBlocksAvail;
222 afs_int32 PartMaxBlocks;
225 struct AFSStoreVolumeStatus {
231 const AFS_SETMINQUOTA = 1;
232 const AFS_SETMAXQUOTA = 2;
234 struct AFSVolumeInfo {
242 afs_uint32 ServerCount;
251 unsigned short Port0;
252 unsigned short Port1;
253 unsigned short Port2;
254 unsigned short Port3;
255 unsigned short Port4;
256 unsigned short Port5;
257 unsigned short Port6;
258 unsigned short Port7;
269 afs_uint32 ServerCount;
280 typedef afs_int32 ViceLockType;
281 typedef AFSFetchStatus AFSBulkStats<AFSCBMAX>;
285 %#define LockExtend 2
286 %#define LockRelease 3
288 typedef afs_int32 ViceOfflineType;
294 %#include "../afs/longc_procs.h"
298 typedef afs_int32 ViceIds<FLUSHMAX>;
299 typedef afs_int32 IPAddrs<FLUSHMAX>;
301 %#define MAXCMDINT64S 3
302 %#define MAXCMDINT32S 200
303 %#define MAXCMDCHARS 256
305 struct ResidencyCmdInputs {
308 afs_int64 int64s[MAXCMDINT64S];
309 afs_uint32 int32s[MAXCMDINT32S];
310 char chars[MAXCMDCHARS];
313 struct ResidencyCmdOutputs {
315 struct AFSFetchStatus status;
316 afs_int64 int64s[MAXCMDINT64S];
317 afs_uint32 int32s[MAXCMDINT32S];
318 char chars[MAXCMDCHARS];
329 OUT AFSFetchStatus *OutStatus,
330 AFSCallBack *CallBack,
336 OUT AFSOpaque *AccessList,
337 AFSFetchStatus *OutStatus,
343 OUT AFSFetchStatus *OutStatus,
344 AFSCallBack *CallBack,
350 AFSStoreStatus *InStatus,
353 afs_int32 FileLength,
354 OUT AFSFetchStatus *OutStatus,
360 AFSOpaque *AccessList,
361 OUT AFSFetchStatus *OutStatus,
367 AFSStoreStatus *InStatus,
368 OUT AFSFetchStatus *OutStatus,
374 string Name<AFSNAMEMAX>,
375 OUT AFSFetchStatus *OutStatus,
381 string Name<AFSNAMEMAX>,
382 AFSStoreStatus *InStatus,
384 AFSFetchStatus *OutFidStatus,
385 AFSFetchStatus *OutDirStatus,
386 AFSCallBack *CallBack,
387 AFSVolSync *Sync) = 137;
390 IN AFSFid *OldDirFid,
391 string OldName<AFSNAMEMAX>,
393 string NewName<AFSNAMEMAX>,
394 OUT AFSFetchStatus *OutOldDirStatus,
395 AFSFetchStatus *OutNewDirStatus,
401 string Name<AFSNAMEMAX>,
402 string LinkContents<AFSPATHMAX>,
403 AFSStoreStatus *InStatus,
405 AFSFetchStatus *OutFidStatus,
406 AFSFetchStatus *OutDirStatus,
412 string Name<AFSNAMEMAX>,
414 OUT AFSFetchStatus *OutFidStatus,
415 AFSFetchStatus *OutDirStatus,
421 string Name<AFSNAMEMAX>,
422 AFSStoreStatus *InStatus,
424 AFSFetchStatus *OutFidStatus,
425 AFSFetchStatus *OutDirStatus,
426 AFSCallBack *CallBack,
432 string Name<AFSNAMEMAX>,
433 OUT AFSFetchStatus *OutDirStatus,
454 OUT ViceStatistics *Statistics
458 IN AFSCBFids *Fids_Array,
459 AFSCBs *CallBacks_Array
463 IN string VolumeName<AFSNAMEMAX>,
464 OUT VolumeInfo *Volumeinfo
468 IN afs_int32 Volumeid,
469 OUT AFSFetchVolumeStatus *Volumestatus,
470 string Name<AFSNAMEMAX>,
471 string OfflineMsg<AFSOPAQUEMAX>,
472 string Motd<AFSOPAQUEMAX>
476 IN afs_int32 Volumeid,
477 AFSStoreVolumeStatus *Volumestatus,
478 string Name<AFSNAMEMAX>,
479 string OfflineMsg<AFSOPAQUEMAX>,
480 string Motd<AFSOPAQUEMAX>
484 OUT string VolumeName<AFSNAMEMAX>
493 OUT afs_uint32 *Seconds,
498 IN string VolumeName<AFSNAMEMAX>,
499 OUT AFSVolumeInfo *stuff
503 IN AFSCBFids *FidsArray,
504 OUT AFSBulkStats *StatArray,
526 OUT afs_int32 *versionNumberP
530 IN afs_int32 clientVersionNumber,
531 afs_int32 collectionNumber,
532 OUT afs_int32 *srvVersionNumberP,
537 /* This interface is to supported the AFS/DFS Protocol Translator */
540 string Name<AFSNAMEMAX>,
542 AFSFetchStatus *OutFidStatus,
543 AFSFetchStatus *OutDirStatus,
544 AFSCallBack *CallBack,
549 IN ViceIds *IdsArray,
552 OUT afs_int32 *spare2,
558 string Name<AFSNAMEMAX>,
559 string LinkContents<AFSPATHMAX>,
560 AFSStoreStatus *InStatus,
562 AFSFetchStatus *OutFidStatus,
563 AFSFetchStatus *OutDirStatus,
564 AFSCallBack *CallBack,
570 IN struct ResidencyCmdInputs *Inputs,
571 OUT struct ResidencyCmdOutputs *Outputs
575 IN AFSCBFids *FidsArray,
576 OUT AFSBulkStats *StatArray,