xref: /f-stack/tools/compat/include/sys/_sx.h (revision 1eaf0ac3)
1*1eaf0ac3Slogwang /*-
2*1eaf0ac3Slogwang  * Copyright (c) 2007 Attilio Rao <[email protected]>
3*1eaf0ac3Slogwang  * All rights reserved.
4*1eaf0ac3Slogwang  *
5*1eaf0ac3Slogwang  * Redistribution and use in source and binary forms, with or without
6*1eaf0ac3Slogwang  * modification, are permitted provided that the following conditions
7*1eaf0ac3Slogwang  * are met:
8*1eaf0ac3Slogwang  * 1. Redistributions of source code must retain the above copyright
9*1eaf0ac3Slogwang  *    notice(s), this list of conditions and the following disclaimer as
10*1eaf0ac3Slogwang  *    the first lines of this file unmodified other than the possible
11*1eaf0ac3Slogwang  *    addition of one or more copyright notices.
12*1eaf0ac3Slogwang  * 2. Redistributions in binary form must reproduce the above copyright
13*1eaf0ac3Slogwang  *    notice(s), this list of conditions and the following disclaimer in the
14*1eaf0ac3Slogwang  *    documentation and/or other materials provided with the distribution.
15*1eaf0ac3Slogwang  *
16*1eaf0ac3Slogwang  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY
17*1eaf0ac3Slogwang  * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
18*1eaf0ac3Slogwang  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
19*1eaf0ac3Slogwang  * DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY
20*1eaf0ac3Slogwang  * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21*1eaf0ac3Slogwang  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
22*1eaf0ac3Slogwang  * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
23*1eaf0ac3Slogwang  * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24*1eaf0ac3Slogwang  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25*1eaf0ac3Slogwang  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
26*1eaf0ac3Slogwang  * DAMAGE.
27*1eaf0ac3Slogwang  *
28*1eaf0ac3Slogwang  * $FreeBSD$
29*1eaf0ac3Slogwang  */
30*1eaf0ac3Slogwang 
31*1eaf0ac3Slogwang #ifndef	_SYS__SX_H_
32*1eaf0ac3Slogwang #define	_SYS__SX_H_
33*1eaf0ac3Slogwang 
34*1eaf0ac3Slogwang /*
35*1eaf0ac3Slogwang  * Shared/exclusive lock main structure definition.
36*1eaf0ac3Slogwang  */
37*1eaf0ac3Slogwang struct sx {
38*1eaf0ac3Slogwang 	struct lock_object	lock_object;
39*1eaf0ac3Slogwang 	void*	sx_lock;
40*1eaf0ac3Slogwang };
41*1eaf0ac3Slogwang 
42*1eaf0ac3Slogwang #endif	/* !_SYS__SX_H_ */
43