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/contrib/openzfs/lib/libspl/include/sys/trace_spl.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 /* Here to keep the libspl build happy */
    2 
    3 #ifndef _LIBSPL_SPL_TRACE_H
    4 #define _LIBSPL_SPL_TRACE_H
    5 
    6 /*
    7  * The set-error SDT probe is extra static, in that we declare its fake
    8  * function literally, rather than with the DTRACE_PROBE1() macro.  This is
    9  * necessary so that SET_ERROR() can evaluate to a value, which wouldn't
   10  * be possible if it required multiple statements (to declare the function
   11  * and then call it).
   12  *
   13  * SET_ERROR() uses the comma operator so that it can be used without much
   14  * additional code.  For example, "return (EINVAL);" becomes
   15  * "return (SET_ERROR(EINVAL));".  Note that the argument will be evaluated
   16  * twice, so it should not have side effects (e.g. something like:
   17  * "return (SET_ERROR(log_error(EINVAL, info)));" would log the error twice).
   18  */
   19 #undef SET_ERROR
   20 #define SET_ERROR(err) \
   21         (__set_error(__FILE__, __func__, __LINE__, err), err)
   22 
   23 
   24 #endif

Cache object: 4dcbcd2368fa14454001817704215e10


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