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/mach/mig_errors.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 /* 
    2  * Mach Operating System
    3  * Copyright (c) 1991,1990,1989,1988,1987 Carnegie Mellon University
    4  * All Rights Reserved.
    5  * 
    6  * Permission to use, copy, modify and distribute this software and its
    7  * documentation is hereby granted, provided that both the copyright
    8  * notice and this permission notice appear in all copies of the
    9  * software, derivative works or modified versions, and any portions
   10  * thereof, and that both notices appear in supporting documentation.
   11  * 
   12  * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
   13  * CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
   14  * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
   15  * 
   16  * Carnegie Mellon requests users of this software to return to
   17  * 
   18  *  Software Distribution Coordinator  or  Software.Distribution@CS.CMU.EDU
   19  *  School of Computer Science
   20  *  Carnegie Mellon University
   21  *  Pittsburgh PA 15213-3890
   22  * 
   23  * any improvements or extensions that they make and grant Carnegie Mellon
   24  * the rights to redistribute these changes.
   25  */
   26 /*
   27  * HISTORY
   28  * $Log:        mig_errors.h,v $
   29  * Revision 2.9  93/01/14  17:44:58  danner
   30  *      Cleanup.
   31  *      [92/06/10            pds]
   32  * 
   33  * Revision 2.8  92/03/31  15:18:19  rpd
   34  *      Added MIG_DESTROY_REQUEST.
   35  *      [92/03/09            rpd]
   36  * 
   37  * Revision 2.7  92/01/15  13:44:38  rpd
   38  *      Changed MACH_IPC_COMPAT conditionals to default to not present.
   39  * 
   40  * Revision 2.6  92/01/03  20:21:52  dbg
   41  *      Add mig_routine_t.
   42  *      [91/11/11            dbg]
   43  * 
   44  * Revision 2.5  91/08/28  11:15:31  jsb
   45  *      Added MIG_SERVER_DIED.
   46  *      [91/08/21            rpd]
   47  * 
   48  * Revision 2.4  91/05/14  16:56:33  mrt
   49  *      Correcting copyright
   50  * 
   51  * Revision 2.3  91/02/05  17:34:20  mrt
   52  *      Changed to new Mach copyright
   53  *      [91/02/01  17:19:44  mrt]
   54  * 
   55  * Revision 2.2  90/06/02  14:59:14  rpd
   56  *      Converted to new IPC.
   57  *      [90/03/26  22:37:01  rpd]
   58  * 
   59  * Revision 2.1  89/08/03  16:03:33  rwd
   60  * Created.
   61  * 
   62  * Revision 2.4  89/02/25  18:38:41  gm0w
   63  *      Changes for cleanup.
   64  * 
   65  * Revision 2.3  89/02/07  01:01:21  mwyoung
   66  * Relocated from sys/mig_errors.h
   67  * 
   68  * Revision 2.2  88/07/20  21:05:51  rpd
   69  * Added definition of mig_symtab_t.
   70  * 
   71  *  2-Dec-87  David Golub (dbg) at Carnegie-Mellon University
   72  *      Added MIG_ARRAY_TOO_LARGE.
   73  *
   74  * 25-May-87  Richard Draves (rpd) at Carnegie-Mellon University
   75  *      Added definition of death_pill_t.
   76  *
   77  * 31-Jul-86  Michael Young (mwyoung) at Carnegie-Mellon University
   78  *      Created.
   79  *
   80  */
   81 /*
   82  * Mach Interface Generator errors
   83  *
   84  */
   85 
   86 #ifndef _MACH_MIG_ERRORS_H_
   87 #define _MACH_MIG_ERRORS_H_
   88 
   89 #ifdef  KERNEL
   90 #include <mach_ipc_compat.h>
   91 #endif  /* KERNEL */
   92 
   93 #include <mach/kern_return.h>
   94 #include <mach/message.h>
   95 
   96 /*
   97  *      These error codes should be specified as system 4, subsytem 2.
   98  *      But alas backwards compatibility makes that impossible.
   99  *      The problem is old clients of new servers (eg, the kernel)
  100  *      which get strange large error codes when there is a Mig problem
  101  *      in the server.  Unfortunately, the IPC system doesn't have
  102  *      the knowledge to convert the codes in this situation.
  103  */
  104 
  105 #define MIG_TYPE_ERROR          -300    /* client type check failure */
  106 #define MIG_REPLY_MISMATCH      -301    /* wrong reply message ID */
  107 #define MIG_REMOTE_ERROR        -302    /* server detected error */
  108 #define MIG_BAD_ID              -303    /* bad request message ID */
  109 #define MIG_BAD_ARGUMENTS       -304    /* server type check failure */
  110 #define MIG_NO_REPLY            -305    /* no reply should be sent */
  111 #define MIG_EXCEPTION           -306    /* server raised exception */
  112 #define MIG_ARRAY_TOO_LARGE     -307    /* array not large enough */
  113 #define MIG_SERVER_DIED         -308    /* server died */
  114 #define MIG_DESTROY_REQUEST     -309    /* destroy request with no reply */
  115 
  116 typedef struct {
  117         mach_msg_header_t       Head;
  118         mach_msg_type_t         RetCodeType;
  119         kern_return_t           RetCode;
  120 } mig_reply_header_t;
  121 
  122 typedef struct mig_symtab {
  123         char    *ms_routine_name;
  124         int     ms_routine_number;
  125 #if     defined(__STDC__) || defined(c_plus_plus) || defined(hc)
  126         void
  127 #else
  128         int
  129 #endif
  130                 (*ms_routine)();
  131 } mig_symtab_t;
  132 
  133 /*
  134  * Definition for server stub routines.  These routines
  135  * unpack the request message, call the server procedure,
  136  * and pack the reply message.
  137  */
  138 #if     defined(__STDC__) || defined(c_plus_plus)
  139 typedef void    (*mig_routine_t)(mach_msg_header_t *, mach_msg_header_t *);
  140 #else
  141 #if     defined(hc)
  142 typedef void    (*mig_routine_t)();
  143 #else
  144 typedef int     (*mig_routine_t)();     /* PCC cannot handle void (*)() */
  145 #endif
  146 #endif
  147 
  148 /* Definitions for the old IPC interface. */
  149 
  150 #if     MACH_IPC_COMPAT
  151 
  152 typedef struct {
  153         msg_header_t            Head;
  154         msg_type_t              RetCodeType;
  155         kern_return_t           RetCode;
  156 } death_pill_t;
  157 
  158 #endif  /* MACH_IPC_COMPAT */
  159 
  160 #endif  /* _MACH_MIG_ERRORS_H_ */

Cache object: 4f642f2b7cead33282af44a8185893ab


[ 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.