- no ldconfig for darwin
[deb_libnfs.git] / rquota / rquota.x
1 /* implementation based on wireshark c-code */
2
3 const RQUOTAPATHLEN = 1024; /* Guess this is max. It is max for mount so probably rquota too */
4
5 enum rquotastat {
6 RQUOTA_OK = 1,
7 RQUOTA_NOQUOTA = 2,
8 RQUOTA_EPERM = 3
9 };
10
11 typedef string exportpath<RQUOTAPATHLEN>;
12
13 struct GETQUOTA1args {
14 exportpath export;
15 int uid;
16 };
17
18 enum quotatype {
19 RQUOTA_TYPE_UID = 0,
20 RQUOTA_TYPE_GID = 1
21 };
22
23 struct GETQUOTA2args {
24 exportpath export;
25 quotatype type;
26 int uid;
27 };
28
29 struct GETQUOTA1res_ok {
30 int bsize;
31 int active;
32 int bhardlimit;
33 int bsoftlimit;
34 int curblocks;
35 int fhardlimit;
36 int fsoftlimit;
37 int curfiles;
38 int btimeleft;
39 int ftimeleft;
40 };
41
42 union GETQUOTA1res switch (rquotastat status) {
43 case RQUOTA_OK:
44 GETQUOTA1res_ok quota;
45 default:
46 void;
47 };
48
49 program RQUOTA_PROGRAM {
50 version RQUOTA_V1 {
51 void
52 RQUOTA1_NULL(void) = 0;
53
54 GETQUOTA1res
55 RQUOTA1_GETQUOTA(GETQUOTA1args) = 1;
56
57 GETQUOTA1res
58 RQUOTA1_GETACTIVEQUOTA(GETQUOTA1args) = 2;
59 } = 1;
60
61 version RQUOTA_V2 {
62 void
63 RQUOTA2_NULL(void) = 0;
64
65 GETQUOTA1res
66 RQUOTA2_GETQUOTA(GETQUOTA2args) = 1;
67
68 GETQUOTA1res
69 RQUOTA2_GETACTIVEQUOTA(GETQUOTA2args) = 2;
70 } = 2;
71 } = 100011;
72