summaryrefslogtreecommitdiff
path: root/lib9p/tests
diff options
context:
space:
mode:
Diffstat (limited to 'lib9p/tests')
-rw-r--r--lib9p/tests/test_compile.c1571
-rwxr-xr-xlib9p/tests/test_compile.c.gen2
-rw-r--r--lib9p/tests/test_compile_config/config.h22
-rw-r--r--lib9p/tests/test_server/fs_flush.c31
-rw-r--r--lib9p/tests/test_server/fs_shutdown.c36
-rw-r--r--lib9p/tests/test_server/fs_whoami.c39
-rwxr-xr-xlib9p/tests/testclient-p9p2
-rw-r--r--lib9p/tests/testclient-p9p.explog34
-rw-r--r--lib9p/tests/testclient-sess.c4
-rw-r--r--lib9p/tests/testclient-sess.explog14
10 files changed, 1289 insertions, 466 deletions
diff --git a/lib9p/tests/test_compile.c b/lib9p/tests/test_compile.c
index 4532655..e53b738 100644
--- a/lib9p/tests/test_compile.c
+++ b/lib9p/tests/test_compile.c
@@ -3,428 +3,1253 @@
#include <lib9p/core.h>
int main(void) {
[[gnu::unused]] uint64_t x;
- x = LIB9P_TAG_NOTAG;
- x = LIB9P_FID_NOFID;
- x = LIB9P_DM_DIR;
+#ifdef LIB9P_B4_FALSE
+ x = LIB9P_B4_FALSE;
+#endif
+#ifdef LIB9P_B4_TRUE
+ x = LIB9P_B4_TRUE;
+#endif
+#ifdef LIB9P_DM_APPEND
x = LIB9P_DM_APPEND;
- x = LIB9P_DM_EXCL;
- x = _LIB9P_DM_PLAN9_MOUNT;
+#endif
+#ifdef LIB9P_DM_AUTH
x = LIB9P_DM_AUTH;
- x = LIB9P_DM_TMP;
- x = _LIB9P_DM_UNUSED_25;
- x = _LIB9P_DM_UNUSED_24;
+#endif
+#ifdef LIB9P_DM_DEVICE
x = LIB9P_DM_DEVICE;
- x = _LIB9P_DM_UNUSED_22;
- x = LIB9P_DM_PIPE;
- x = LIB9P_DM_SOCKET;
- x = LIB9P_DM_SETUID;
- x = LIB9P_DM_SETGID;
- x = _LIB9P_DM_UNUSED_17;
- x = _LIB9P_DM_UNUSED_16;
- x = _LIB9P_DM_UNUSED_15;
- x = _LIB9P_DM_UNUSED_14;
- x = _LIB9P_DM_UNUSED_13;
- x = _LIB9P_DM_UNUSED_12;
- x = _LIB9P_DM_UNUSED_11;
- x = _LIB9P_DM_UNUSED_10;
- x = _LIB9P_DM_UNUSED_9;
- x = LIB9P_DM_OWNER_R;
- x = LIB9P_DM_OWNER_W;
- x = LIB9P_DM_OWNER_X;
+#endif
+#ifdef LIB9P_DM_DIR
+ x = LIB9P_DM_DIR;
+#endif
+#ifdef LIB9P_DM_EXCL
+ x = LIB9P_DM_EXCL;
+#endif
+#ifdef LIB9P_DM_GROUP_R
x = LIB9P_DM_GROUP_R;
+#endif
+#ifdef LIB9P_DM_GROUP_W
x = LIB9P_DM_GROUP_W;
+#endif
+#ifdef LIB9P_DM_GROUP_X
x = LIB9P_DM_GROUP_X;
+#endif
+#ifdef LIB9P_DM_OTHER_R
x = LIB9P_DM_OTHER_R;
+#endif
+#ifdef LIB9P_DM_OTHER_W
x = LIB9P_DM_OTHER_W;
+#endif
+#ifdef LIB9P_DM_OTHER_X
x = LIB9P_DM_OTHER_X;
+#endif
+#ifdef LIB9P_DM_OWNER_R
+ x = LIB9P_DM_OWNER_R;
+#endif
+#ifdef LIB9P_DM_OWNER_W
+ x = LIB9P_DM_OWNER_W;
+#endif
+#ifdef LIB9P_DM_OWNER_X
+ x = LIB9P_DM_OWNER_X;
+#endif
+#ifdef LIB9P_DM_PERM_MASK
x = LIB9P_DM_PERM_MASK;
- x = LIB9P_QT_DIR;
- x = LIB9P_QT_APPEND;
- x = LIB9P_QT_EXCL;
- x = _LIB9P_QT_PLAN9_MOUNT;
- x = LIB9P_QT_AUTH;
- x = LIB9P_QT_TMP;
- x = LIB9P_QT_SYMLINK;
- x = _LIB9P_QT_UNUSED_0;
- x = LIB9P_QT_FILE;
- x = _LIB9P_O_UNUSED_7;
- x = LIB9P_O_RCLOSE;
- x = _LIB9P_O_RESERVED_CEXEC;
- x = LIB9P_O_TRUNC;
- x = _LIB9P_O_UNUSED_3;
- x = _LIB9P_O_UNUSED_2;
- x = LIB9P_O_FLAG_MASK;
- x = LIB9P_O_MODE_READ;
- x = LIB9P_O_MODE_WRITE;
- x = LIB9P_O_MODE_RDWR;
- x = LIB9P_O_MODE_EXEC;
- x = LIB9P_O_MODE_MASK;
- x = LIB9P_NUID_NONUID;
- x = LIB9P_ERRNO_NOERROR;
- x = LIB9P_ERRNO_L_EPERM;
- x = LIB9P_ERRNO_L_ENOENT;
- x = LIB9P_ERRNO_L_ESRCH;
- x = LIB9P_ERRNO_L_EINTR;
- x = LIB9P_ERRNO_L_EIO;
- x = LIB9P_ERRNO_L_ENXIO;
+#endif
+#ifdef LIB9P_DM_PIPE
+ x = LIB9P_DM_PIPE;
+#endif
+#ifdef LIB9P_DM_SETGID
+ x = LIB9P_DM_SETGID;
+#endif
+#ifdef LIB9P_DM_SETUID
+ x = LIB9P_DM_SETUID;
+#endif
+#ifdef LIB9P_DM_SOCKET
+ x = LIB9P_DM_SOCKET;
+#endif
+#ifdef LIB9P_DM_TMP
+ x = LIB9P_DM_TMP;
+#endif
+#ifdef LIB9P_DT_BLOCK_DEV
+ x = LIB9P_DT_BLOCK_DEV;
+#endif
+#ifdef LIB9P_DT_CHAR_DEV
+ x = LIB9P_DT_CHAR_DEV;
+#endif
+#ifdef LIB9P_DT_DIRECTORY
+ x = LIB9P_DT_DIRECTORY;
+#endif
+#ifdef LIB9P_DT_PIPE
+ x = LIB9P_DT_PIPE;
+#endif
+#ifdef LIB9P_DT_REGULAR
+ x = LIB9P_DT_REGULAR;
+#endif
+#ifdef LIB9P_DT_SOCKET
+ x = LIB9P_DT_SOCKET;
+#endif
+#ifdef LIB9P_DT_SYMLINK
+ x = LIB9P_DT_SYMLINK;
+#endif
+#ifdef LIB9P_DT_UNKNOWN
+ x = LIB9P_DT_UNKNOWN;
+#endif
+#ifdef LIB9P_ERRNO_L_E2BIG
x = LIB9P_ERRNO_L_E2BIG;
- x = LIB9P_ERRNO_L_ENOEXEC;
- x = LIB9P_ERRNO_L_EBADF;
- x = LIB9P_ERRNO_L_ECHILD;
- x = LIB9P_ERRNO_L_EAGAIN;
- x = LIB9P_ERRNO_L_ENOMEM;
+#endif
+#ifdef LIB9P_ERRNO_L_EACCES
x = LIB9P_ERRNO_L_EACCES;
- x = LIB9P_ERRNO_L_EFAULT;
- x = LIB9P_ERRNO_L_ENOTBLK;
- x = LIB9P_ERRNO_L_EBUSY;
- x = LIB9P_ERRNO_L_EEXIST;
- x = LIB9P_ERRNO_L_EXDEV;
- x = LIB9P_ERRNO_L_ENODEV;
- x = LIB9P_ERRNO_L_ENOTDIR;
- x = LIB9P_ERRNO_L_EISDIR;
- x = LIB9P_ERRNO_L_EINVAL;
- x = LIB9P_ERRNO_L_ENFILE;
- x = LIB9P_ERRNO_L_EMFILE;
- x = LIB9P_ERRNO_L_ENOTTY;
- x = LIB9P_ERRNO_L_ETXTBSY;
- x = LIB9P_ERRNO_L_EFBIG;
- x = LIB9P_ERRNO_L_ENOSPC;
- x = LIB9P_ERRNO_L_ESPIPE;
- x = LIB9P_ERRNO_L_EROFS;
- x = LIB9P_ERRNO_L_EMLINK;
- x = LIB9P_ERRNO_L_EPIPE;
- x = LIB9P_ERRNO_L_EDOM;
- x = LIB9P_ERRNO_L_ERANGE;
- x = LIB9P_ERRNO_L_EDEADLK;
- x = LIB9P_ERRNO_L_ENAMETOOLONG;
- x = LIB9P_ERRNO_L_ENOLCK;
- x = LIB9P_ERRNO_L_ENOSYS;
- x = LIB9P_ERRNO_L_ENOTEMPTY;
- x = LIB9P_ERRNO_L_ELOOP;
- x = LIB9P_ERRNO_L_ENOMSG;
- x = LIB9P_ERRNO_L_EIDRM;
- x = LIB9P_ERRNO_L_ECHRNG;
- x = LIB9P_ERRNO_L_EL2NSYNC;
- x = LIB9P_ERRNO_L_EL3HLT;
- x = LIB9P_ERRNO_L_EL3RST;
- x = LIB9P_ERRNO_L_ELNRNG;
- x = LIB9P_ERRNO_L_EUNATCH;
- x = LIB9P_ERRNO_L_ENOCSI;
- x = LIB9P_ERRNO_L_EL2HLT;
+#endif
+#ifdef LIB9P_ERRNO_L_EADDRINUSE
+ x = LIB9P_ERRNO_L_EADDRINUSE;
+#endif
+#ifdef LIB9P_ERRNO_L_EADDRNOTAVAIL
+ x = LIB9P_ERRNO_L_EADDRNOTAVAIL;
+#endif
+#ifdef LIB9P_ERRNO_L_EADV
+ x = LIB9P_ERRNO_L_EADV;
+#endif
+#ifdef LIB9P_ERRNO_L_EAFNOSUPPORT
+ x = LIB9P_ERRNO_L_EAFNOSUPPORT;
+#endif
+#ifdef LIB9P_ERRNO_L_EAGAIN
+ x = LIB9P_ERRNO_L_EAGAIN;
+#endif
+#ifdef LIB9P_ERRNO_L_EALREADY
+ x = LIB9P_ERRNO_L_EALREADY;
+#endif
+#ifdef LIB9P_ERRNO_L_EBADE
x = LIB9P_ERRNO_L_EBADE;
+#endif
+#ifdef LIB9P_ERRNO_L_EBADF
+ x = LIB9P_ERRNO_L_EBADF;
+#endif
+#ifdef LIB9P_ERRNO_L_EBADFD
+ x = LIB9P_ERRNO_L_EBADFD;
+#endif
+#ifdef LIB9P_ERRNO_L_EBADMSG
+ x = LIB9P_ERRNO_L_EBADMSG;
+#endif
+#ifdef LIB9P_ERRNO_L_EBADR
x = LIB9P_ERRNO_L_EBADR;
- x = LIB9P_ERRNO_L_EXFULL;
- x = LIB9P_ERRNO_L_ENOANO;
+#endif
+#ifdef LIB9P_ERRNO_L_EBADRQC
x = LIB9P_ERRNO_L_EBADRQC;
+#endif
+#ifdef LIB9P_ERRNO_L_EBADSLT
x = LIB9P_ERRNO_L_EBADSLT;
+#endif
+#ifdef LIB9P_ERRNO_L_EBFONT
x = LIB9P_ERRNO_L_EBFONT;
- x = LIB9P_ERRNO_L_ENOSTR;
- x = LIB9P_ERRNO_L_ENODATA;
- x = LIB9P_ERRNO_L_ETIME;
- x = LIB9P_ERRNO_L_ENOSR;
- x = LIB9P_ERRNO_L_ENONET;
- x = LIB9P_ERRNO_L_ENOPKG;
- x = LIB9P_ERRNO_L_EREMOTE;
- x = LIB9P_ERRNO_L_ENOLINK;
- x = LIB9P_ERRNO_L_EADV;
- x = LIB9P_ERRNO_L_ESRMNT;
+#endif
+#ifdef LIB9P_ERRNO_L_EBUSY
+ x = LIB9P_ERRNO_L_EBUSY;
+#endif
+#ifdef LIB9P_ERRNO_L_ECANCELED
+ x = LIB9P_ERRNO_L_ECANCELED;
+#endif
+#ifdef LIB9P_ERRNO_L_ECHILD
+ x = LIB9P_ERRNO_L_ECHILD;
+#endif
+#ifdef LIB9P_ERRNO_L_ECHRNG
+ x = LIB9P_ERRNO_L_ECHRNG;
+#endif
+#ifdef LIB9P_ERRNO_L_ECOMM
x = LIB9P_ERRNO_L_ECOMM;
- x = LIB9P_ERRNO_L_EPROTO;
- x = LIB9P_ERRNO_L_EMULTIHOP;
+#endif
+#ifdef LIB9P_ERRNO_L_ECONNABORTED
+ x = LIB9P_ERRNO_L_ECONNABORTED;
+#endif
+#ifdef LIB9P_ERRNO_L_ECONNREFUSED
+ x = LIB9P_ERRNO_L_ECONNREFUSED;
+#endif
+#ifdef LIB9P_ERRNO_L_ECONNRESET
+ x = LIB9P_ERRNO_L_ECONNRESET;
+#endif
+#ifdef LIB9P_ERRNO_L_EDEADLK
+ x = LIB9P_ERRNO_L_EDEADLK;
+#endif
+#ifdef LIB9P_ERRNO_L_EDESTADDRREQ
+ x = LIB9P_ERRNO_L_EDESTADDRREQ;
+#endif
+#ifdef LIB9P_ERRNO_L_EDOM
+ x = LIB9P_ERRNO_L_EDOM;
+#endif
+#ifdef LIB9P_ERRNO_L_EDOTDOT
x = LIB9P_ERRNO_L_EDOTDOT;
- x = LIB9P_ERRNO_L_EBADMSG;
- x = LIB9P_ERRNO_L_EOVERFLOW;
- x = LIB9P_ERRNO_L_ENOTUNIQ;
- x = LIB9P_ERRNO_L_EBADFD;
- x = LIB9P_ERRNO_L_EREMCHG;
+#endif
+#ifdef LIB9P_ERRNO_L_EDQUOT
+ x = LIB9P_ERRNO_L_EDQUOT;
+#endif
+#ifdef LIB9P_ERRNO_L_EEXIST
+ x = LIB9P_ERRNO_L_EEXIST;
+#endif
+#ifdef LIB9P_ERRNO_L_EFAULT
+ x = LIB9P_ERRNO_L_EFAULT;
+#endif
+#ifdef LIB9P_ERRNO_L_EFBIG
+ x = LIB9P_ERRNO_L_EFBIG;
+#endif
+#ifdef LIB9P_ERRNO_L_EHOSTDOWN
+ x = LIB9P_ERRNO_L_EHOSTDOWN;
+#endif
+#ifdef LIB9P_ERRNO_L_EHOSTUNREACH
+ x = LIB9P_ERRNO_L_EHOSTUNREACH;
+#endif
+#ifdef LIB9P_ERRNO_L_EHWPOISON
+ x = LIB9P_ERRNO_L_EHWPOISON;
+#endif
+#ifdef LIB9P_ERRNO_L_EIDRM
+ x = LIB9P_ERRNO_L_EIDRM;
+#endif
+#ifdef LIB9P_ERRNO_L_EILSEQ
+ x = LIB9P_ERRNO_L_EILSEQ;
+#endif
+#ifdef LIB9P_ERRNO_L_EINPROGRESS
+ x = LIB9P_ERRNO_L_EINPROGRESS;
+#endif
+#ifdef LIB9P_ERRNO_L_EINTR
+ x = LIB9P_ERRNO_L_EINTR;
+#endif
+#ifdef LIB9P_ERRNO_L_EINVAL
+ x = LIB9P_ERRNO_L_EINVAL;
+#endif
+#ifdef LIB9P_ERRNO_L_EIO
+ x = LIB9P_ERRNO_L_EIO;
+#endif
+#ifdef LIB9P_ERRNO_L_EISCONN
+ x = LIB9P_ERRNO_L_EISCONN;
+#endif
+#ifdef LIB9P_ERRNO_L_EISDIR
+ x = LIB9P_ERRNO_L_EISDIR;
+#endif
+#ifdef LIB9P_ERRNO_L_EISNAM
+ x = LIB9P_ERRNO_L_EISNAM;
+#endif
+#ifdef LIB9P_ERRNO_L_EKEYEXPIRED
+ x = LIB9P_ERRNO_L_EKEYEXPIRED;
+#endif
+#ifdef LIB9P_ERRNO_L_EKEYREJECTED
+ x = LIB9P_ERRNO_L_EKEYREJECTED;
+#endif
+#ifdef LIB9P_ERRNO_L_EKEYREVOKED
+ x = LIB9P_ERRNO_L_EKEYREVOKED;
+#endif
+#ifdef LIB9P_ERRNO_L_EL2HLT
+ x = LIB9P_ERRNO_L_EL2HLT;
+#endif
+#ifdef LIB9P_ERRNO_L_EL2NSYNC
+ x = LIB9P_ERRNO_L_EL2NSYNC;
+#endif
+#ifdef LIB9P_ERRNO_L_EL3HLT
+ x = LIB9P_ERRNO_L_EL3HLT;
+#endif
+#ifdef LIB9P_ERRNO_L_EL3RST
+ x = LIB9P_ERRNO_L_EL3RST;
+#endif
+#ifdef LIB9P_ERRNO_L_ELIBACC
x = LIB9P_ERRNO_L_ELIBACC;
+#endif
+#ifdef LIB9P_ERRNO_L_ELIBBAD
x = LIB9P_ERRNO_L_ELIBBAD;
- x = LIB9P_ERRNO_L_ELIBSCN;
- x = LIB9P_ERRNO_L_ELIBMAX;
+#endif
+#ifdef LIB9P_ERRNO_L_ELIBEXEC
x = LIB9P_ERRNO_L_ELIBEXEC;
- x = LIB9P_ERRNO_L_EILSEQ;
- x = LIB9P_ERRNO_L_ERESTART;
- x = LIB9P_ERRNO_L_ESTRPIPE;
- x = LIB9P_ERRNO_L_EUSERS;
- x = LIB9P_ERRNO_L_ENOTSOCK;
- x = LIB9P_ERRNO_L_EDESTADDRREQ;
+#endif
+#ifdef LIB9P_ERRNO_L_ELIBMAX
+ x = LIB9P_ERRNO_L_ELIBMAX;
+#endif
+#ifdef LIB9P_ERRNO_L_ELIBSCN
+ x = LIB9P_ERRNO_L_ELIBSCN;
+#endif
+#ifdef LIB9P_ERRNO_L_ELNRNG
+ x = LIB9P_ERRNO_L_ELNRNG;
+#endif
+#ifdef LIB9P_ERRNO_L_ELOOP
+ x = LIB9P_ERRNO_L_ELOOP;
+#endif
+#ifdef LIB9P_ERRNO_L_EMEDIUMTYPE
+ x = LIB9P_ERRNO_L_EMEDIUMTYPE;
+#endif
+#ifdef LIB9P_ERRNO_L_EMFILE
+ x = LIB9P_ERRNO_L_EMFILE;
+#endif
+#ifdef LIB9P_ERRNO_L_EMLINK
+ x = LIB9P_ERRNO_L_EMLINK;
+#endif
+#ifdef LIB9P_ERRNO_L_EMSGSIZE
x = LIB9P_ERRNO_L_EMSGSIZE;
- x = LIB9P_ERRNO_L_EPROTOTYPE;
- x = LIB9P_ERRNO_L_ENOPROTOOPT;
- x = LIB9P_ERRNO_L_EPROTONOSUPPORT;
- x = LIB9P_ERRNO_L_ESOCKTNOSUPPORT;
- x = LIB9P_ERRNO_L_EOPNOTSUPP;
- x = LIB9P_ERRNO_L_EPFNOSUPPORT;
- x = LIB9P_ERRNO_L_EAFNOSUPPORT;
- x = LIB9P_ERRNO_L_EADDRINUSE;
- x = LIB9P_ERRNO_L_EADDRNOTAVAIL;
+#endif
+#ifdef LIB9P_ERRNO_L_EMULTIHOP
+ x = LIB9P_ERRNO_L_EMULTIHOP;
+#endif
+#ifdef LIB9P_ERRNO_L_ENAMETOOLONG
+ x = LIB9P_ERRNO_L_ENAMETOOLONG;
+#endif
+#ifdef LIB9P_ERRNO_L_ENAVAIL
+ x = LIB9P_ERRNO_L_ENAVAIL;
+#endif
+#ifdef LIB9P_ERRNO_L_ENETDOWN
x = LIB9P_ERRNO_L_ENETDOWN;
- x = LIB9P_ERRNO_L_ENETUNREACH;
+#endif
+#ifdef LIB9P_ERRNO_L_ENETRESET
x = LIB9P_ERRNO_L_ENETRESET;
- x = LIB9P_ERRNO_L_ECONNABORTED;
- x = LIB9P_ERRNO_L_ECONNRESET;
+#endif
+#ifdef LIB9P_ERRNO_L_ENETUNREACH
+ x = LIB9P_ERRNO_L_ENETUNREACH;
+#endif
+#ifdef LIB9P_ERRNO_L_ENFILE
+ x = LIB9P_ERRNO_L_ENFILE;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOANO
+ x = LIB9P_ERRNO_L_ENOANO;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOBUFS
x = LIB9P_ERRNO_L_ENOBUFS;
- x = LIB9P_ERRNO_L_EISCONN;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOCSI
+ x = LIB9P_ERRNO_L_ENOCSI;
+#endif
+#ifdef LIB9P_ERRNO_L_ENODATA
+ x = LIB9P_ERRNO_L_ENODATA;
+#endif
+#ifdef LIB9P_ERRNO_L_ENODEV
+ x = LIB9P_ERRNO_L_ENODEV;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOENT
+ x = LIB9P_ERRNO_L_ENOENT;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOEXEC
+ x = LIB9P_ERRNO_L_ENOEXEC;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOKEY
+ x = LIB9P_ERRNO_L_ENOKEY;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOLCK
+ x = LIB9P_ERRNO_L_ENOLCK;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOLINK
+ x = LIB9P_ERRNO_L_ENOLINK;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOMEDIUM
+ x = LIB9P_ERRNO_L_ENOMEDIUM;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOMEM
+ x = LIB9P_ERRNO_L_ENOMEM;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOMSG
+ x = LIB9P_ERRNO_L_ENOMSG;
+#endif
+#ifdef LIB9P_ERRNO_L_ENONET
+ x = LIB9P_ERRNO_L_ENONET;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOPKG
+ x = LIB9P_ERRNO_L_ENOPKG;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOPROTOOPT
+ x = LIB9P_ERRNO_L_ENOPROTOOPT;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOSPC
+ x = LIB9P_ERRNO_L_ENOSPC;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOSR
+ x = LIB9P_ERRNO_L_ENOSR;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOSTR
+ x = LIB9P_ERRNO_L_ENOSTR;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOSYS
+ x = LIB9P_ERRNO_L_ENOSYS;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOTBLK
+ x = LIB9P_ERRNO_L_ENOTBLK;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOTCONN
x = LIB9P_ERRNO_L_ENOTCONN;
- x = LIB9P_ERRNO_L_ESHUTDOWN;
- x = LIB9P_ERRNO_L_ETOOMANYREFS;
- x = LIB9P_ERRNO_L_ETIMEDOUT;
- x = LIB9P_ERRNO_L_ECONNREFUSED;
- x = LIB9P_ERRNO_L_EHOSTDOWN;
- x = LIB9P_ERRNO_L_EHOSTUNREACH;
- x = LIB9P_ERRNO_L_EALREADY;
- x = LIB9P_ERRNO_L_EINPROGRESS;
- x = LIB9P_ERRNO_L_ESTALE;
- x = LIB9P_ERRNO_L_EUCLEAN;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOTDIR
+ x = LIB9P_ERRNO_L_ENOTDIR;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOTEMPTY
+ x = LIB9P_ERRNO_L_ENOTEMPTY;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOTNAM
x = LIB9P_ERRNO_L_ENOTNAM;
- x = LIB9P_ERRNO_L_ENAVAIL;
- x = LIB9P_ERRNO_L_EISNAM;
- x = LIB9P_ERRNO_L_EREMOTEIO;
- x = LIB9P_ERRNO_L_EDQUOT;
- x = LIB9P_ERRNO_L_ENOMEDIUM;
- x = LIB9P_ERRNO_L_EMEDIUMTYPE;
- x = LIB9P_ERRNO_L_ECANCELED;
- x = LIB9P_ERRNO_L_ENOKEY;
- x = LIB9P_ERRNO_L_EKEYEXPIRED;
- x = LIB9P_ERRNO_L_EKEYREVOKED;
- x = LIB9P_ERRNO_L_EKEYREJECTED;
- x = LIB9P_ERRNO_L_EOWNERDEAD;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOTRECOVERABLE
x = LIB9P_ERRNO_L_ENOTRECOVERABLE;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOTSOCK
+ x = LIB9P_ERRNO_L_ENOTSOCK;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOTTY
+ x = LIB9P_ERRNO_L_ENOTTY;
+#endif
+#ifdef LIB9P_ERRNO_L_ENOTUNIQ
+ x = LIB9P_ERRNO_L_ENOTUNIQ;
+#endif
+#ifdef LIB9P_ERRNO_L_ENXIO
+ x = LIB9P_ERRNO_L_ENXIO;
+#endif
+#ifdef LIB9P_ERRNO_L_EOPNOTSUPP
+ x = LIB9P_ERRNO_L_EOPNOTSUPP;
+#endif
+#ifdef LIB9P_ERRNO_L_EOVERFLOW
+ x = LIB9P_ERRNO_L_EOVERFLOW;
+#endif
+#ifdef LIB9P_ERRNO_L_EOWNERDEAD
+ x = LIB9P_ERRNO_L_EOWNERDEAD;
+#endif
+#ifdef LIB9P_ERRNO_L_EPERM
+ x = LIB9P_ERRNO_L_EPERM;
+#endif
+#ifdef LIB9P_ERRNO_L_EPFNOSUPPORT
+ x = LIB9P_ERRNO_L_EPFNOSUPPORT;
+#endif
+#ifdef LIB9P_ERRNO_L_EPIPE
+ x = LIB9P_ERRNO_L_EPIPE;
+#endif
+#ifdef LIB9P_ERRNO_L_EPROTO
+ x = LIB9P_ERRNO_L_EPROTO;
+#endif
+#ifdef LIB9P_ERRNO_L_EPROTONOSUPPORT
+ x = LIB9P_ERRNO_L_EPROTONOSUPPORT;
+#endif
+#ifdef LIB9P_ERRNO_L_EPROTOTYPE
+ x = LIB9P_ERRNO_L_EPROTOTYPE;
+#endif
+#ifdef LIB9P_ERRNO_L_ERANGE
+ x = LIB9P_ERRNO_L_ERANGE;
+#endif
+#ifdef LIB9P_ERRNO_L_EREMCHG
+ x = LIB9P_ERRNO_L_EREMCHG;
+#endif
+#ifdef LIB9P_ERRNO_L_EREMOTE
+ x = LIB9P_ERRNO_L_EREMOTE;
+#endif
+#ifdef LIB9P_ERRNO_L_EREMOTEIO
+ x = LIB9P_ERRNO_L_EREMOTEIO;
+#endif
+#ifdef LIB9P_ERRNO_L_ERESTART
+ x = LIB9P_ERRNO_L_ERESTART;
+#endif
+#ifdef LIB9P_ERRNO_L_ERFKILL
x = LIB9P_ERRNO_L_ERFKILL;
- x = LIB9P_ERRNO_L_EHWPOISON;
- x = LIB9P_SUPER_MAGIC_V9FS_MAGIC;
- x = _LIB9P_LO_UNUSED_31;
- x = _LIB9P_LO_UNUSED_30;
- x = _LIB9P_LO_UNUSED_29;
- x = _LIB9P_LO_UNUSED_28;
- x = _LIB9P_LO_UNUSED_27;
- x = _LIB9P_LO_UNUSED_26;
- x = _LIB9P_LO_UNUSED_25;
- x = _LIB9P_LO_UNUSED_24;
- x = _LIB9P_LO_UNUSED_23;
- x = _LIB9P_LO_UNUSED_22;
- x = _LIB9P_LO_UNUSED_21;
- x = LIB9P_LO_SYNC;
+#endif
+#ifdef LIB9P_ERRNO_L_EROFS
+ x = LIB9P_ERRNO_L_EROFS;
+#endif
+#ifdef LIB9P_ERRNO_L_ESHUTDOWN
+ x = LIB9P_ERRNO_L_ESHUTDOWN;
+#endif
+#ifdef LIB9P_ERRNO_L_ESOCKTNOSUPPORT
+ x = LIB9P_ERRNO_L_ESOCKTNOSUPPORT;
+#endif
+#ifdef LIB9P_ERRNO_L_ESPIPE
+ x = LIB9P_ERRNO_L_ESPIPE;
+#endif
+#ifdef LIB9P_ERRNO_L_ESRCH
+ x = LIB9P_ERRNO_L_ESRCH;
+#endif
+#ifdef LIB9P_ERRNO_L_ESRMNT
+ x = LIB9P_ERRNO_L_ESRMNT;
+#endif
+#ifdef LIB9P_ERRNO_L_ESTALE
+ x = LIB9P_ERRNO_L_ESTALE;
+#endif
+#ifdef LIB9P_ERRNO_L_ESTRPIPE
+ x = LIB9P_ERRNO_L_ESTRPIPE;
+#endif
+#ifdef LIB9P_ERRNO_L_ETIME
+ x = LIB9P_ERRNO_L_ETIME;
+#endif
+#ifdef LIB9P_ERRNO_L_ETIMEDOUT
+ x = LIB9P_ERRNO_L_ETIMEDOUT;
+#endif
+#ifdef LIB9P_ERRNO_L_ETOOMANYREFS
+ x = LIB9P_ERRNO_L_ETOOMANYREFS;
+#endif
+#ifdef LIB9P_ERRNO_L_ETXTBSY
+ x = LIB9P_ERRNO_L_ETXTBSY;
+#endif
+#ifdef LIB9P_ERRNO_L_EUCLEAN
+ x = LIB9P_ERRNO_L_EUCLEAN;
+#endif
+#ifdef LIB9P_ERRNO_L_EUNATCH
+ x = LIB9P_ERRNO_L_EUNATCH;
+#endif
+#ifdef LIB9P_ERRNO_L_EUSERS
+ x = LIB9P_ERRNO_L_EUSERS;
+#endif
+#ifdef LIB9P_ERRNO_L_EXDEV
+ x = LIB9P_ERRNO_L_EXDEV;
+#endif
+#ifdef LIB9P_ERRNO_L_EXFULL
+ x = LIB9P_ERRNO_L_EXFULL;
+#endif
+#ifdef LIB9P_ERRNO_NOERROR
+ x = LIB9P_ERRNO_NOERROR;
+#endif
+#ifdef LIB9P_FID_NOFID
+ x = LIB9P_FID_NOFID;
+#endif
+#ifdef LIB9P_GETATTR_ALL
+ x = LIB9P_GETATTR_ALL;
+#endif
+#ifdef LIB9P_GETATTR_ATIME
+ x = LIB9P_GETATTR_ATIME;
+#endif
+#ifdef LIB9P_GETATTR_BASIC
+ x = LIB9P_GETATTR_BASIC;
+#endif
+#ifdef LIB9P_GETATTR_BLOCKS
+ x = LIB9P_GETATTR_BLOCKS;
+#endif
+#ifdef LIB9P_GETATTR_BTIME
+ x = LIB9P_GETATTR_BTIME;
+#endif
+#ifdef LIB9P_GETATTR_CTIME
+ x = LIB9P_GETATTR_CTIME;
+#endif
+#ifdef LIB9P_GETATTR_DATA_VERSION
+ x = LIB9P_GETATTR_DATA_VERSION;
+#endif
+#ifdef LIB9P_GETATTR_GEN
+ x = LIB9P_GETATTR_GEN;
+#endif
+#ifdef LIB9P_GETATTR_GID
+ x = LIB9P_GETATTR_GID;
+#endif
+#ifdef LIB9P_GETATTR_INO
+ x = LIB9P_GETATTR_INO;
+#endif
+#ifdef LIB9P_GETATTR_MODE
+ x = LIB9P_GETATTR_MODE;
+#endif
+#ifdef LIB9P_GETATTR_MTIME
+ x = LIB9P_GETATTR_MTIME;
+#endif
+#ifdef LIB9P_GETATTR_NLINK
+ x = LIB9P_GETATTR_NLINK;
+#endif
+#ifdef LIB9P_GETATTR_RDEV
+ x = LIB9P_GETATTR_RDEV;
+#endif
+#ifdef LIB9P_GETATTR_SIZE
+ x = LIB9P_GETATTR_SIZE;
+#endif
+#ifdef LIB9P_GETATTR_UID
+ x = LIB9P_GETATTR_UID;
+#endif
+#ifdef LIB9P_LOCK_FLAGS_BLOCK
+ x = LIB9P_LOCK_FLAGS_BLOCK;
+#endif
+#ifdef LIB9P_LOCK_FLAGS_RECLAIM
+ x = LIB9P_LOCK_FLAGS_RECLAIM;
+#endif
+#ifdef LIB9P_LOCK_STATUS_BLOCKED
+ x = LIB9P_LOCK_STATUS_BLOCKED;
+#endif
+#ifdef LIB9P_LOCK_STATUS_ERROR
+ x = LIB9P_LOCK_STATUS_ERROR;
+#endif
+#ifdef LIB9P_LOCK_STATUS_GRACE
+ x = LIB9P_LOCK_STATUS_GRACE;
+#endif
+#ifdef LIB9P_LOCK_STATUS_SUCCESS
+ x = LIB9P_LOCK_STATUS_SUCCESS;
+#endif
+#ifdef LIB9P_LOCK_TYPE_RDLCK
+ x = LIB9P_LOCK_TYPE_RDLCK;
+#endif
+#ifdef LIB9P_LOCK_TYPE_UNLCK
+ x = LIB9P_LOCK_TYPE_UNLCK;
+#endif
+#ifdef LIB9P_LOCK_TYPE_WRLCK
+ x = LIB9P_LOCK_TYPE_WRLCK;
+#endif
+#ifdef LIB9P_LO_APPEND
+ x = LIB9P_LO_APPEND;
+#endif
+#ifdef LIB9P_LO_BSD_FASYNC
+ x = LIB9P_LO_BSD_FASYNC;
+#endif
+#ifdef LIB9P_LO_CLOEXEC
x = LIB9P_LO_CLOEXEC;
- x = LIB9P_LO_NOATIME;
- x = LIB9P_LO_NOFOLLOW;
- x = LIB9P_LO_DIRECTORY;
- x = LIB9P_LO_LARGEFILE;
+#endif
+#ifdef LIB9P_LO_CREATE
+ x = LIB9P_LO_CREATE;
+#endif
+#ifdef LIB9P_LO_DIRECT
x = LIB9P_LO_DIRECT;
- x = LIB9P_LO_BSD_FASYNC;
+#endif
+#ifdef LIB9P_LO_DIRECTORY
+ x = LIB9P_LO_DIRECTORY;
+#endif
+#ifdef LIB9P_LO_DSYNC
x = LIB9P_LO_DSYNC;
- x = LIB9P_LO_NONBLOCK;
- x = LIB9P_LO_APPEND;
- x = LIB9P_LO_TRUNC;
- x = LIB9P_LO_NOCTTY;
+#endif
+#ifdef LIB9P_LO_EXCL
x = LIB9P_LO_EXCL;
- x = LIB9P_LO_CREATE;
- x = _LIB9P_LO_UNUSED_5;
- x = _LIB9P_LO_UNUSED_4;
- x = _LIB9P_LO_UNUSED_3;
- x = _LIB9P_LO_UNUSED_2;
+#endif
+#ifdef LIB9P_LO_FLAG_MASK
x = LIB9P_LO_FLAG_MASK;
+#endif
+#ifdef LIB9P_LO_LARGEFILE
+ x = LIB9P_LO_LARGEFILE;
+#endif
+#ifdef LIB9P_LO_MODE_MASK
+ x = LIB9P_LO_MODE_MASK;
+#endif
+#ifdef LIB9P_LO_MODE_NOACCESS
+ x = LIB9P_LO_MODE_NOACCESS;
+#endif
+#ifdef LIB9P_LO_MODE_RDONLY
x = LIB9P_LO_MODE_RDONLY;
- x = LIB9P_LO_MODE_WRONLY;
+#endif
+#ifdef LIB9P_LO_MODE_RDWR
x = LIB9P_LO_MODE_RDWR;
- x = LIB9P_LO_MODE_NOACCESS;
- x = LIB9P_LO_MODE_MASK;
- x = LIB9P_DT_UNKNOWN;
- x = LIB9P_DT_PIPE;
- x = LIB9P_DT_CHAR_DEV;
- x = LIB9P_DT_DIRECTORY;
- x = LIB9P_DT_BLOCK_DEV;
- x = LIB9P_DT_REGULAR;
- x = LIB9P_DT_SYMLINK;
- x = LIB9P_DT_SOCKET;
- x = _LIB9P_DT_WHITEOUT;
- x = _LIB9P_MODE_UNUSED_31;
- x = _LIB9P_MODE_UNUSED_30;
- x = _LIB9P_MODE_UNUSED_29;
- x = _LIB9P_MODE_UNUSED_28;
- x = _LIB9P_MODE_UNUSED_27;
- x = _LIB9P_MODE_UNUSED_26;
- x = _LIB9P_MODE_UNUSED_25;
- x = _LIB9P_MODE_UNUSED_24;
- x = _LIB9P_MODE_UNUSED_23;
- x = _LIB9P_MODE_UNUSED_22;
- x = _LIB9P_MODE_UNUSED_21;
- x = _LIB9P_MODE_UNUSED_20;
- x = _LIB9P_MODE_UNUSED_19;
- x = _LIB9P_MODE_UNUSED_18;
- x = _LIB9P_MODE_UNUSED_17;
- x = _LIB9P_MODE_UNUSED_16;
- x = LIB9P_MODE_PERM_SETGROUP;
- x = LIB9P_MODE_PERM_SETUSER;
- x = LIB9P_MODE_PERM_STICKY;
- x = LIB9P_MODE_PERM_OWNER_R;
- x = LIB9P_MODE_PERM_OWNER_W;
- x = LIB9P_MODE_PERM_OWNER_X;
+#endif
+#ifdef LIB9P_LO_MODE_WRONLY
+ x = LIB9P_LO_MODE_WRONLY;
+#endif
+#ifdef LIB9P_LO_NOATIME
+ x = LIB9P_LO_NOATIME;
+#endif
+#ifdef LIB9P_LO_NOCTTY
+ x = LIB9P_LO_NOCTTY;
+#endif
+#ifdef LIB9P_LO_NOFOLLOW
+ x = LIB9P_LO_NOFOLLOW;
+#endif
+#ifdef LIB9P_LO_NONBLOCK
+ x = LIB9P_LO_NONBLOCK;
+#endif
+#ifdef LIB9P_LO_SYNC
+ x = LIB9P_LO_SYNC;
+#endif
+#ifdef LIB9P_LO_TRUNC
+ x = LIB9P_LO_TRUNC;
+#endif
+#ifdef LIB9P_MODE_FMT_BLOCK_DEV
+ x = LIB9P_MODE_FMT_BLOCK_DEV;
+#endif
+#ifdef LIB9P_MODE_FMT_CHAR_DEV
+ x = LIB9P_MODE_FMT_CHAR_DEV;
+#endif
+#ifdef LIB9P_MODE_FMT_DIRECTORY
+ x = LIB9P_MODE_FMT_DIRECTORY;
+#endif
+#ifdef LIB9P_MODE_FMT_MASK
+ x = LIB9P_MODE_FMT_MASK;
+#endif
+#ifdef LIB9P_MODE_FMT_PIPE
+ x = LIB9P_MODE_FMT_PIPE;
+#endif
+#ifdef LIB9P_MODE_FMT_REGULAR
+ x = LIB9P_MODE_FMT_REGULAR;
+#endif
+#ifdef LIB9P_MODE_FMT_SOCKET
+ x = LIB9P_MODE_FMT_SOCKET;
+#endif
+#ifdef LIB9P_MODE_FMT_SYMLINK
+ x = LIB9P_MODE_FMT_SYMLINK;
+#endif
+#ifdef LIB9P_MODE_PERM_GROUP_R
x = LIB9P_MODE_PERM_GROUP_R;
+#endif
+#ifdef LIB9P_MODE_PERM_GROUP_W
x = LIB9P_MODE_PERM_GROUP_W;
+#endif
+#ifdef LIB9P_MODE_PERM_GROUP_X
x = LIB9P_MODE_PERM_GROUP_X;
+#endif
+#ifdef LIB9P_MODE_PERM_MASK
+ x = LIB9P_MODE_PERM_MASK;
+#endif
+#ifdef LIB9P_MODE_PERM_OTHER_R
x = LIB9P_MODE_PERM_OTHER_R;
+#endif
+#ifdef LIB9P_MODE_PERM_OTHER_W
x = LIB9P_MODE_PERM_OTHER_W;
+#endif
+#ifdef LIB9P_MODE_PERM_OTHER_X
x = LIB9P_MODE_PERM_OTHER_X;
- x = LIB9P_MODE_PERM_MASK;
- x = LIB9P_MODE_FMT_PIPE;
- x = LIB9P_MODE_FMT_CHAR_DEV;
- x = LIB9P_MODE_FMT_DIRECTORY;
- x = LIB9P_MODE_FMT_BLOCK_DEV;
- x = LIB9P_MODE_FMT_REGULAR;
- x = LIB9P_MODE_FMT_SYMLINK;
- x = LIB9P_MODE_FMT_SOCKET;
- x = LIB9P_MODE_FMT_MASK;
- x = LIB9P_B4_FALSE;
- x = LIB9P_B4_TRUE;
- x = _LIB9P_GETATTR_UNUSED_63;
- x = _LIB9P_GETATTR_UNUSED_62;
- x = _LIB9P_GETATTR_UNUSED_61;
- x = _LIB9P_GETATTR_UNUSED_60;
- x = _LIB9P_GETATTR_UNUSED_59;
- x = _LIB9P_GETATTR_UNUSED_58;
- x = _LIB9P_GETATTR_UNUSED_57;
- x = _LIB9P_GETATTR_UNUSED_56;
- x = _LIB9P_GETATTR_UNUSED_55;
- x = _LIB9P_GETATTR_UNUSED_54;
- x = _LIB9P_GETATTR_UNUSED_53;
- x = _LIB9P_GETATTR_UNUSED_52;
- x = _LIB9P_GETATTR_UNUSED_51;
- x = _LIB9P_GETATTR_UNUSED_50;
- x = _LIB9P_GETATTR_UNUSED_49;
- x = _LIB9P_GETATTR_UNUSED_48;
- x = _LIB9P_GETATTR_UNUSED_47;
- x = _LIB9P_GETATTR_UNUSED_46;
- x = _LIB9P_GETATTR_UNUSED_45;
- x = _LIB9P_GETATTR_UNUSED_44;
- x = _LIB9P_GETATTR_UNUSED_43;
- x = _LIB9P_GETATTR_UNUSED_42;
- x = _LIB9P_GETATTR_UNUSED_41;
- x = _LIB9P_GETATTR_UNUSED_40;
- x = _LIB9P_GETATTR_UNUSED_39;
- x = _LIB9P_GETATTR_UNUSED_38;
- x = _LIB9P_GETATTR_UNUSED_37;
- x = _LIB9P_GETATTR_UNUSED_36;
- x = _LIB9P_GETATTR_UNUSED_35;
- x = _LIB9P_GETATTR_UNUSED_34;
- x = _LIB9P_GETATTR_UNUSED_33;
- x = _LIB9P_GETATTR_UNUSED_32;
- x = _LIB9P_GETATTR_UNUSED_31;
- x = _LIB9P_GETATTR_UNUSED_30;
- x = _LIB9P_GETATTR_UNUSED_29;
- x = _LIB9P_GETATTR_UNUSED_28;
- x = _LIB9P_GETATTR_UNUSED_27;
- x = _LIB9P_GETATTR_UNUSED_26;
- x = _LIB9P_GETATTR_UNUSED_25;
- x = _LIB9P_GETATTR_UNUSED_24;
- x = _LIB9P_GETATTR_UNUSED_23;
- x = _LIB9P_GETATTR_UNUSED_22;
- x = _LIB9P_GETATTR_UNUSED_21;
- x = _LIB9P_GETATTR_UNUSED_20;
- x = _LIB9P_GETATTR_UNUSED_19;
- x = _LIB9P_GETATTR_UNUSED_18;
- x = _LIB9P_GETATTR_UNUSED_17;
- x = _LIB9P_GETATTR_UNUSED_16;
- x = _LIB9P_GETATTR_UNUSED_15;
- x = _LIB9P_GETATTR_UNUSED_14;
- x = LIB9P_GETATTR_DATA_VERSION;
- x = LIB9P_GETATTR_GEN;
- x = LIB9P_GETATTR_BTIME;
- x = LIB9P_GETATTR_BLOCKS;
- x = LIB9P_GETATTR_SIZE;
- x = LIB9P_GETATTR_INO;
- x = LIB9P_GETATTR_CTIME;
- x = LIB9P_GETATTR_MTIME;
- x = LIB9P_GETATTR_ATIME;
- x = LIB9P_GETATTR_RDEV;
- x = LIB9P_GETATTR_GID;
- x = LIB9P_GETATTR_UID;
- x = LIB9P_GETATTR_NLINK;
- x = LIB9P_GETATTR_MODE;
- x = LIB9P_GETATTR_BASIC;
- x = LIB9P_GETATTR_ALL;
- x = _LIB9P_SETATTR_UNUSED_31;
- x = _LIB9P_SETATTR_UNUSED_30;
- x = _LIB9P_SETATTR_UNUSED_29;
- x = _LIB9P_SETATTR_UNUSED_28;
- x = _LIB9P_SETATTR_UNUSED_27;
- x = _LIB9P_SETATTR_UNUSED_26;
- x = _LIB9P_SETATTR_UNUSED_25;
- x = _LIB9P_SETATTR_UNUSED_24;
- x = _LIB9P_SETATTR_UNUSED_23;
- x = _LIB9P_SETATTR_UNUSED_22;
- x = _LIB9P_SETATTR_UNUSED_21;
- x = _LIB9P_SETATTR_UNUSED_20;
- x = _LIB9P_SETATTR_UNUSED_19;
- x = _LIB9P_SETATTR_UNUSED_18;
- x = _LIB9P_SETATTR_UNUSED_17;
- x = _LIB9P_SETATTR_UNUSED_16;
- x = _LIB9P_SETATTR_UNUSED_15;
- x = _LIB9P_SETATTR_UNUSED_14;
- x = _LIB9P_SETATTR_UNUSED_13;
- x = _LIB9P_SETATTR_UNUSED_12;
- x = _LIB9P_SETATTR_UNUSED_11;
- x = _LIB9P_SETATTR_UNUSED_10;
- x = _LIB9P_SETATTR_UNUSED_9;
- x = LIB9P_SETATTR_MTIME_SET;
+#endif
+#ifdef LIB9P_MODE_PERM_OWNER_R
+ x = LIB9P_MODE_PERM_OWNER_R;
+#endif
+#ifdef LIB9P_MODE_PERM_OWNER_W
+ x = LIB9P_MODE_PERM_OWNER_W;
+#endif
+#ifdef LIB9P_MODE_PERM_OWNER_X
+ x = LIB9P_MODE_PERM_OWNER_X;
+#endif
+#ifdef LIB9P_MODE_PERM_SETGROUP
+ x = LIB9P_MODE_PERM_SETGROUP;
+#endif
+#ifdef LIB9P_MODE_PERM_SETUSER
+ x = LIB9P_MODE_PERM_SETUSER;
+#endif
+#ifdef LIB9P_MODE_PERM_STICKY
+ x = LIB9P_MODE_PERM_STICKY;
+#endif
+#ifdef LIB9P_NUID_NONUID
+ x = LIB9P_NUID_NONUID;
+#endif
+#ifdef LIB9P_O_FLAG_MASK
+ x = LIB9P_O_FLAG_MASK;
+#endif
+#ifdef LIB9P_O_MODE_EXEC
+ x = LIB9P_O_MODE_EXEC;
+#endif
+#ifdef LIB9P_O_MODE_MASK
+ x = LIB9P_O_MODE_MASK;
+#endif
+#ifdef LIB9P_O_MODE_RDWR
+ x = LIB9P_O_MODE_RDWR;
+#endif
+#ifdef LIB9P_O_MODE_READ
+ x = LIB9P_O_MODE_READ;
+#endif
+#ifdef LIB9P_O_MODE_WRITE
+ x = LIB9P_O_MODE_WRITE;
+#endif
+#ifdef LIB9P_O_RCLOSE
+ x = LIB9P_O_RCLOSE;
+#endif
+#ifdef LIB9P_O_TRUNC
+ x = LIB9P_O_TRUNC;
+#endif
+#ifdef LIB9P_QT_APPEND
+ x = LIB9P_QT_APPEND;
+#endif
+#ifdef LIB9P_QT_AUTH
+ x = LIB9P_QT_AUTH;
+#endif
+#ifdef LIB9P_QT_DIR
+ x = LIB9P_QT_DIR;
+#endif
+#ifdef LIB9P_QT_EXCL
+ x = LIB9P_QT_EXCL;
+#endif
+#ifdef LIB9P_QT_FILE
+ x = LIB9P_QT_FILE;
+#endif
+#ifdef LIB9P_QT_SYMLINK
+ x = LIB9P_QT_SYMLINK;
+#endif
+#ifdef LIB9P_QT_TMP
+ x = LIB9P_QT_TMP;
+#endif
+#ifdef LIB9P_RMSG_MAX_COPY
+ x = LIB9P_RMSG_MAX_COPY;
+#endif
+#ifdef LIB9P_RMSG_MAX_IOV
+ x = LIB9P_RMSG_MAX_IOV;
+#endif
+#ifdef LIB9P_SETATTR_ATIME
+ x = LIB9P_SETATTR_ATIME;
+#endif
+#ifdef LIB9P_SETATTR_ATIME_SET
x = LIB9P_SETATTR_ATIME_SET;
+#endif
+#ifdef LIB9P_SETATTR_CTIME
x = LIB9P_SETATTR_CTIME;
+#endif
+#ifdef LIB9P_SETATTR_GID
+ x = LIB9P_SETATTR_GID;
+#endif
+#ifdef LIB9P_SETATTR_MODE
+ x = LIB9P_SETATTR_MODE;
+#endif
+#ifdef LIB9P_SETATTR_MTIME
x = LIB9P_SETATTR_MTIME;
- x = LIB9P_SETATTR_ATIME;
+#endif
+#ifdef LIB9P_SETATTR_MTIME_SET
+ x = LIB9P_SETATTR_MTIME_SET;
+#endif
+#ifdef LIB9P_SETATTR_SIZE
x = LIB9P_SETATTR_SIZE;
- x = LIB9P_SETATTR_GID;
+#endif
+#ifdef LIB9P_SETATTR_UID
x = LIB9P_SETATTR_UID;
- x = LIB9P_SETATTR_MODE;
- x = LIB9P_LOCK_TYPE_RDLCK;
- x = LIB9P_LOCK_TYPE_WRLCK;
- x = LIB9P_LOCK_TYPE_UNLCK;
- x = _LIB9P_LOCK_FLAGS_UNUSED_31;
- x = _LIB9P_LOCK_FLAGS_UNUSED_30;
- x = _LIB9P_LOCK_FLAGS_UNUSED_29;
- x = _LIB9P_LOCK_FLAGS_UNUSED_28;
- x = _LIB9P_LOCK_FLAGS_UNUSED_27;
- x = _LIB9P_LOCK_FLAGS_UNUSED_26;
- x = _LIB9P_LOCK_FLAGS_UNUSED_25;
- x = _LIB9P_LOCK_FLAGS_UNUSED_24;
- x = _LIB9P_LOCK_FLAGS_UNUSED_23;
- x = _LIB9P_LOCK_FLAGS_UNUSED_22;
- x = _LIB9P_LOCK_FLAGS_UNUSED_21;
- x = _LIB9P_LOCK_FLAGS_UNUSED_20;
- x = _LIB9P_LOCK_FLAGS_UNUSED_19;
- x = _LIB9P_LOCK_FLAGS_UNUSED_18;
- x = _LIB9P_LOCK_FLAGS_UNUSED_17;
- x = _LIB9P_LOCK_FLAGS_UNUSED_16;
- x = _LIB9P_LOCK_FLAGS_UNUSED_15;
- x = _LIB9P_LOCK_FLAGS_UNUSED_14;
- x = _LIB9P_LOCK_FLAGS_UNUSED_13;
- x = _LIB9P_LOCK_FLAGS_UNUSED_12;
- x = _LIB9P_LOCK_FLAGS_UNUSED_11;
+#endif
+#ifdef LIB9P_SUPER_MAGIC_V9FS_MAGIC
+ x = LIB9P_SUPER_MAGIC_V9FS_MAGIC;
+#endif
+#ifdef LIB9P_TAG_NOTAG
+ x = LIB9P_TAG_NOTAG;
+#endif
+#ifdef LIB9P_TMSG_MAX_COPY
+ x = LIB9P_TMSG_MAX_COPY;
+#endif
+#ifdef LIB9P_TMSG_MAX_IOV
+ x = LIB9P_TMSG_MAX_IOV;
+#endif
+#ifdef _LIB9P_DM_PLAN9_MOUNT
+ x = _LIB9P_DM_PLAN9_MOUNT;
+#endif
+#ifdef _LIB9P_DM_UNUSED_10
+ x = _LIB9P_DM_UNUSED_10;
+#endif
+#ifdef _LIB9P_DM_UNUSED_11
+ x = _LIB9P_DM_UNUSED_11;
+#endif
+#ifdef _LIB9P_DM_UNUSED_12
+ x = _LIB9P_DM_UNUSED_12;
+#endif
+#ifdef _LIB9P_DM_UNUSED_13
+ x = _LIB9P_DM_UNUSED_13;
+#endif
+#ifdef _LIB9P_DM_UNUSED_14
+ x = _LIB9P_DM_UNUSED_14;
+#endif
+#ifdef _LIB9P_DM_UNUSED_15
+ x = _LIB9P_DM_UNUSED_15;
+#endif
+#ifdef _LIB9P_DM_UNUSED_16
+ x = _LIB9P_DM_UNUSED_16;
+#endif
+#ifdef _LIB9P_DM_UNUSED_17
+ x = _LIB9P_DM_UNUSED_17;
+#endif
+#ifdef _LIB9P_DM_UNUSED_22
+ x = _LIB9P_DM_UNUSED_22;
+#endif
+#ifdef _LIB9P_DM_UNUSED_24
+ x = _LIB9P_DM_UNUSED_24;
+#endif
+#ifdef _LIB9P_DM_UNUSED_25
+ x = _LIB9P_DM_UNUSED_25;
+#endif
+#ifdef _LIB9P_DM_UNUSED_9
+ x = _LIB9P_DM_UNUSED_9;
+#endif
+#ifdef _LIB9P_DT_WHITEOUT
+ x = _LIB9P_DT_WHITEOUT;
+#endif
+#ifdef _LIB9P_ENABLE_stat
+ x = _LIB9P_ENABLE_stat;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_14
+ x = _LIB9P_GETATTR_UNUSED_14;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_15
+ x = _LIB9P_GETATTR_UNUSED_15;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_16
+ x = _LIB9P_GETATTR_UNUSED_16;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_17
+ x = _LIB9P_GETATTR_UNUSED_17;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_18
+ x = _LIB9P_GETATTR_UNUSED_18;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_19
+ x = _LIB9P_GETATTR_UNUSED_19;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_20
+ x = _LIB9P_GETATTR_UNUSED_20;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_21
+ x = _LIB9P_GETATTR_UNUSED_21;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_22
+ x = _LIB9P_GETATTR_UNUSED_22;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_23
+ x = _LIB9P_GETATTR_UNUSED_23;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_24
+ x = _LIB9P_GETATTR_UNUSED_24;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_25
+ x = _LIB9P_GETATTR_UNUSED_25;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_26
+ x = _LIB9P_GETATTR_UNUSED_26;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_27
+ x = _LIB9P_GETATTR_UNUSED_27;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_28
+ x = _LIB9P_GETATTR_UNUSED_28;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_29
+ x = _LIB9P_GETATTR_UNUSED_29;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_30
+ x = _LIB9P_GETATTR_UNUSED_30;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_31
+ x = _LIB9P_GETATTR_UNUSED_31;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_32
+ x = _LIB9P_GETATTR_UNUSED_32;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_33
+ x = _LIB9P_GETATTR_UNUSED_33;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_34
+ x = _LIB9P_GETATTR_UNUSED_34;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_35
+ x = _LIB9P_GETATTR_UNUSED_35;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_36
+ x = _LIB9P_GETATTR_UNUSED_36;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_37
+ x = _LIB9P_GETATTR_UNUSED_37;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_38
+ x = _LIB9P_GETATTR_UNUSED_38;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_39
+ x = _LIB9P_GETATTR_UNUSED_39;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_40
+ x = _LIB9P_GETATTR_UNUSED_40;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_41
+ x = _LIB9P_GETATTR_UNUSED_41;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_42
+ x = _LIB9P_GETATTR_UNUSED_42;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_43
+ x = _LIB9P_GETATTR_UNUSED_43;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_44
+ x = _LIB9P_GETATTR_UNUSED_44;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_45
+ x = _LIB9P_GETATTR_UNUSED_45;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_46
+ x = _LIB9P_GETATTR_UNUSED_46;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_47
+ x = _LIB9P_GETATTR_UNUSED_47;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_48
+ x = _LIB9P_GETATTR_UNUSED_48;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_49
+ x = _LIB9P_GETATTR_UNUSED_49;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_50
+ x = _LIB9P_GETATTR_UNUSED_50;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_51
+ x = _LIB9P_GETATTR_UNUSED_51;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_52
+ x = _LIB9P_GETATTR_UNUSED_52;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_53
+ x = _LIB9P_GETATTR_UNUSED_53;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_54
+ x = _LIB9P_GETATTR_UNUSED_54;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_55
+ x = _LIB9P_GETATTR_UNUSED_55;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_56
+ x = _LIB9P_GETATTR_UNUSED_56;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_57
+ x = _LIB9P_GETATTR_UNUSED_57;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_58
+ x = _LIB9P_GETATTR_UNUSED_58;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_59
+ x = _LIB9P_GETATTR_UNUSED_59;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_60
+ x = _LIB9P_GETATTR_UNUSED_60;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_61
+ x = _LIB9P_GETATTR_UNUSED_61;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_62
+ x = _LIB9P_GETATTR_UNUSED_62;
+#endif
+#ifdef _LIB9P_GETATTR_UNUSED_63
+ x = _LIB9P_GETATTR_UNUSED_63;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_10
x = _LIB9P_LOCK_FLAGS_UNUSED_10;
- x = _LIB9P_LOCK_FLAGS_UNUSED_9;
- x = _LIB9P_LOCK_FLAGS_UNUSED_8;
- x = _LIB9P_LOCK_FLAGS_UNUSED_7;
- x = _LIB9P_LOCK_FLAGS_UNUSED_6;
- x = _LIB9P_LOCK_FLAGS_UNUSED_5;
- x = _LIB9P_LOCK_FLAGS_UNUSED_4;
- x = _LIB9P_LOCK_FLAGS_UNUSED_3;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_11
+ x = _LIB9P_LOCK_FLAGS_UNUSED_11;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_12
+ x = _LIB9P_LOCK_FLAGS_UNUSED_12;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_13
+ x = _LIB9P_LOCK_FLAGS_UNUSED_13;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_14
+ x = _LIB9P_LOCK_FLAGS_UNUSED_14;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_15
+ x = _LIB9P_LOCK_FLAGS_UNUSED_15;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_16
+ x = _LIB9P_LOCK_FLAGS_UNUSED_16;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_17
+ x = _LIB9P_LOCK_FLAGS_UNUSED_17;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_18
+ x = _LIB9P_LOCK_FLAGS_UNUSED_18;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_19
+ x = _LIB9P_LOCK_FLAGS_UNUSED_19;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_2
x = _LIB9P_LOCK_FLAGS_UNUSED_2;
- x = LIB9P_LOCK_FLAGS_RECLAIM;
- x = LIB9P_LOCK_FLAGS_BLOCK;
- x = LIB9P_LOCK_STATUS_SUCCESS;
- x = LIB9P_LOCK_STATUS_BLOCKED;
- x = LIB9P_LOCK_STATUS_ERROR;
- x = LIB9P_LOCK_STATUS_GRACE;
- x = LIB9P_TMSG_MAX_IOV;
- x = LIB9P_TMSG_MAX_IOV;
- x = LIB9P_TMSG_MAX_COPY;
- x = LIB9P_TMSG_MAX_COPY;
- x = LIB9P_TMSG_MAX_COPY;
- x = LIB9P_TMSG_MAX_COPY;
- x = LIB9P_TMSG_MAX_COPY;
- x = LIB9P_TMSG_MAX_COPY;
- x = LIB9P_RMSG_MAX_IOV;
- x = LIB9P_RMSG_MAX_IOV;
- x = LIB9P_RMSG_MAX_IOV;
- x = LIB9P_RMSG_MAX_COPY;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_20
+ x = _LIB9P_LOCK_FLAGS_UNUSED_20;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_21
+ x = _LIB9P_LOCK_FLAGS_UNUSED_21;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_22
+ x = _LIB9P_LOCK_FLAGS_UNUSED_22;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_23
+ x = _LIB9P_LOCK_FLAGS_UNUSED_23;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_24
+ x = _LIB9P_LOCK_FLAGS_UNUSED_24;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_25
+ x = _LIB9P_LOCK_FLAGS_UNUSED_25;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_26
+ x = _LIB9P_LOCK_FLAGS_UNUSED_26;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_27
+ x = _LIB9P_LOCK_FLAGS_UNUSED_27;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_28
+ x = _LIB9P_LOCK_FLAGS_UNUSED_28;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_29
+ x = _LIB9P_LOCK_FLAGS_UNUSED_29;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_3
+ x = _LIB9P_LOCK_FLAGS_UNUSED_3;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_30
+ x = _LIB9P_LOCK_FLAGS_UNUSED_30;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_31
+ x = _LIB9P_LOCK_FLAGS_UNUSED_31;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_4
+ x = _LIB9P_LOCK_FLAGS_UNUSED_4;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_5
+ x = _LIB9P_LOCK_FLAGS_UNUSED_5;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_6
+ x = _LIB9P_LOCK_FLAGS_UNUSED_6;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_7
+ x = _LIB9P_LOCK_FLAGS_UNUSED_7;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_8
+ x = _LIB9P_LOCK_FLAGS_UNUSED_8;
+#endif
+#ifdef _LIB9P_LOCK_FLAGS_UNUSED_9
+ x = _LIB9P_LOCK_FLAGS_UNUSED_9;
+#endif
+#ifdef _LIB9P_LO_UNUSED_2
+ x = _LIB9P_LO_UNUSED_2;
+#endif
+#ifdef _LIB9P_LO_UNUSED_21
+ x = _LIB9P_LO_UNUSED_21;
+#endif
+#ifdef _LIB9P_LO_UNUSED_22
+ x = _LIB9P_LO_UNUSED_22;
+#endif
+#ifdef _LIB9P_LO_UNUSED_23
+ x = _LIB9P_LO_UNUSED_23;
+#endif
+#ifdef _LIB9P_LO_UNUSED_24
+ x = _LIB9P_LO_UNUSED_24;
+#endif
+#ifdef _LIB9P_LO_UNUSED_25
+ x = _LIB9P_LO_UNUSED_25;
+#endif
+#ifdef _LIB9P_LO_UNUSED_26
+ x = _LIB9P_LO_UNUSED_26;
+#endif
+#ifdef _LIB9P_LO_UNUSED_27
+ x = _LIB9P_LO_UNUSED_27;
+#endif
+#ifdef _LIB9P_LO_UNUSED_28
+ x = _LIB9P_LO_UNUSED_28;
+#endif
+#ifdef _LIB9P_LO_UNUSED_29
+ x = _LIB9P_LO_UNUSED_29;
+#endif
+#ifdef _LIB9P_LO_UNUSED_3
+ x = _LIB9P_LO_UNUSED_3;
+#endif
+#ifdef _LIB9P_LO_UNUSED_30
+ x = _LIB9P_LO_UNUSED_30;
+#endif
+#ifdef _LIB9P_LO_UNUSED_31
+ x = _LIB9P_LO_UNUSED_31;
+#endif
+#ifdef _LIB9P_LO_UNUSED_4
+ x = _LIB9P_LO_UNUSED_4;
+#endif
+#ifdef _LIB9P_LO_UNUSED_5
+ x = _LIB9P_LO_UNUSED_5;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_16
+ x = _LIB9P_MODE_UNUSED_16;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_17
+ x = _LIB9P_MODE_UNUSED_17;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_18
+ x = _LIB9P_MODE_UNUSED_18;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_19
+ x = _LIB9P_MODE_UNUSED_19;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_20
+ x = _LIB9P_MODE_UNUSED_20;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_21
+ x = _LIB9P_MODE_UNUSED_21;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_22
+ x = _LIB9P_MODE_UNUSED_22;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_23
+ x = _LIB9P_MODE_UNUSED_23;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_24
+ x = _LIB9P_MODE_UNUSED_24;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_25
+ x = _LIB9P_MODE_UNUSED_25;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_26
+ x = _LIB9P_MODE_UNUSED_26;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_27
+ x = _LIB9P_MODE_UNUSED_27;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_28
+ x = _LIB9P_MODE_UNUSED_28;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_29
+ x = _LIB9P_MODE_UNUSED_29;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_30
+ x = _LIB9P_MODE_UNUSED_30;
+#endif
+#ifdef _LIB9P_MODE_UNUSED_31
+ x = _LIB9P_MODE_UNUSED_31;
+#endif
+#ifdef _LIB9P_O_RESERVED_CEXEC
+ x = _LIB9P_O_RESERVED_CEXEC;
+#endif
+#ifdef _LIB9P_O_UNUSED_2
+ x = _LIB9P_O_UNUSED_2;
+#endif
+#ifdef _LIB9P_O_UNUSED_3
+ x = _LIB9P_O_UNUSED_3;
+#endif
+#ifdef _LIB9P_O_UNUSED_7
+ x = _LIB9P_O_UNUSED_7;
+#endif
+#ifdef _LIB9P_QT_PLAN9_MOUNT
+ x = _LIB9P_QT_PLAN9_MOUNT;
+#endif
+#ifdef _LIB9P_QT_UNUSED_0
+ x = _LIB9P_QT_UNUSED_0;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_10
+ x = _LIB9P_SETATTR_UNUSED_10;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_11
+ x = _LIB9P_SETATTR_UNUSED_11;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_12
+ x = _LIB9P_SETATTR_UNUSED_12;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_13
+ x = _LIB9P_SETATTR_UNUSED_13;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_14
+ x = _LIB9P_SETATTR_UNUSED_14;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_15
+ x = _LIB9P_SETATTR_UNUSED_15;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_16
+ x = _LIB9P_SETATTR_UNUSED_16;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_17
+ x = _LIB9P_SETATTR_UNUSED_17;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_18
+ x = _LIB9P_SETATTR_UNUSED_18;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_19
+ x = _LIB9P_SETATTR_UNUSED_19;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_20
+ x = _LIB9P_SETATTR_UNUSED_20;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_21
+ x = _LIB9P_SETATTR_UNUSED_21;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_22
+ x = _LIB9P_SETATTR_UNUSED_22;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_23
+ x = _LIB9P_SETATTR_UNUSED_23;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_24
+ x = _LIB9P_SETATTR_UNUSED_24;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_25
+ x = _LIB9P_SETATTR_UNUSED_25;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_26
+ x = _LIB9P_SETATTR_UNUSED_26;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_27
+ x = _LIB9P_SETATTR_UNUSED_27;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_28
+ x = _LIB9P_SETATTR_UNUSED_28;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_29
+ x = _LIB9P_SETATTR_UNUSED_29;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_30
+ x = _LIB9P_SETATTR_UNUSED_30;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_31
+ x = _LIB9P_SETATTR_UNUSED_31;
+#endif
+#ifdef _LIB9P_SETATTR_UNUSED_9
+ x = _LIB9P_SETATTR_UNUSED_9;
+#endif
return 0;
}
diff --git a/lib9p/tests/test_compile.c.gen b/lib9p/tests/test_compile.c.gen
index 1289943..eb89c54 100755
--- a/lib9p/tests/test_compile.c.gen
+++ b/lib9p/tests/test_compile.c.gen
@@ -13,7 +13,7 @@ outfile=$2
echo "#include <lib9p/core.h>"
echo 'int main(void) {'
echo ' [[gnu::unused]] uint64_t x;'
- sed -nE 's/^\s*#\s*define\s*(\S[^ (]*)\s.*/ x = \1;/p' <"$generated_h"
+ <"$generated_h" sed -nE 's/^\s*#\s*define\s*(\S[^ (]*)\s.*/\1/p' | LC_COLLATE=C sort -u | sed 's/.*/#ifdef &\n x = &;\n#endif/'
echo ' return 0;'
echo '}'
} >"$outfile"
diff --git a/lib9p/tests/test_compile_config/config.h b/lib9p/tests/test_compile_config/config.h
index f899dfa..02cb8e5 100644
--- a/lib9p/tests/test_compile_config/config.h
+++ b/lib9p/tests/test_compile_config/config.h
@@ -7,13 +7,25 @@
#ifndef _CONFIG_H_
#define _CONFIG_H_
+/* 9P *************************************************************************/
+
#define CONFIG_9P_MAX_ERR_SIZE 128
#define CONFIG_9P_MAX_9P2000_e_WELEM 16
-#define CONFIG_9P_ENABLE_9P2000 1 /* bool */
-#define CONFIG_9P_ENABLE_9P2000_u 1 /* bool */
-#define CONFIG_9P_ENABLE_9P2000_e 1 /* bool */
-#define CONFIG_9P_ENABLE_9P2000_L 1 /* bool */
-#define CONFIG_9P_ENABLE_9P2000_p9p 1 /* bool */
+/* 9P_SRV *********************************************************************/
+
+#define CONFIG_9P_SRV_MAX_MSG_SIZE ((4*1024)+24)
+#define CONFIG_9P_SRV_MAX_HOSTMSG_SIZE CONFIG_9P_SRV_MAX_MSG_SIZE+16
+
+/* COROUTINE ******************************************************************/
+
+#define CONFIG_COROUTINE_STACK_SIZE_DEFAULT (32*1024)
+#define CONFIG_COROUTINE_NAME_LEN 16
+#define CONFIG_COROUTINE_MEASURE_STACK 1 /* bool */
+#define CONFIG_COROUTINE_PROTECT_STACK 1 /* bool */
+#define CONFIG_COROUTINE_DEBUG 0 /* bool */
+#define CONFIG_COROUTINE_VALGRIND 1 /* bool */
+#define CONFIG_COROUTINE_GDB 1 /* bool */
+#define CONFIG_COROUTINE_NUM 8
#endif /* _CONFIG_H_ */
diff --git a/lib9p/tests/test_server/fs_flush.c b/lib9p/tests/test_server/fs_flush.c
index 779eb91..e6408d7 100644
--- a/lib9p/tests/test_server/fs_flush.c
+++ b/lib9p/tests/test_server/fs_flush.c
@@ -31,28 +31,23 @@ static struct lib9p_qid flush_file_qid(struct flush_file *self) {
};
}
-static struct lib9p_stat flush_file_stat(struct flush_file *self, struct lib9p_srv_ctx *ctx) {
+static struct lib9p_srv_stat flush_file_stat(struct flush_file *self, struct lib9p_srv_ctx *ctx) {
assert(self);
assert(ctx);
- return (struct lib9p_stat){
- .kern_type = 0,
- .kern_dev = 0,
- .file_qid = flush_file_qid(self),
- .file_mode = 0444,
- .file_atime = UTIL9P_ATIME,
- .file_mtime = UTIL9P_MTIME,
- .file_size = 6,
- .file_name = lib9p_str(self->name),
- .file_owner_uid = lib9p_str("root"),
- .file_owner_gid = lib9p_str("root"),
- .file_last_modified_uid = lib9p_str("root"),
- .file_extension = lib9p_str(NULL),
- .file_owner_n_uid = 0,
- .file_owner_n_gid = 0,
- .file_last_modified_n_uid = 0,
+ return (struct lib9p_srv_stat){
+ .qid = flush_file_qid(self),
+ .mode = 0444,
+ .atime_sec = UTIL9P_ATIME,
+ .mtime_sec = UTIL9P_MTIME,
+ .size = 6,
+ .name = lib9p_str(self->name),
+ .owner_uid = { .name = lib9p_str("root"), .num = 0 },
+ .owner_gid = { .name = lib9p_str("root"), .num = 0 },
+ .last_modifier_uid = { .name = lib9p_str("root"), .num = 0 },
+ .extension = lib9p_str(NULL),
};
}
-static void flush_file_wstat(struct flush_file *self, struct lib9p_srv_ctx *ctx, struct lib9p_stat) {
+static void flush_file_wstat(struct flush_file *self, struct lib9p_srv_ctx *ctx, struct lib9p_srv_stat) {
assert(self);
assert(ctx);
lib9p_error(&ctx->basectx, LIB9P_ERRNO_L_EROFS, "cannot wstat API file");
diff --git a/lib9p/tests/test_server/fs_shutdown.c b/lib9p/tests/test_server/fs_shutdown.c
index e7375ef..d4ae67e 100644
--- a/lib9p/tests/test_server/fs_shutdown.c
+++ b/lib9p/tests/test_server/fs_shutdown.c
@@ -24,34 +24,29 @@ static void shutdown_file_free(struct shutdown_file *self) {
static struct lib9p_qid shutdown_file_qid(struct shutdown_file *self) {
assert(self);
return (struct lib9p_qid){
- .type = LIB9P_QT_FILE,
+ .type = LIB9P_QT_FILE | LIB9P_QT_APPEND,
.vers = 1,
.path = self->pathnum,
};
}
-static struct lib9p_stat shutdown_file_stat(struct shutdown_file *self, struct lib9p_srv_ctx *ctx) {
+static struct lib9p_srv_stat shutdown_file_stat(struct shutdown_file *self, struct lib9p_srv_ctx *ctx) {
assert(self);
assert(ctx);
- return (struct lib9p_stat){
- .kern_type = 0,
- .kern_dev = 0,
- .file_qid = shutdown_file_qid(self),
- .file_mode = 0222,
- .file_atime = UTIL9P_ATIME,
- .file_mtime = UTIL9P_MTIME,
- .file_size = 0,
- .file_name = lib9p_str(self->name),
- .file_owner_uid = lib9p_str("root"),
- .file_owner_gid = lib9p_str("root"),
- .file_last_modified_uid = lib9p_str("root"),
- .file_extension = lib9p_str(NULL),
- .file_owner_n_uid = 0,
- .file_owner_n_gid = 0,
- .file_last_modified_n_uid = 0,
+ return (struct lib9p_srv_stat){
+ .qid = shutdown_file_qid(self),
+ .mode = 0222 | LIB9P_DM_APPEND,
+ .atime_sec = UTIL9P_ATIME,
+ .mtime_sec = UTIL9P_MTIME,
+ .size = 0,
+ .name = lib9p_str(self->name),
+ .owner_uid = { .name=lib9p_str("root"), .num=0 },
+ .owner_gid = { .name=lib9p_str("root"), .num=0 },
+ .last_modifier_uid = { .name=lib9p_str("root"), .num=0 },
+ .extension = lib9p_str(NULL),
};
}
-static void shutdown_file_wstat(struct shutdown_file *self, struct lib9p_srv_ctx *ctx, struct lib9p_stat) {
+static void shutdown_file_wstat(struct shutdown_file *self, struct lib9p_srv_ctx *ctx, struct lib9p_srv_stat) {
assert(self);
assert(ctx);
lib9p_error(&ctx->basectx, LIB9P_ERRNO_L_EROFS, "cannot wstat API file");
@@ -91,10 +86,11 @@ static uint32_t shutdown_fio_iounit(struct shutdown_fio *self) {
return 0;
}
-static uint32_t shutdown_fio_pwrite(struct shutdown_fio *self, struct lib9p_srv_ctx *ctx, void *buf, uint32_t byte_count, uint64_t LM_UNUSED(offset)) {
+static uint32_t shutdown_fio_pwrite(struct shutdown_fio *self, struct lib9p_srv_ctx *ctx, void *buf, uint32_t byte_count, uint64_t offset) {
assert(self);
assert(ctx);
assert(buf);
+ assert(offset == 0);
if (byte_count == 0)
return 0;
for (size_t i = 0; i < self->parent->nlisteners; i++)
diff --git a/lib9p/tests/test_server/fs_whoami.c b/lib9p/tests/test_server/fs_whoami.c
index 653ac4b..8d9752a 100644
--- a/lib9p/tests/test_server/fs_whoami.c
+++ b/lib9p/tests/test_server/fs_whoami.c
@@ -23,10 +23,10 @@ LO_IMPLEMENTATION_C(lib9p_srv_fio, struct whoami_fio, whoami_fio, static);
size_t whoami_len(struct lib9p_srv_ctx *ctx) {
assert(ctx);
- assert(ctx->authinfo);
+ assert(ctx->user);
size_t len = 0;
- uint32_t uid = ctx->authinfo->uid;
+ uint32_t uid = ctx->user->num;
while (uid) {
len++;
uid /= 10;
@@ -34,7 +34,7 @@ size_t whoami_len(struct lib9p_srv_ctx *ctx) {
if (!len)
len++;
len += 2;
- len += ctx->authinfo->uname.len;
+ len += ctx->user->name.len;
return len;
}
@@ -52,29 +52,24 @@ static struct lib9p_qid whoami_file_qid(struct whoami_file *self) {
};
}
-static struct lib9p_stat whoami_file_stat(struct whoami_file *self, struct lib9p_srv_ctx *ctx) {
+static struct lib9p_srv_stat whoami_file_stat(struct whoami_file *self, struct lib9p_srv_ctx *ctx) {
assert(self);
assert(ctx);
- return (struct lib9p_stat){
- .kern_type = 0,
- .kern_dev = 0,
- .file_qid = whoami_file_qid(self),
- .file_mode = 0444,
- .file_atime = UTIL9P_ATIME,
- .file_mtime = UTIL9P_MTIME,
- .file_size = whoami_len(ctx),
- .file_name = lib9p_str(self->name),
- .file_owner_uid = lib9p_str("root"),
- .file_owner_gid = lib9p_str("root"),
- .file_last_modified_uid = lib9p_str("root"),
- .file_extension = lib9p_str(NULL),
- .file_owner_n_uid = 0,
- .file_owner_n_gid = 0,
- .file_last_modified_n_uid = 0,
+ return (struct lib9p_srv_stat){
+ .qid = whoami_file_qid(self),
+ .mode = 0444,
+ .atime_sec = UTIL9P_ATIME,
+ .mtime_sec = UTIL9P_MTIME,
+ .size = whoami_len(ctx),
+ .name = lib9p_str(self->name),
+ .owner_uid = { .name=lib9p_str("root"), .num=0 },
+ .owner_gid = { .name=lib9p_str("root"), .num=0 },
+ .last_modifier_uid = { .name=lib9p_str("root"), .num=0 },
+ .extension = lib9p_str(NULL),
};
}
-static void whoami_file_wstat(struct whoami_file *self, struct lib9p_srv_ctx *ctx, struct lib9p_stat) {
+static void whoami_file_wstat(struct whoami_file *self, struct lib9p_srv_ctx *ctx, struct lib9p_srv_stat) {
assert(self);
assert(ctx);
lib9p_error(&ctx->basectx, LIB9P_ERRNO_L_EROFS, "cannot wstat API file");
@@ -138,7 +133,7 @@ static void whoami_fio_pread(struct whoami_fio *self, struct lib9p_srv_ctx *ctx,
self->buf_len = data_size+1;
}
snprintf(self->buf, self->buf_len, "%"PRIu32" %.*s\n",
- ctx->authinfo->uid, ctx->authinfo->uname.len, ctx->authinfo->uname.utf8);
+ ctx->user->num, ctx->user->name.len, ctx->user->name.utf8);
if (byte_offset > (uint64_t)data_size) {
lib9p_error(&ctx->basectx,
diff --git a/lib9p/tests/testclient-p9p b/lib9p/tests/testclient-p9p
index 9c9f9f2..09ce746 100755
--- a/lib9p/tests/testclient-p9p
+++ b/lib9p/tests/testclient-p9p
@@ -30,7 +30,7 @@ expect_lines \
'--r--r--r-- M 0 root root 6 Oct 7 2024 flush-silent' \
'--r--r--r-- M 0 root root 6 Oct 7 2024 flush-slowread' \
'--r--r--r-- M 0 root root 6 Oct 7 2024 flush-slowsilent' \
- '---w--w--w- M 0 root root 0 Oct 7 2024 shutdown' \
+ 'a--w--w--w- M 0 root root 0 Oct 7 2024 shutdown' \
'--r--r--r-- M 0 root root 9 Oct 7 2024 whoami'
out=$("${client[@]}" ls -l 'Documentation/')
diff --git a/lib9p/tests/testclient-p9p.explog b/lib9p/tests/testclient-p9p.explog
index 7f3953d..54f1e4b 100644
--- a/lib9p/tests/testclient-p9p.explog
+++ b/lib9p/tests/testclient-p9p.explog
@@ -4,14 +4,14 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
> Tversion { tag=NOTAG max_msg_size=8192 version="9P2000" }
< Rversion { tag=NOTAG max_msg_size=4120 version="9P2000" }
-> Tauth { tag=0 afid=0 uname="nobody" aname="" n_uid=0 }
+> Tauth { tag=0 afid=0 uname="nobody" aname="" unum=0 }
< Rerror { tag=0 errstr="authentication not required" errnum=L_EOPNOTSUPP }
-> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" n_uid=0 }
+> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" unum=0 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
> Twalk { tag=0 fid=0 newfid=1 nwname=0 wname=[ ] }
< Rwalk { tag=0 nwqid=0 wqid=[ ] }
> Tstat { tag=0 fid=1 }
-< Rstat { tag=0 stat={ kern_type=0 kern_dev=0 file_qid={ type=(DIR) vers=1 path=1 } file_mode=(DIR|0555) file_atime=1728337905 file_mtime=1728337904 file_size=0 file_name="" file_owner_uid="root" file_owner_gid="root" file_last_modified_uid="root" file_extension="" file_owner_n_uid=0 file_owner_n_gid=0 file_last_modified_n_uid=0 } }
+< Rstat { tag=0 stat={ fstype=0 fsdev=0 qid={ type=(DIR) vers=1 path=1 } mode=(DIR|0555) atime=1728337905 mtime=1728337904 length=0 name="" owner_uname="root" owner_gname="root" last_modifier_uname="root" extension="" owner_unum=0 owner_gnum=0 last_modifier_unum=0 } }
> Tclunk { tag=0 fid=1 }
< Rclunk { tag=0 }
> Twalk { tag=0 fid=0 newfid=1 nwname=0 wname=[ ] }
@@ -26,14 +26,14 @@
< Rclunk { tag=0 }
> Tversion { tag=NOTAG max_msg_size=8192 version="9P2000" }
< Rversion { tag=NOTAG max_msg_size=4120 version="9P2000" }
-> Tauth { tag=0 afid=0 uname="nobody" aname="" n_uid=0 }
+> Tauth { tag=0 afid=0 uname="nobody" aname="" unum=0 }
< Rerror { tag=0 errstr="authentication not required" errnum=L_EOPNOTSUPP }
-> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" n_uid=0 }
+> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" unum=0 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
> Twalk { tag=0 fid=0 newfid=1 nwname=1 wname=[ "Documentation" ] }
< Rwalk { tag=0 nwqid=1 wqid=[ { type=(DIR) vers=1 path=2 } ] }
> Tstat { tag=0 fid=1 }
-< Rstat { tag=0 stat={ kern_type=0 kern_dev=0 file_qid={ type=(DIR) vers=1 path=2 } file_mode=(DIR|0555) file_atime=1728337905 file_mtime=1728337904 file_size=0 file_name="Documentation" file_owner_uid="root" file_owner_gid="root" file_last_modified_uid="root" file_extension="" file_owner_n_uid=0 file_owner_n_gid=0 file_last_modified_n_uid=0 } }
+< Rstat { tag=0 stat={ fstype=0 fsdev=0 qid={ type=(DIR) vers=1 path=2 } mode=(DIR|0555) atime=1728337905 mtime=1728337904 length=0 name="Documentation" owner_uname="root" owner_gname="root" last_modifier_uname="root" extension="" owner_unum=0 owner_gnum=0 last_modifier_unum=0 } }
> Tclunk { tag=0 fid=1 }
< Rclunk { tag=0 }
> Twalk { tag=0 fid=0 newfid=1 nwname=1 wname=[ "Documentation" ] }
@@ -48,9 +48,9 @@
< Rclunk { tag=0 }
> Tversion { tag=NOTAG max_msg_size=8192 version="9P2000" }
< Rversion { tag=NOTAG max_msg_size=4120 version="9P2000" }
-> Tauth { tag=0 afid=0 uname="nobody" aname="" n_uid=0 }
+> Tauth { tag=0 afid=0 uname="nobody" aname="" unum=0 }
< Rerror { tag=0 errstr="authentication not required" errnum=L_EOPNOTSUPP }
-> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" n_uid=0 }
+> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" unum=0 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
> Twalk { tag=0 fid=0 newfid=1 nwname=1 wname=[ "README.md" ] }
< Rwalk { tag=0 nwqid=1 wqid=[ { type=(0) vers=1 path=4 } ] }
@@ -64,9 +64,9 @@
< Rclunk { tag=0 }
> Tversion { tag=NOTAG max_msg_size=8192 version="9P2000" }
< Rversion { tag=NOTAG max_msg_size=4120 version="9P2000" }
-> Tauth { tag=0 afid=0 uname="nobody" aname="" n_uid=0 }
+> Tauth { tag=0 afid=0 uname="nobody" aname="" unum=0 }
< Rerror { tag=0 errstr="authentication not required" errnum=L_EOPNOTSUPP }
-> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" n_uid=0 }
+> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" unum=0 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
> Twalk { tag=0 fid=0 newfid=1 nwname=2 wname=[ "Documentation", "x" ] }
< Rwalk { tag=0 nwqid=2 wqid=[ { type=(DIR) vers=1 path=2 }, { type=(0) vers=1 path=3 } ] }
@@ -80,26 +80,26 @@
< Rclunk { tag=0 }
> Tversion { tag=NOTAG max_msg_size=8192 version="9P2000" }
< Rversion { tag=NOTAG max_msg_size=4120 version="9P2000" }
-> Tauth { tag=0 afid=0 uname="nobody" aname="" n_uid=0 }
+> Tauth { tag=0 afid=0 uname="nobody" aname="" unum=0 }
< Rerror { tag=0 errstr="authentication not required" errnum=L_EOPNOTSUPP }
-> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" n_uid=0 }
+> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" unum=0 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
> Twalk { tag=0 fid=0 newfid=1 nwname=2 wname=[ "Documentation", "x" ] }
< Rwalk { tag=0 nwqid=2 wqid=[ { type=(DIR) vers=1 path=2 }, { type=(0) vers=1 path=3 } ] }
> Tstat { tag=0 fid=1 }
-< Rstat { tag=0 stat={ kern_type=0 kern_dev=0 file_qid={ type=(0) vers=1 path=3 } file_mode=(0444) file_atime=1728337905 file_mtime=1728337904 file_size=166 file_name="x" file_owner_uid="root" file_owner_gid="root" file_last_modified_uid="root" file_extension="" file_owner_n_uid=0 file_owner_n_gid=0 file_last_modified_n_uid=0 } }
+< Rstat { tag=0 stat={ fstype=0 fsdev=0 qid={ type=(0) vers=1 path=3 } mode=(0444) atime=1728337905 mtime=1728337904 length=166 name="x" owner_uname="root" owner_gname="root" last_modifier_uname="root" extension="" owner_unum=0 owner_gnum=0 last_modifier_unum=0 } }
> Tclunk { tag=0 fid=1 }
< Rclunk { tag=0 }
> Tversion { tag=NOTAG max_msg_size=8192 version="9P2000" }
< Rversion { tag=NOTAG max_msg_size=4120 version="9P2000" }
-> Tauth { tag=0 afid=0 uname="nobody" aname="" n_uid=0 }
+> Tauth { tag=0 afid=0 uname="nobody" aname="" unum=0 }
< Rerror { tag=0 errstr="authentication not required" errnum=L_EOPNOTSUPP }
-> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" n_uid=0 }
+> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" unum=0 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
> Twalk { tag=0 fid=0 newfid=1 nwname=1 wname=[ "shutdown" ] }
-< Rwalk { tag=0 nwqid=1 wqid=[ { type=(0) vers=1 path=5 } ] }
+< Rwalk { tag=0 nwqid=1 wqid=[ { type=(APPEND) vers=1 path=5 } ] }
> Topen { tag=0 fid=1 mode=(TRUNC|MODE_WRITE) }
-< Ropen { tag=0 qid={ type=(0) vers=1 path=5 } iounit=0 }
+< Ropen { tag=0 qid={ type=(APPEND) vers=1 path=5 } iounit=0 }
> Twrite { tag=0 fid=1 offset=0 count=2 data="1\n" }
< Rwrite { tag=0 count=2 }
> Tclunk { tag=0 fid=1 }
diff --git a/lib9p/tests/testclient-sess.c b/lib9p/tests/testclient-sess.c
index 561c0c9..7cb7f97 100644
--- a/lib9p/tests/testclient-sess.c
+++ b/lib9p/tests/testclient-sess.c
@@ -95,9 +95,9 @@ int main(int argc, char *argv[]) {
send9p(Tversion, .tag=0, .max_msg_size=(8*1024), .version=lib9p_str("9P2000.u"));
recv9p(); /* Rversion */
ctx.version = LIB9P_VER_9P2000_u;
- send9p(Tattach, .tag=0, .fid=0, .afid=LIB9P_FID_NOFID, .uname=lib9p_str("alice"), .n_uid=1000, .aname=lib9p_str(""));
+ send9p(Tattach, .tag=0, .fid=0, .afid=LIB9P_FID_NOFID, .uname=lib9p_str("alice"), .unum=1000, .aname=lib9p_str(""));
recv9p(); /* Rattach */
- send9p(Tattach, .tag=0, .fid=1, .afid=LIB9P_FID_NOFID, .uname=lib9p_str("bob"), .n_uid=1001, .aname=lib9p_str(""));
+ send9p(Tattach, .tag=0, .fid=1, .afid=LIB9P_FID_NOFID, .uname=lib9p_str("bob"), .unum=1001, .aname=lib9p_str(""));
recv9p(); /* Rattach */
wname[0] = lib9p_str("whoami"); send9p(Twalk, .tag=0, .fid=0, .newfid=2, .nwname=1, .wname=wname);
recv9p(); /* Rwalk */
diff --git a/lib9p/tests/testclient-sess.explog b/lib9p/tests/testclient-sess.explog
index 74a2cd7..a3838ac 100644
--- a/lib9p/tests/testclient-sess.explog
+++ b/lib9p/tests/testclient-sess.explog
@@ -14,9 +14,9 @@
# ext version, users ###########################################################
> Tversion { tag=0 max_msg_size=8192 version="9P2000.u" }
< Rversion { tag=0 max_msg_size=4120 version="9P2000.u" }
-> Tattach { tag=0 fid=0 afid=NOFID uname="alice" aname="" n_uid=1000 }
+> Tattach { tag=0 fid=0 afid=NOFID uname="alice" aname="" unum=1000 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
-> Tattach { tag=0 fid=1 afid=NOFID uname="bob" aname="" n_uid=1001 }
+> Tattach { tag=0 fid=1 afid=NOFID uname="bob" aname="" unum=1001 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
> Twalk { tag=0 fid=0 newfid=2 nwname=1 wname=[ "whoami" ] }
< Rwalk { tag=0 nwqid=1 wqid=[ { type=(0) vers=1 path=8 } ] }
@@ -34,7 +34,7 @@
# walk #########################################################################
> Tversion { tag=0 max_msg_size=8192 version="9P2000" }
< Rversion { tag=0 max_msg_size=4120 version="9P2000" }
-> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" n_uid=0 }
+> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" unum=0 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
# dup
@@ -83,7 +83,7 @@
# flush ########################################################################
> Tversion { tag=0 max_msg_size=8192 version="9P2000" }
< Rversion { tag=0 max_msg_size=4120 version="9P2000" }
-> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" n_uid=0 }
+> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" unum=0 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
# flush, but original response comes back first
@@ -146,11 +146,11 @@
# shutdown #####################################################################
> Tversion { tag=0 max_msg_size=8192 version="9P2000" }
< Rversion { tag=0 max_msg_size=4120 version="9P2000" }
-> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" n_uid=0 }
+> Tattach { tag=0 fid=0 afid=NOFID uname="nobody" aname="" unum=0 }
< Rattach { tag=0 qid={ type=(DIR) vers=1 path=1 } }
> Twalk { tag=0 fid=0 newfid=0 nwname=1 wname=[ "shutdown" ] }
-< Rwalk { tag=0 nwqid=1 wqid=[ { type=(0) vers=1 path=5 } ] }
+< Rwalk { tag=0 nwqid=1 wqid=[ { type=(APPEND) vers=1 path=5 } ] }
> Topen { tag=0 fid=0 mode=(MODE_WRITE) }
-< Ropen { tag=0 qid={ type=(0) vers=1 path=5 } iounit=0 }
+< Ropen { tag=0 qid={ type=(APPEND) vers=1 path=5 } iounit=0 }
> Twrite { tag=0 fid=0 offset=0 count=2 data="1\n" }
< Rwrite { tag=0 count=2 }