1 /* $Id: os-defaults.h,v 5.2 90/06/23 22:20:44 jsp Rel $ */
2 
3 /*
4  * Common OS definitions.  These may be overridden in
5  * the OS specific files ("os-foo.h").
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  * %sccs.include.redist.c%
16  *
17  *	@(#)os-defaults.h	5.1 (Berkeley) 06/29/90
18  */
19 
20 /*
21  * What level of AMD are we backward compatible with?
22  * This only applies to externally visible characteristics.
23  * Rev.Minor.Branch.Patch (2 digits each)
24  */
25 #define	AMD_COMPAT	5000000		/* 5.0 */
26 
27 /*
28  * What type is free(void*) returning?
29  */
30 #define FREE_RETURN_TYPE	void
31 
32 /*
33  * Is the mount table mirrored in software
34  */
35 #define	UPDATE_MTAB
36 
37 /*
38  * Where to get union wait
39  */
40 #define	WAIT	<sys/wait.h>
41 
42 /*
43  * Where to get mount entry info
44  */
45 #define	MNTENT_HDR	<mntent.h>
46 
47 /*
48  * Include support for syslog()
49  */
50 #define	HAS_SYSLOG
51 
52 /*
53  * Byte ordering
54  */
55 #define	ARCH_ENDIAN	"unknown"
56 
57 /*
58  * Name of filesystem types
59  */
60 #define	MTAB_TYPE_NFS	"nfs"
61 #define	MTAB_TYPE_UFS	"4.2"
62 
63 /*
64  * Name of mount & unmount system calls
65  *
66  * NOTE:
67  *  UNMOUNT_TRAP takes a struct mntent *
68  */
69 #define	MOUNT_TRAP(type, mnt, flags, mnt_data) \
70 	mount(type, mnt->mnt_dir, flags, mnt_data)
71 #define	UNMOUNT_TRAP(mnt)	unmount(mnt->mnt_dir)
72 
73 /*
74  * How to unmount filesystems.
75  * NEED_UMOUNT_FS includes code to scan the mount table
76  * to find the correct information for the unmount system
77  * call.  Some systems, such as 4.4bsd, do not require
78  * this - they can just do an unmount system call directly.
79  */
80 #define	NEED_UMOUNT_FS
81 #define	UMOUNT_FS(dir)	umount_fs(dir)
82 
83 /*
84  * Type of a file handle
85  */
86 #define	NFS_FH_TYPE	fhandle_t *
87 #define	NFS_FH_DREF(dst, src) { (dst) = (src); }
88 
89 /*
90  * How to copy an address into an NFS filehandle
91  */
92 #define	NFS_SA_DREF(dst, src) { (dst).addr = (src); }
93 
94 /*
95  * Type of filesystem type
96  */
97 #define	MTYPE_TYPE	int
98 
99 /*
100  * How to get a mount list
101  */
102 #define	READ_MTAB_FROM_FILE
103