]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - include/os/freebsd/spl/sys/cmn_err.h
Update OpenZFS to 2.0.0-rc3-gbd565f
[FreeBSD/FreeBSD.git] / include / os / freebsd / spl / sys / cmn_err.h
1 /*
2  * CDDL HEADER START
3  *
4  * The contents of this file are subject to the terms of the
5  * Common Development and Distribution License, Version 1.0 only
6  * (the "License").  You may not use this file except in compliance
7  * with the License.
8  *
9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10  * or http://www.opensolaris.org/os/licensing.
11  * See the License for the specific language governing permissions
12  * and limitations under the License.
13  *
14  * When distributing Covered Code, include this CDDL HEADER in each
15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16  * If applicable, add the following below this CDDL HEADER, with the
17  * fields enclosed by brackets "[]" replaced with your own identifying
18  * information: Portions Copyright [yyyy] [name of copyright owner]
19  *
20  * CDDL HEADER END
21  */
22 /*      Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
23 /*        All Rights Reserved   */
24
25
26 /*
27  * Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
28  * Use is subject to license terms.
29  */
30
31 #ifndef _SYS_CMN_ERR_H
32 #define _SYS_CMN_ERR_H
33
34 #if !defined(_ASM)
35 #include <sys/_stdarg.h>
36 #endif
37
38 #ifdef  __cplusplus
39 extern "C" {
40 #endif
41
42 /* Common error handling severity levels */
43
44 #define CE_CONT         0       /* continuation         */
45 #define CE_NOTE         1       /* notice               */
46 #define CE_WARN         2       /* warning              */
47 #define CE_PANIC        3       /* panic                */
48 #define CE_IGNORE       4       /* print nothing        */
49
50 #ifndef _ASM
51
52 /*PRINTFLIKE2*/
53 extern void cmn_err(int, const char *, ...)
54     __KPRINTFLIKE(2);
55
56 extern void vzcmn_err(zoneid_t, int, const char *, __va_list)
57     __KVPRINTFLIKE(3);
58
59 extern void vcmn_err(int, const char *, __va_list)
60     __KVPRINTFLIKE(2);
61
62 /*PRINTFLIKE3*/
63 extern void zcmn_err(zoneid_t, int, const char *, ...)
64     __KPRINTFLIKE(3);
65
66 extern void vzprintf(zoneid_t, const char *, __va_list)
67     __KVPRINTFLIKE(2);
68
69 /*PRINTFLIKE2*/
70 extern void zprintf(zoneid_t, const char *, ...)
71     __KPRINTFLIKE(2);
72
73 extern void vuprintf(const char *, __va_list)
74     __KVPRINTFLIKE(1);
75
76 /*PRINTFLIKE1*/
77 extern void panic(const char *, ...)
78     __KPRINTFLIKE(1) __NORETURN;
79
80 extern void vpanic(const char *, __va_list)
81     __KVPRINTFLIKE(1) __NORETURN;
82
83 #endif /* !_ASM */
84
85 #ifdef  __cplusplus
86 }
87 #endif
88
89 #endif  /* _SYS_CMN_ERR_H */