| 1 | /* $Id: os-u4_0.h,v 5.2 91/03/03 20:22:45 jsp Alpha $ */ |
| 2 | |
| 3 | /* |
| 4 | * Ultrix 4.0 definitions for Amd (automounter) |
| 5 | * from Chris Lindblad <cjl@ai.mit.edu> |
| 6 | * |
| 7 | * Copyright (c) 1989 Jan-Simon Pendry |
| 8 | * Copyright (c) 1989 Imperial College of Science, Technology & Medicine |
| 9 | * Copyright (c) 1989 The Regents of the University of California. |
| 10 | * All rights reserved. |
| 11 | * |
| 12 | * This code is derived from software contributed to Berkeley by |
| 13 | * Jan-Simon Pendry at Imperial College, London. |
| 14 | * |
| 15 | * Redistribution and use in source and binary forms are permitted provided |
| 16 | * that: (1) source distributions retain this entire copyright notice and |
| 17 | * comment, and (2) distributions including binaries display the following |
| 18 | * acknowledgement: ``This product includes software developed by the |
| 19 | * University of California, Berkeley and its contributors'' in the |
| 20 | * documentation or other materials provided with the distribution and in |
| 21 | * all advertising materials mentioning features or use of this software. |
| 22 | * Neither the name of the University nor the names of its contributors may |
| 23 | * be used to endorse or promote products derived from this software without |
| 24 | * specific prior written permission. |
| 25 | * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED |
| 26 | * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF |
| 27 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. |
| 28 | * |
| 29 | * @(#)os-u4_0.h 5.1 (Berkeley) %G% |
| 30 | */ |
| 31 | |
| 32 | /* |
| 33 | * Does the compiler grok void * |
| 34 | */ |
| 35 | #undef VOIDP |
| 36 | |
| 37 | /* |
| 38 | * Which version of the Sun RPC library we are using |
| 39 | * This is the implementation release number, not |
| 40 | * the protocol revision number. |
| 41 | */ |
| 42 | #define RPC_3 |
| 43 | |
| 44 | /* |
| 45 | * Which version of the NFS interface are we using. |
| 46 | * This is the implementation release number, not |
| 47 | * the protocol revision number. |
| 48 | */ |
| 49 | #define NFS_3 |
| 50 | |
| 51 | /* |
| 52 | * Byte ordering |
| 53 | */ |
| 54 | #undef ARCH_ENDIAN |
| 55 | #if defined(vax) || defined(mips) |
| 56 | #define ARCH_ENDIAN "little" |
| 57 | #endif |
| 58 | |
| 59 | /* |
| 60 | * The mount table is obtained from the kernel |
| 61 | */ |
| 62 | #undef UPDATE_MTAB |
| 63 | |
| 64 | /* |
| 65 | * No mntent info on Ultrix |
| 66 | */ |
| 67 | #undef MNTENT_HDR |
| 68 | |
| 69 | /* |
| 70 | * No support for syslog() |
| 71 | */ |
| 72 | #define HAS_SYSLOG |
| 73 | |
| 74 | /* |
| 75 | * Name of filesystem types |
| 76 | */ |
| 77 | #define MOUNT_TYPE_NFS GT_NFS |
| 78 | #define MOUNT_TYPE_UFS GT_ULTRIX |
| 79 | #undef MTAB_TYPE_UFS |
| 80 | #define MTAB_TYPE_UFS "ufs" |
| 81 | |
| 82 | /* |
| 83 | * Name of mount & unmount system calls |
| 84 | */ |
| 85 | #undef MOUNT_TRAP |
| 86 | #define MOUNT_TRAP(type, mnt, flag, mnt_data) \ |
| 87 | mount(mnt->mnt_fsname, mnt->mnt_dir, flag, type, mnt_data) |
| 88 | #undef UNMOUNT_TRAP |
| 89 | #define UNMOUNT_TRAP(mnt) umount(mnt->mnt_passno) |
| 90 | |
| 91 | /* |
| 92 | * Miscellaneous Ultrix bits |
| 93 | */ |
| 94 | #define M_RDONLY M_RONLY |
| 95 | |
| 96 | #define MNTMAXSTR 128 |
| 97 | |
| 98 | #define MNTTYPE_UFS "ufs" /* Un*x file system */ |
| 99 | #define MNTTYPE_NFS "nfs" /* network file system */ |
| 100 | #define MNTTYPE_IGNORE "ignore" /* No type specified, ignore this entry */ |
| 101 | |
| 102 | #define MNTOPT_RO "ro" /* read only */ |
| 103 | #define MNTOPT_RW "rw" /* read/write */ |
| 104 | #define MNTOPT_QUOTA "quota" /* quotas */ |
| 105 | #define MNTOPT_NOQUOTA "noquota" /* no quotas */ |
| 106 | #define MNTOPT_HARD "hard" /* hard mount */ |
| 107 | #define MNTOPT_SOFT "soft" /* soft mount */ |
| 108 | #define MNTOPT_INTR "intr" /* interrupts allowed */ |
| 109 | |
| 110 | #define MNTOPT_NOSUID "nosuid" /* no set uid allowed */ |
| 111 | |
| 112 | struct mntent { |
| 113 | char *mnt_fsname; /* name of mounted file system */ |
| 114 | char *mnt_dir; /* file system path prefix */ |
| 115 | char *mnt_type; /* MNTTYPE_* */ |
| 116 | char *mnt_opts; /* MNTOPT* */ |
| 117 | int mnt_freq; /* dump frequency, in days */ |
| 118 | int mnt_passno; /* pass number on parallel fsck */ |
| 119 | }; |
| 120 | #define MOUNTED "/etc/mtab" |
| 121 | |
| 122 | #define NFS_HDR "misc-ultrix.h" |
| 123 | #define UFS_HDR "misc-ultrix.h" |
| 124 | |
| 125 | #define NEED_CLNT_SPERRNO |
| 126 | |
| 127 | #define nfs_args nfs_gfs_mount |
| 128 | #define ULTRIX_HACK /* Should be handled better than this !! */ |
| 129 | #define NEED_MNTOPT_PARSER |
| 130 | |
| 131 | /* |
| 132 | * How to get a mount list |
| 133 | */ |
| 134 | #undef READ_MTAB_FROM_FILE |
| 135 | #define READ_MTAB_ULTRIX_STYLE |
| 136 | |
| 137 | /* |
| 138 | * Need precise length links |
| 139 | */ |
| 140 | #define PRECISE_SYMLINKS |