condvar_impl.h (381a2a9a) | condvar_impl.h (f4b3ec61) |
---|---|
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 (the "License"). 6 * You may not use this file except in compliance with the License. 7 * 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE --- 6 unchanged lines hidden (view full) --- 15 * If applicable, add the following below this CDDL HEADER, with the 16 * fields enclosed by brackets "[]" replaced with your own identifying 17 * information: Portions Copyright [yyyy] [name of copyright owner] 18 * 19 * CDDL HEADER END 20 */ 21 22/* | 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 (the "License"). 6 * You may not use this file except in compliance with the License. 7 * 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE --- 6 unchanged lines hidden (view full) --- 15 * If applicable, add the following below this CDDL HEADER, with the 16 * fields enclosed by brackets "[]" replaced with your own identifying 17 * information: Portions Copyright [yyyy] [name of copyright owner] 18 * 19 * CDDL HEADER END 20 */ 21 22/* |
23 * Copyright 2006 Sun Microsystems, Inc. All rights reserved. | 23 * Copyright 2007 Sun Microsystems, Inc. All rights reserved. |
24 * Use is subject to license terms. 25 */ 26 27#ifndef _SYS_CONDVAR_IMPL_H 28#define _SYS_CONDVAR_IMPL_H 29 30#pragma ident "%Z%%M% %I% %E% SMI" 31 --- 65 unchanged lines hidden (view full) --- 97#define CVW_EXIT_WRITE(_c) { \ 98 mutex_enter(&(_c)->cvw_lock); \ 99 ASSERT((_c)->cvw_refcnt == -1); \ 100 (_c)->cvw_refcnt = 0; \ 101 cv_broadcast(&(_c)->cvw_waiter); \ 102 mutex_exit(&(_c)->cvw_lock); \ 103} 104 | 24 * Use is subject to license terms. 25 */ 26 27#ifndef _SYS_CONDVAR_IMPL_H 28#define _SYS_CONDVAR_IMPL_H 29 30#pragma ident "%Z%%M% %I% %E% SMI" 31 --- 65 unchanged lines hidden (view full) --- 97#define CVW_EXIT_WRITE(_c) { \ 98 mutex_enter(&(_c)->cvw_lock); \ 99 ASSERT((_c)->cvw_refcnt == -1); \ 100 (_c)->cvw_refcnt = 0; \ 101 cv_broadcast(&(_c)->cvw_waiter); \ 102 mutex_exit(&(_c)->cvw_lock); \ 103} 104 |
105#define CVW_DESTROY(_c) { \ 106 mutex_destroy(&(_c)->cvw_lock); \ 107 cv_destroy(&(_c)->cvw_waiter); \ 108} 109 |
|
105#ifdef __cplusplus 106} 107#endif 108 109#endif /* _SYS_CONDVAR_IMPL_H */ | 110#ifdef __cplusplus 111} 112#endif 113 114#endif /* _SYS_CONDVAR_IMPL_H */ |