Expand PMF_FN_* macros.
[netbsd-mini2440.git] / sys / compat / osf1 / osf1_cvt.h
blob2693e31aba5b70e922537cb46d1e177c9f315452
1 /* $NetBSD: osf1_cvt.h,v 1.10 2005/12/11 12:20:23 christos Exp $ */
3 /*
4 * Copyright (c) 1999 Christopher G. Demetriou. All rights reserved.
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:
9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer.
11 * 2. Redistributions in binary form must reproduce the above copyright
12 * notice, this list of conditions and the following disclaimer in the
13 * documentation and/or other materials provided with the distribution.
14 * 3. All advertising materials mentioning features or use of this software
15 * must display the following acknowledgement:
16 * This product includes software developed by Christopher G. Demetriou
17 * for the NetBSD Project.
18 * 4. The name of the author may not be used to endorse or promote products
19 * derived from this software without specific prior written permission
21 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
22 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
23 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
24 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
25 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
26 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
30 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
33 #ifndef _COMPAT_OSF1_OSF1_CVT_H_
34 #define _COMPAT_OSF1_OSF1_CVT_H_
36 #include <sys/param.h>
37 #include <sys/proc.h>
38 #include <sys/mount.h>
39 #include <sys/resource.h>
40 #include <sys/signal.h>
41 #include <sys/stat.h>
42 #include <sys/fcntl.h>
44 #include <compat/common/compat_util.h>
46 #define osf1_cvt_dev_from_native(dev) \
47 osf1_makedev(major(dev), minor(dev))
48 #define osf1_cvt_dev_to_native(dev) \
49 makedev(osf1_major(dev), osf1_minor(dev))
51 void osf1_cvt_flock_from_native(const struct flock *nf,
52 struct osf1_flock *of);
53 int osf1_cvt_flock_to_native(const struct osf1_flock *of,
54 struct flock *nf);
55 struct msghdr;
56 int osf1_cvt_msghdr_xopen_to_native(const struct osf1_msghdr_xopen *omh,
57 struct msghdr *nmh);
58 int osf1_cvt_pathconf_name_to_native(int oname, int *bnamep);
59 void osf1_cvt_rusage_from_native(const struct rusage *nru,
60 struct osf1_rusage *oru);
61 void osf1_cvt_sigaction_from_native(const struct sigaction *nsa,
62 struct osf1_sigaction *osa);
63 int osf1_cvt_sigaction_to_native(const struct osf1_sigaction *osa,
64 struct sigaction *nsa);
65 void osf1_cvt_sigset_from_native(const sigset_t *nss, osf1_sigset_t *oss);
66 int osf1_cvt_sigset_to_native(const osf1_sigset_t *oss, sigset_t *nss);
67 void osf1_cvt_stat_from_native(const struct stat *nst,
68 struct osf1_stat *ost);
69 void osf1_cvt_stat2_from_native(const struct stat *nst,
70 struct osf1_stat2 *ost);
71 void osf1_cvt_statfs_from_native(const struct statvfs *nsfs,
72 struct osf1_statfs *osfs);
74 extern const int native_to_osf1_errno[];
75 extern const int osf1_to_native_signo[];
76 extern const int native_to_osf1_signo[];
78 extern const struct emul_flags_xtab osf1_access_flags_xtab[];
79 extern const struct emul_flags_xtab osf1_fcntl_getsetfd_flags_rxtab[];
80 extern const struct emul_flags_xtab osf1_fcntl_getsetfd_flags_xtab[];
81 extern const struct emul_flags_xtab osf1_fcntl_getsetfl_flags_rxtab[];
82 extern const struct emul_flags_xtab osf1_fcntl_getsetfl_flags_xtab[];
83 extern const struct emul_flags_xtab osf1_mmap_flags_xtab[];
84 extern const struct emul_flags_xtab osf1_mmap_prot_xtab[];
85 extern const struct emul_flags_xtab osf1_nfs_mount_flags_xtab[];
86 extern const struct emul_flags_xtab osf1_open_flags_rxtab[];
87 extern const struct emul_flags_xtab osf1_open_flags_xtab[];
88 extern const struct emul_flags_xtab osf1_reboot_opt_xtab[];
89 extern const struct emul_flags_xtab osf1_sendrecv_msg_flags_xtab[];
90 extern const struct emul_flags_xtab osf1_sigaction_flags_rxtab[];
91 extern const struct emul_flags_xtab osf1_sigaction_flags_xtab[];
92 extern const struct emul_flags_xtab osf1_sigaltstack_flags_rxtab[];
93 extern const struct emul_flags_xtab osf1_sigaltstack_flags_xtab[];
94 extern const struct emul_flags_xtab osf1_wait_options_xtab[];
96 #endif /* _COMPAT_OSF1_OSF1_CVT_H_ */