2 * Based on cfs.h from Coda, but revamped for increased simplicity.
3 * Linux modifications by Peter Braam, Aug 1996
4 * Rewritten for InterMezzo
7 #ifndef _PRESTO_HEADER_
8 #define _PRESTO_HEADER_
13 #define ASYNCHRONOUS 1
15 int lento_permit(ino_t ino);
16 int lento_opendir(ino_t ino, int async);
17 int lento_open(ino_t ino);
18 int lento_journal(char *page);
23 * Kernel <--> Lento communications.
27 #define LENTO_PERMIT 1
28 #define LENTO_JOURNAL 2
29 #define LENTO_OPENDIR 3
31 #define LENTO_SIGNAL 5
34 #define PRESTO_RELEASE_JOURNAL 51
35 #define PRESTO_MARK 52
37 #define LENTO_DOWNCALL(opcode) (opcode <= PRESTO_MARK && opcode >= PRESTO_RELEASE_JOURNAL)
39 /* Lento <-> Presto RPC arguments */
42 unsigned int unique; /* Keep multiple outstanding msgs distinct */
43 u_short pid; /* Common to all */
47 /* This structure _must_ sit at the beginning of the buffer */
48 struct lento_down_hdr {
55 struct lento_permit_in {
56 struct lento_up_hdr uh;
59 struct lento_permit_out {
60 struct lento_down_hdr dh;
65 struct lento_opendir_in {
66 struct lento_up_hdr uh;
70 struct lento_opendir_out {
71 struct lento_down_hdr dh;
76 struct lento_open_in {
77 struct lento_up_hdr uh;
80 struct lento_open_out {
81 struct lento_down_hdr dh;
84 /* lento_mark_dentry */
85 struct lento_mark_dentry {
86 struct lento_down_hdr dh;
92 /* NB: every struct below begins with an up_hdr */
94 struct lento_up_hdr uh;
95 struct lento_permit_in lento_permit;
96 struct lento_open_in lento_open;
97 struct lento_opendir_in lento_opendir;
101 struct lento_down_hdr dh;
102 struct lento_permit_out lento_permit;
103 struct lento_open_out lento_open;
104 struct lento_opendir_out lento_opendir;
107 union lento_downcalls {
108 struct lento_down_hdr dch;
109 struct lento_mark_dentry mark;
112 int lento_upcall(int read_size, int *rep_size,
113 union up_args *buffer, int async);