7 * Userspace RCU header -- name mapping to allow multiple flavors to be
8 * used in the same executable.
10 * Copyright (c) 2009 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
11 * Copyright (c) 2009 Paul E. McKenney, IBM Corporation.
13 * LGPL-compatible code should include this header with :
15 * #define _LGPL_SOURCE
18 * This library is free software; you can redistribute it and/or
19 * modify it under the terms of the GNU Lesser General Public
20 * License as published by the Free Software Foundation; either
21 * version 2.1 of the License, or (at your option) any later version.
23 * This library is distributed in the hope that it will be useful,
24 * but WITHOUT ANY WARRANTY; without even the implied warranty of
25 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
26 * Lesser General Public License for more details.
28 * You should have received a copy of the GNU Lesser General Public
29 * License along with this library; if not, write to the Free Software
30 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
32 * IBM's contributions to this file may be relicensed under LGPLv2 or later.
35 /* Mapping macros to allow multiple flavors in a single binary. */
37 #if !defined(RCU_MEMBARRIER) && !defined(RCU_SIGNAL) && !defined(RCU_MB)
38 #define RCU_MEMBARRIER
43 #define rcu_read_lock rcu_read_lock_memb
44 #define _rcu_read_lock _rcu_read_lock_memb
45 #define rcu_read_unlock rcu_read_unlock_memb
46 #define _rcu_read_unlock _rcu_read_unlock_memb
47 #define rcu_register_thread rcu_register_thread_memb
48 #define rcu_unregister_thread rcu_unregister_thread_memb
49 #define rcu_init rcu_init_memb
50 #define rcu_exit rcu_exit_memb
51 #define synchronize_rcu synchronize_rcu_memb
52 #define rcu_reader rcu_reader_memb
53 #define rcu_gp_ctr rcu_gp_ctr_memb
55 #define get_cpu_call_rcu_data get_cpu_call_rcu_data_memb
56 #define get_call_rcu_thread get_call_rcu_thread_memb
57 #define create_call_rcu_data create_call_rcu_data_memb
58 #define set_cpu_call_rcu_data set_cpu_call_rcu_data_memb
59 #define get_default_call_rcu_data get_default_call_rcu_data_memb
60 #define get_call_rcu_data get_call_rcu_data_memb
61 #define get_thread_call_rcu_data get_thread_call_rcu_data_memb
62 #define set_thread_call_rcu_data set_thread_call_rcu_data_memb
63 #define create_all_cpu_call_rcu_data create_all_cpu_call_rcu_data_memb
64 #define free_all_cpu_call_rcu_data free_all_cpu_call_rcu_data_memb
65 #define call_rcu call_rcu_memb
67 #define defer_rcu defer_rcu_memb
68 #define rcu_defer_register_thread rcu_defer_register_thread_memb
69 #define rcu_defer_unregister_thread rcu_defer_unregister_thread_memb
70 #define rcu_defer_barrier rcu_defer_barrier_memb
71 #define rcu_defer_barrier_thread rcu_defer_barrier_thread_memb
73 /* Concurrent Data Structures */
74 #define cds_lfq_node_init_rcu cds_lfq_node_init_rcu_memb
75 #define cds_lfq_init_rcu cds_lfq_init_rcu_memb
76 #define cds_lfq_destroy_rcu cds_lfq_destroy_rcu_memb
77 #define cds_lfq_enqueue_rcu cds_lfq_enqueue_rcu_memb
78 #define cds_lfq_dequeue_rcu cds_lfq_dequeue_rcu_memb
80 #define cds_lfs_node_init_rcu cds_lfs_node_init_rcu_memb
81 #define cds_lfs_init_rcu cds_lfs_init_rcu_memb
82 #define cds_lfs_push_rcu cds_lfs_push_rcu_memb
83 #define cds_lfs_pop_rcu cds_lfs_pop_rcu_memb
85 #elif defined(RCU_SIGNAL)
87 #define rcu_read_lock rcu_read_lock_sig
88 #define _rcu_read_lock _rcu_read_lock_sig
89 #define rcu_read_unlock rcu_read_unlock_sig
90 #define _rcu_read_unlock _rcu_read_unlock_sig
91 #define rcu_register_thread rcu_register_thread_sig
92 #define rcu_unregister_thread rcu_unregister_thread_sig
93 #define rcu_init rcu_init_sig
94 #define rcu_exit rcu_exit_sig
95 #define synchronize_rcu synchronize_rcu_sig
96 #define rcu_reader rcu_reader_sig
97 #define rcu_gp_ctr rcu_gp_ctr_sig
99 #define get_cpu_call_rcu_data get_cpu_call_rcu_data_sig
100 #define get_call_rcu_thread get_call_rcu_thread_sig
101 #define create_call_rcu_data create_call_rcu_data_sig
102 #define set_cpu_call_rcu_data set_cpu_call_rcu_data_sig
103 #define get_default_call_rcu_data get_default_call_rcu_data_sig
104 #define get_call_rcu_data get_call_rcu_data_sig
105 #define get_thread_call_rcu_data get_thread_call_rcu_data_sig
106 #define set_thread_call_rcu_data set_thread_call_rcu_data_sig
107 #define create_all_cpu_call_rcu_data create_all_cpu_call_rcu_data_sig
108 #define free_all_cpu_call_rcu_data free_all_cpu_call_rcu_data_sig
109 #define call_rcu call_rcu_sig
111 #define defer_rcu defer_rcu_sig
112 #define rcu_defer_register_thread rcu_defer_register_thread_sig
113 #define rcu_defer_unregister_thread rcu_defer_unregister_thread_sig
114 #define rcu_defer_barrier rcu_defer_barrier_sig
115 #define rcu_defer_barrier_thread rcu_defer_barrier_thread_sig
117 /* Concurrent Data Structures */
118 #define cds_lfq_node_init_rcu cds_lfq_node_init_rcu_sig
119 #define cds_lfq_init_rcu cds_lfq_init_rcu_sig
120 #define cds_lfq_destroy_rcu cds_lfq_destroy_rcu_sig
121 #define cds_lfq_enqueue_rcu cds_lfq_enqueue_rcu_sig
122 #define cds_lfq_dequeue_rcu cds_lfq_dequeue_rcu_sig
124 #define cds_lfs_node_init_rcu cds_lfs_node_init_rcu_sig
125 #define cds_lfs_init_rcu cds_lfs_init_rcu_sig
126 #define cds_lfs_push_rcu cds_lfs_push_rcu_sig
127 #define cds_lfs_pop_rcu cds_lfs_pop_rcu_sig
129 #elif defined(RCU_MB)
131 #define rcu_read_lock rcu_read_lock_mb
132 #define _rcu_read_lock _rcu_read_lock_mb
133 #define rcu_read_unlock rcu_read_unlock_mb
134 #define _rcu_read_unlock _rcu_read_unlock_mb
135 #define rcu_register_thread rcu_register_thread_mb
136 #define rcu_unregister_thread rcu_unregister_thread_mb
137 #define rcu_init rcu_init_mb
138 #define rcu_exit rcu_exit_mb
139 #define synchronize_rcu synchronize_rcu_mb
140 #define rcu_reader rcu_reader_mb
141 #define rcu_gp_ctr rcu_gp_ctr_mb
143 #define get_cpu_call_rcu_data get_cpu_call_rcu_data_mb
144 #define get_call_rcu_thread get_call_rcu_thread_mb
145 #define create_call_rcu_data create_call_rcu_data_mb
146 #define set_cpu_call_rcu_data set_cpu_call_rcu_data_mb
147 #define get_default_call_rcu_data get_default_call_rcu_data_mb
148 #define get_call_rcu_data get_call_rcu_data_mb
149 #define get_thread_call_rcu_data get_thread_call_rcu_data_mb
150 #define set_thread_call_rcu_data set_thread_call_rcu_data_mb
151 #define create_all_cpu_call_rcu_data create_all_cpu_call_rcu_data_mb
152 #define free_all_cpu_call_rcu_data free_all_cpu_call_rcu_data_mb
153 #define call_rcu call_rcu_mb
155 #define defer_rcu defer_rcu_mb
156 #define rcu_defer_register_thread rcu_defer_register_thread_mb
157 #define rcu_defer_unregister_thread rcu_defer_unregister_thread_mb
158 #define rcu_defer_barrier rcu_defer_barrier_mb
159 #define rcu_defer_barrier_thread rcu_defer_barrier_thread_mb
161 /* Concurrent Data Structures */
162 #define cds_lfq_node_init_rcu cds_lfq_node_init_rcu_mb
163 #define cds_lfq_init_rcu cds_lfq_init_rcu_mb
164 #define cds_lfq_destroy_rcu cds_lfq_destroy_rcu_mb
165 #define cds_lfq_enqueue_rcu cds_lfq_enqueue_rcu_mb
166 #define cds_lfq_dequeue_rcu cds_lfq_dequeue_rcu_mb
168 #define cds_lfs_node_init_rcu cds_lfs_node_init_rcu_mb
169 #define cds_lfs_init_rcu cds_lfs_init_rcu_mb
170 #define cds_lfs_push_rcu cds_lfs_push_rcu_mb
171 #define cds_lfs_pop_rcu cds_lfs_pop_rcu_mb
175 #error "Undefined selection"
179 #endif /* _URCU_MAP_H */
This page took 0.033028 seconds and 5 git commands to generate.