The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/compat/osf1/osf1.h

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 /* $NetBSD: osf1.h,v 1.27 2005/12/11 12:20:23 christos Exp $ */
    2 
    3 /*
    4  * Copyright (c) 1999 Christopher G. Demetriou.  All rights reserved.
    5  *
    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
   20  *
   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.
   31  */
   32 
   33 #ifndef _COMPAT_OSF1_OSF1_H_
   34 #define _COMPAT_OSF1_OSF1_H_
   35 
   36 /*
   37  * Collected OSF/1 definitions and structures, sorted by OSF/1 header.
   38  * Error numbers (errno.h) aren't here, since they're likely to change
   39  * (additions) more often.
   40  *
   41  * This file is up to date as of Digital UNIX V4.0.
   42  */
   43 
   44 #include <sys/types.h>
   45 #include <compat/osf1/osf1_errno.h>
   46 #include <compat/osf1/osf1_signal.h>
   47 
   48 /*
   49  * type and structure definitions used by other structures
   50  */
   51 
   52 typedef int16_t         osf1_short;
   53 typedef int32_t         osf1_int;
   54 typedef int64_t         osf1_long;
   55 typedef u_int32_t       osf1_u_int;
   56 
   57 typedef int32_t         osf1_dev_t;
   58 typedef u_int32_t       osf1_ino_t;
   59 typedef u_int32_t       osf1_mode_t;
   60 typedef u_int16_t       osf1_nlink_t;
   61 typedef u_int32_t       osf1_uid_t;
   62 typedef u_int32_t       osf1_gid_t;
   63 typedef u_int64_t       osf1_off_t;
   64 typedef int32_t         osf1_time_t;
   65 typedef u_int32_t       osf1_uint_t;
   66 typedef u_int64_t       osf1_sigset_t;
   67 typedef u_int64_t       osf1_size_t;
   68 typedef u_int64_t       osf1_fsid_t;
   69 typedef u_int64_t       osf1_rlim_t;
   70 typedef void            *osf1_data_ptr; /* XXX hard to fix size */
   71 typedef void            *osf1_fcn_ptr;  /* XXX hard to fix size, bogus */
   72 typedef osf1_int        osf1_key_t;
   73 typedef osf1_int        osf1_pid_t;
   74 typedef u_int64_t       osf1_blksize_t;
   75 typedef u_int64_t       osf1_blkcnt_t;
   76 
   77 struct osf1_timeval {                           /* time.h */
   78         osf1_time_t     tv_sec;
   79         osf1_int        tv_usec;
   80 };
   81 
   82 
   83 /* access.h */
   84 
   85 #define OSF1_F_OK                       0               /* pseudo-flag */
   86 #define OSF1_X_OK                       0x01
   87 #define OSF1_W_OK                       0x02
   88 #define OSF1_R_OK                       0x04
   89 
   90 
   91 /* auxv.h */
   92 
   93 union osf1_auxv_data {
   94         osf1_long       a_val;
   95         osf1_data_ptr   a_ptr;
   96         osf1_fcn_ptr    a_fcn;
   97 };
   98 
   99 struct osf1_auxv {
  100         osf1_int        a_type;
  101         union osf1_auxv_data a_un;
  102 };
  103 
  104 /* auxv entry types */
  105 #define OSF1_AT_NULL                    0
  106 #define OSF1_AT_IGNORE                  1
  107 #define OSF1_AT_EXECFD                  2
  108 #define OSF1_AT_PHDR                    3
  109 #define OSF1_AT_PHENT                   4
  110 #define OSF1_AT_PHNUM                   5
  111 #define OSF1_AT_PAGESZ                  6
  112 #define OSF1_AT_BASE                    7
  113 #define OSF1_AT_FLAGS                   8
  114 #define OSF1_AT_ENTRY                   9
  115 #define OSF1_AT_EXEC_FILENAME           1001
  116 #define OSF1_AT_EXEC_LOADER_FILENAME    1002
  117 #define OSF1_AT_EXEC_LOADER_FLAGS       1003
  118 
  119 
  120 /* exec.h/ldr_exec.h */
  121 
  122 #define OSF1_LDR_EXEC_DEFAULT_LOADER    "/sbin/loader"
  123 
  124 /* exec_with_loader()/OSF1_AT_EXEC_LOADER_FLAGS flags regions */
  125 #define OSF1_LDR_EXEC_SYSTEM_MASK       0xffff0000
  126 #define OSF1_LDR_EXEC_USER_MASK         0xffff0000
  127 
  128 /* OSF1_AT_EXEC_LOADER_FLAGS flags */
  129 #define OSF1_LDR_EXEC_NOPRIVS_F         0x10000000
  130 #define OSF1_LDR_EXEC_PTRACE_F          0x20000000
  131 #define OSF1_LDR_EXEC_SETGID_F          0x40000000
  132 #define OSF1_LDR_EXEC_SETUID_F          0x80000000
  133 
  134 
  135 /* fcntl.h */
  136 
  137 /* fcntl ops */
  138 #define OSF1_F_DUPFD            0
  139 #define OSF1_F_GETFD            1       /* uses flags, see below */
  140 #define OSF1_F_SETFD            2       /* uses flags, see below */
  141 #define OSF1_F_GETFL            3       /* uses flags, see below */
  142 #define OSF1_F_SETFL            4       /* uses flags, see below */
  143 #define OSF1_F_GETOWN           5
  144 #define OSF1_F_SETOWN           6
  145 #define OSF1_F_GETLK            7       /* uses osf1_flock, see below */
  146 #define OSF1_F_SETLK            8       /* uses osf1_flock, see below */
  147 #define OSF1_F_SETLKW           9       /* uses osf1_flock, see below */
  148 #define OSF1_F_RGETLK           10      /* [lock mgr op] */
  149 #define OSF1_F_RSETLK           11      /* [lock mgr op] */
  150 #define OSF1_F_CNVT             12      /* [lock mgr op] */
  151 #define OSF1_F_RSETLKW          13      /* [lock mgr op] */
  152 #define OSF1_F_PURGEFS          14      /* [lock mgr op] */
  153 #define OSF1_F_PURGENFS         15      /* [DECsafe op] */
  154 
  155 /* fcntl GETFD/SETFD flags */
  156 #define OSF1_FD_CLOEXEC         1
  157 
  158 /* fcntl GETFL/SETFL flags, in addition to the O_* flags below */
  159 #define OSF1_FASYNC             0x00000040
  160 
  161 /* struct osf1_flock, for GETLK/SETLK/SETLKW */
  162 struct osf1_flock {
  163         osf1_short      l_type;
  164         osf1_short      l_whence;
  165         osf1_off_t      l_start;
  166         osf1_off_t      l_len;
  167         osf1_pid_t      l_pid;
  168 };
  169 
  170 /* GETLK/SETLK/SETLKW locking types */
  171 #define OSF1_F_RDLCK    1
  172 #define OSF1_F_WRLCK    2
  173 #define OSF1_F_UNLCK    8
  174 
  175 /* open flags */
  176 #define OSF1_O_RDONLY           0x00000000
  177 #define OSF1_O_WRONLY           0x00000001
  178 #define OSF1_O_RDWR             0x00000002
  179 #define OSF1_O_ACCMODE          0x00000003      /* mask of RD and WR bits */
  180 #define OSF1_O_NONBLOCK         0x00000004
  181 #define OSF1_O_APPEND           0x00000008
  182 /* no                           0x00000010 */
  183 #define OSF1_O_DEFER            0x00000020
  184 /* no                           0x00000040 */
  185 /* no                           0x00000080 */
  186 /* no                           0x00000100 */
  187 #define OSF1_O_CREAT            0x00000200
  188 #define OSF1_O_TRUNC            0x00000400
  189 #define OSF1_O_EXCL             0x00000800
  190 #define OSF1_O_NOCTTY           0x00001000
  191 #define OSF1_O_SYNC             0x00004000
  192 #define OSF1_O_NDELAY           0x00008000
  193 #define OSF1_O_DRD              0x00008000      /* == O_NDELAY, DON'T USE */
  194 /* no                           0x00010000 */
  195 /* no                           0x00020000 */
  196 /* no                           0x00040000 */
  197 #define OSF1_O_DSYNC            0x00080000
  198 #define OSF1_O_RSYNC            0x00100000
  199 /* no                           0x00200000+ */
  200 
  201 
  202 /* ioctl.h */
  203 
  204 #define OSF1_IOCPARM_MASK       0x1fff
  205 #define OSF1_IOCPARM_LEN(x)     (((x) >> 16) & OSF1_IOCPARM_MASK)
  206 #define OSF1_IOCGROUP(x)        (((x) >> 8) & 0xff)
  207 #define OSF1_IOCCMD(x)          ((x) & 0xff)
  208 
  209 #define OSF1_IOCPARM_MAX        8192
  210 #define OSF1_IOC_VOID           0x20000000
  211 #define OSF1_IOC_OUT            0x40000000
  212 #define OSF1_IOC_IN             0x80000000
  213 #define OSF1_IOC_INOUT          (OSF1_IOC_IN|OSF1_IOC_OUT)
  214 #define OSF1_IOC_DIRMASK        0xe0000000
  215 
  216 
  217 /* mman.h */
  218 
  219 /* protection mask */
  220 #define OSF1_PROT_NONE          0               /* pseudo-flag */
  221 #define OSF1_PROT_READ          0x0001
  222 #define OSF1_PROT_WRITE         0x0002
  223 #define OSF1_PROT_EXEC          0x0004
  224 
  225 /* mmap flags */
  226 #define OSF1_MAP_SHARED         0x0001
  227 #define OSF1_MAP_PRIVATE        0x0002
  228 
  229 #define OSF1_MAP_FILE           0               /* pseudo-flag */
  230 #define OSF1_MAP_ANON           0x0010
  231 #define OSF1_MAP_TYPE           0x00f0
  232 
  233 #define OSF1_MAP_FIXED          0x0100
  234 #define OSF1_MAP_VARIABLE       0               /* pseudo-flag */
  235 
  236 #define OSF1_MAP_HASSEMAPHORE   0x0200
  237 #define OSF1_MAP_INHERIT        0x0400
  238 #define OSF1_MAP_UNALIGNED      0x0800
  239 
  240 /* madvise operations */
  241 #define OSF1_MADV_NORMAL        0
  242 #define OSF1_MADV_RANDOM        1
  243 #define OSF1_MADV_SEQUENTIAL    2
  244 #define OSF1_MADV_WILLNEED      3
  245 #define OSF1_MADV_DONTNEED_COMPAT 4
  246 #define OSF1_MADV_SPACEAVAIL    5
  247 #define OSF1_MADV_DONTNEED      6
  248 
  249 
  250 /* mount.h */
  251 
  252 /* file system type numbers */
  253 #define OSF1_MOUNT_NONE         0
  254 #define OSF1_MOUNT_UFS          1
  255 #define OSF1_MOUNT_NFS          2
  256 #define OSF1_MOUNT_MFS          3
  257 #define OSF1_MOUNT_PC           4
  258 #define OSF1_MOUNT_S5FS         5
  259 #define OSF1_MOUNT_CDFS         6
  260 #define OSF1_MOUNT_DFS          7
  261 #define OSF1_MOUNT_EFS          8
  262 #define OSF1_MOUNT_PROCFS       9
  263 #define OSF1_MOUNT_MSFS         10
  264 #define OSF1_MOUNT_FFM          11
  265 #define OSF1_MOUNT_FDFS         12
  266 #define OSF1_MOUNT_ADDON        13
  267 #define OSF1_MOUNT_NFS3         14
  268 
  269 #define OSF1_MNAMELEN           90
  270 
  271 /* MFS mount argument structure */
  272 struct osf1_mfs_args {
  273         osf1_data_ptr   name;
  274         osf1_data_ptr   base;
  275         osf1_u_int      size;
  276 };
  277 
  278 /* NFS mount argument structure */
  279 struct osf1_nfs_args {
  280         osf1_data_ptr   addr;
  281         osf1_data_ptr   fh;
  282         osf1_int        flags;
  283         osf1_int        wsize;
  284         osf1_int        rsize;
  285         osf1_int        timeo;
  286         osf1_int        retrans;
  287         osf1_data_ptr   hostname;
  288         osf1_int        acregmin;
  289         osf1_int        acregmax;
  290         osf1_int        acdirmin;
  291         osf1_int        acdirmax;
  292         osf1_data_ptr   netname;
  293         osf1_data_ptr   pathconf;
  294 };
  295 
  296 /* NFS mount argument structure flags */
  297 #define OSF1_NFSMNT_SOFT        0x00000001
  298 #define OSF1_NFSMNT_WSIZE       0x00000002
  299 #define OSF1_NFSMNT_RSIZE       0x00000004
  300 #define OSF1_NFSMNT_TIMEO       0x00000008
  301 #define OSF1_NFSMNT_RETRANS     0x00000010
  302 #define OSF1_NFSMNT_HOSTNAME    0x00000020
  303 #define OSF1_NFSMNT_INT         0x00000040
  304 #define OSF1_NFSMNT_NOCONN      0x00000080
  305 #define OSF1_NFSMNT_NOAC        0x00000100
  306 #define OSF1_NFSMNT_ACREGMIN    0x00000200
  307 #define OSF1_NFSMNT_ACREGMAX    0x00000400
  308 #define OSF1_NFSMNT_ACDIRMIN    0x00000800
  309 #define OSF1_NFSMNT_ACDIRMAX    0x00001000
  310 #define OSF1_NFSMNT_NOCTO       0x00002000
  311 #define OSF1_NFSMNT_POSIX       0x00004000
  312 #define OSF1_NFSMNT_AUTO        0x00008000
  313 #define OSF1_NFSMNT_SEC         0x00010000
  314 #define OSF1_NFSMNT_TCP         0x00020000
  315 #define OSF1_NFSMNT_PROPLIST    0x00040000
  316 /* no                           0x00080000+ */
  317 
  318 /* union of all mount argument structures */
  319 union osf1_mount_info {
  320         struct osf1_mfs_args mfs_args;
  321         struct osf1_nfs_args nfs_args;
  322         char            pad[80];
  323 };
  324 
  325 /* statfs structure */
  326 struct osf1_statfs {
  327         osf1_short      f_type;
  328         osf1_short      f_flags;
  329         osf1_int        f_fsize;
  330         osf1_int        f_bsize;
  331         osf1_int        f_blocks;
  332         osf1_int        f_bfree;
  333         osf1_int        f_bavail;
  334         osf1_int        f_files;
  335         osf1_int        f_ffree;
  336         osf1_fsid_t     f_fsid;
  337         osf1_int        f_spare[9];
  338         char            f_mntonname[OSF1_MNAMELEN];
  339         char            f_mntfromname[OSF1_MNAMELEN];
  340         union osf1_mount_info mount_info;
  341 };
  342 
  343 
  344 /* reboot.h */
  345 
  346 /* reboot flags */
  347 #define OSF1_RB_AUTOBOOT        0               /* pseudo-flag */
  348 
  349 #define OSF1_RB_ASKNAME         0x0001
  350 #define OSF1_RB_SINGLE          0x0002
  351 #define OSF1_RB_NOSYNC          0x0004
  352 #define OSF1_RB_KDB             0x0004          /* == RB_NOSYNC; boot only? */
  353 #define OSF1_RB_HALT            0x0008
  354 #define OSF1_RB_INITNAME        0x0010
  355 #define OSF1_RB_DFLTROOT        0x0020
  356 #define OSF1_RB_ALTBOOT         0x0040
  357 #define OSF1_RB_UNIPROC         0x0080
  358 #define OSF1_RB_PARAM           0x0100
  359 #define OSF1_RB_DUMP            0x0200
  360 
  361 
  362 /* resource.h */
  363 
  364 #define OSF1_RUSAGE_THREAD      1
  365 #define OSF1_RUSAGE_SELF        0
  366 #define OSF1_RUSAGE_CHILDREN    -1
  367 
  368 struct osf1_rusage {
  369         struct osf1_timeval ru_utime;
  370         struct osf1_timeval ru_stime;
  371         osf1_long       ru_maxrss;
  372         osf1_long       ru_ixrss;
  373         osf1_long       ru_idrss;
  374         osf1_long       ru_isrss;
  375         osf1_long       ru_minflt;
  376         osf1_long       ru_majflt;
  377         osf1_long       ru_nswap;
  378         osf1_long       ru_inblock;
  379         osf1_long       ru_oublock;
  380         osf1_long       ru_msgsnd;
  381         osf1_long       ru_msgrcv;
  382         osf1_long       ru_nsignals;
  383         osf1_long       ru_nvcsw;
  384         osf1_long       ru_nivcsw;
  385 };
  386 
  387 #define OSF1_RLIMIT_CPU         0
  388 #define OSF1_RLIMIT_FSIZE       1
  389 #define OSF1_RLIMIT_DATA        2
  390 #define OSF1_RLIMIT_STACK       3
  391 #define OSF1_RLIMIT_CORE        4
  392 #define OSF1_RLIMIT_RSS         5
  393 #define OSF1_RLIMIT_NOFILE      6
  394 #define OSF1_RLIMIT_AS          7
  395 
  396 #define OSF1_RLIM_INFINITY      0x7fffffffffffffffL
  397 
  398 struct osf1_rlimit {
  399         rlim_t  rlim_cur;
  400         rlim_t  rlim_max;
  401 };
  402 
  403 
  404 /* seek.h */
  405 
  406 #define OSF1_SEEK_SET           0
  407 #define OSF1_SEEK_CUR           1
  408 #define OSF1_SEEK_END           2
  409 
  410 
  411 /* signal.h (some in machine/signal.h) */
  412 
  413 struct osf1_sigaction {
  414         osf1_fcn_ptr    osf1_sa_handler;
  415         osf1_sigset_t   osf1_sa_mask;
  416         osf1_int        osf1_sa_flags;
  417         osf1_int        osf1_sa_signo;
  418 };
  419 
  420 /* actually from sysmisc.h */
  421 struct osf1_sigaltstack {
  422         osf1_data_ptr   ss_sp;
  423         osf1_int        ss_flags;
  424         osf1_size_t     ss_size;
  425 };
  426 
  427 /* sigaction flags */
  428 #define OSF1_SA_ONSTACK         0x00000001
  429 #define OSF1_SA_RESTART         0x00000002
  430 #define OSF1_SA_NOCLDSTOP       0x00000004
  431 #define OSF1_SA_NODEFER         0x00000008
  432 #define OSF1_SA_RESETHAND       0x00000010
  433 #define OSF1_SA_NOCLDWAIT       0x00000020
  434 #define OSF1_SA_SIGINFO         0x00000040
  435 
  436 /* sigaltstack flags */
  437 #define OSF1_SS_ONSTACK         0x00000001
  438 #define OSF1_SS_DISABLE         0x00000002
  439 #define OSF1_SS_NOMASK          0x00000004
  440 #define OSF1_SS_UCONTEXT        0x00000008
  441 
  442 /* signal set manipulation macros */
  443 #define osf1_sigmask(n)         ((osf1_sigset_t)1 << ((n) - 1))
  444 #define osf1_sigemptyset(s)     (*(s) = (osf1_sigset_t)0)
  445 #define osf1_sigismember(s, n)  (*(s) & osf1_sigmask(n))
  446 #define osf1_sigaddset(s, n)    (*(s) |= osf1_sigmask(n))
  447 
  448 
  449 /* socket.h */
  450 
  451 struct osf1_msghdr {
  452         osf1_data_ptr   msg_name;
  453         osf1_u_int      msg_namelen;
  454         osf1_data_ptr   msg_iov;                /* struct osf1_iovec_xopen * */
  455         osf1_u_int      msg_iovlen;
  456         osf1_data_ptr   msg_control;
  457         osf1_u_int      msg_controllen;
  458         osf1_int        msg_flags;
  459 };
  460 
  461 struct osf1_msghdr_xopen {
  462         osf1_data_ptr   msg_name;
  463         osf1_size_t     msg_namelen;
  464         osf1_data_ptr   msg_iov;                /* struct osf1_iovec_xopen * */
  465         osf1_int        msg_iovlen;
  466         osf1_data_ptr   msg_control;
  467         osf1_size_t     msg_controllen;
  468         osf1_int        msg_flags;
  469 };
  470 
  471 /* max message iov len */
  472 #define OSF1_MSG_MAXIOVLEN      16
  473 
  474 /* send/recv-family message flags */
  475 #define OSF1_MSG_OOB            0x0001
  476 #define OSF1_MSG_PEEK           0x0002
  477 #define OSF1_MSG_DONTROUTE      0x0004
  478 #define OSF1_MSG_EOR            0x0008
  479 #define OSF1_MSG_TRUNC          0x0010
  480 #define OSF1_MSG_CTRUNC         0x0020
  481 #define OSF1_MSG_WAITALL        0x0040
  482 
  483 
  484 /* stat.h */
  485 
  486 struct osf1_stat {
  487         osf1_dev_t      st_dev;
  488         osf1_ino_t      st_ino;
  489         osf1_mode_t     st_mode;
  490         osf1_nlink_t    st_nlink;
  491         osf1_uid_t      st_uid;
  492         osf1_gid_t      st_gid;
  493         osf1_dev_t      st_rdev;
  494         osf1_off_t      st_size;
  495         osf1_time_t     st_atime_sec;
  496         osf1_int        st_spare1;
  497         osf1_time_t     st_mtime_sec;
  498         osf1_int        st_spare2;
  499         osf1_time_t     st_ctime_sec;
  500         osf1_int        st_spare3;
  501         osf1_uint_t     st_blksize;
  502         osf1_int        st_blocks;
  503         osf1_uint_t     st_flags;
  504         osf1_uint_t     st_gen;
  505 };
  506 
  507 struct osf1_stat2 {
  508         osf1_dev_t      st_dev;
  509         osf1_int        st_dead1;       /* was st_ino */
  510         osf1_mode_t     st_mode;
  511         osf1_nlink_t    st_nlink;
  512         osf1_short      st_dead2;       /* something to do with nlink? */
  513         osf1_uid_t      st_uid;
  514         osf1_gid_t      st_gid;
  515         osf1_dev_t      st_rdev;
  516         osf1_dev_t      st_rdev2;
  517         osf1_off_t      st_size;
  518         osf1_time_t     st_dead3;
  519         osf1_int        st_uatime;
  520         osf1_time_t     st_dead4;
  521         osf1_int        st_umtime;
  522         osf1_time_t     st_dead5;
  523         osf1_int        st_uctime;
  524         osf1_int        st_dead6;
  525         osf1_int        st_dead7;
  526         osf1_uint_t     st_flags;
  527         osf1_uint_t     st_generation;
  528         osf1_long       st_unused1[4];
  529         osf1_ino_t      st_ino;
  530         osf1_int        st_unused;
  531         osf1_time_t     st_atime_sec;
  532         osf1_int        st_unused2;
  533         osf1_time_t     st_mtime_sec;
  534         osf1_int        st_unused3;
  535         osf1_time_t     st_ctime_sec;
  536         osf1_int        st_unused4;
  537         osf1_blksize_t  st_blocksize;
  538         osf1_blkcnt_t   st_blocks;
  539 };
  540 
  541 /* systeminfo.h */
  542 
  543 #define OSF1_SI_SYSNAME         1
  544 #define OSF1_SI_HOSTNAME        2
  545 #define OSF1_SI_RELEASE         3
  546 #define OSF1_SI_VERSION         4
  547 #define OSF1_SI_MACHINE         5
  548 #define OSF1_SI_ARCHITECTURE    6
  549 #define OSF1_SI_HW_SERIAL       7
  550 #define OSF1_SI_HW_PROVIDER     8
  551 #define OSF1_SI_SRPC_DOMAIN     9
  552 #define OSF1_SI_SET_HOSTNAME    258
  553 #define OSF1_SI_SET_SYSNAME     259
  554 #define OSF1_SI_SET_SRPC_DOMAIN 265
  555 
  556 
  557 /* time.h */
  558 
  559 struct osf1_itimerval {
  560         struct osf1_timeval it_interval;
  561         struct osf1_timeval it_value;
  562 };
  563 
  564 #define OSF1_ITIMER_REAL        0
  565 #define OSF1_ITIMER_VIRTUAL     1
  566 #define OSF1_ITIMER_PROF        2
  567 
  568 struct osf1_timezone {
  569         osf1_int        tz_minuteswest;
  570         osf1_int        tz_dsttime;
  571 };
  572 
  573 
  574 /* types.h */
  575 
  576 #define osf1_major(x)           ((((dev_t)(x)) >> 20) & 0x00000fff)
  577 #define osf1_minor(x)           ((((dev_t)(x)) >>  0) & 0x000fffff)
  578 #define osf1_makedev(x,y)       ((((dev_t)(x)) << 20) | ((dev_t)(y)))
  579 
  580 
  581 /* uio.h */
  582 
  583 struct osf1_iovec {
  584         osf1_data_ptr   iov_base;
  585         osf1_int        iov_len;
  586 };
  587 
  588 struct osf1_iovec_xopen {
  589         osf1_data_ptr   iov_base;
  590         osf1_size_t     iov_len;
  591 };
  592 
  593 
  594 /* unistd.h (user-land header) */
  595 
  596 #define OSF1__PC_CHOWN_RESTRICTED 10
  597 #define OSF1__PC_LINK_MAX       11
  598 #define OSF1__PC_MAX_CANON      12
  599 #define OSF1__PC_MAX_INPUT      13
  600 #define OSF1__PC_NAME_MAX       14
  601 #define OSF1__PC_NO_TRUNC       15
  602 #define OSF1__PC_PATH_MAX       16
  603 #define OSF1__PC_PIPE_BUF       17
  604 #define OSF1__PC_VDISABLE       18
  605 
  606 
  607 /* utsname.h */
  608 
  609 #define OSF1__SYS_NMLN          32
  610 
  611 struct osf1_utsname {
  612         char            sysname[OSF1__SYS_NMLN];
  613         char            nodename[OSF1__SYS_NMLN];
  614         char            release[OSF1__SYS_NMLN];
  615         char            version[OSF1__SYS_NMLN];
  616         char            machine[OSF1__SYS_NMLN];
  617 };
  618 
  619 
  620 /* wait.h */
  621 
  622 /* wait3() and wait4() options. */
  623 #define OSF1_WNOHANG            0x01
  624 #define OSF1_WUNTRACED          0x02
  625 
  626 /* XXX should have status word bits */
  627 
  628 
  629 /* for set/get sysinfo */
  630 
  631 struct  osf1_cpu_info {
  632         int             current_cpu;
  633         int             cpus_in_box;
  634         int             cpu_type;
  635         int             ncpus;
  636         u_int64_t       cpus_present;
  637         u_int64_t       cpus_running;
  638         u_int64_t       cpu_binding;
  639         u_int64_t       cpu_ex_binding;
  640         int             mhz;
  641         int             unused[3];
  642 };
  643 
  644 #define OSF_SET_IEEE_FP_CONTROL  14
  645 
  646 #define OSF_GET_MAX_UPROCS      2
  647 #define OSF_GET_PHYSMEM         19
  648 #define OSF_GET_MAX_CPU         30
  649 #define OSF_GET_IEEE_FP_CONTROL 45
  650 #define OSF_GET_CPUS_IN_BOX     55
  651 #define OSF_GET_CPU_INFO        59
  652 #define OSF_GET_PROC_TYPE       60
  653 #define OSF_GET_HWRPB           101
  654 #define OSF_GET_PLATFORM_NAME   103
  655 
  656 #endif /* _COMPAT_OSF1_OSF1_H_ */

Cache object: 3a076e2062eb833e753d0738ce3069bc


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.