mirror of
https://github.com/openvswitch/ovs
synced 2025-10-25 15:07:05 +00:00
ovs-thread: Add support for globally visible per-thread data.
DEFINE_PER_THREAD_DATA always declared its data item as "static", meaning that it was only directly visible within a single translation unit. This commit adds additional forms of per-thread data that allow the data to be accessible from multiple translation units. Signed-off-by: Ben Pfaff <blp@nicira.com>
This commit is contained in:
@@ -39,7 +39,7 @@
|
||||
* cryptographic-quality randomness. */
|
||||
|
||||
/* Current random state. */
|
||||
DEFINE_PER_THREAD_DATA(uint32_t, seed, 0);
|
||||
DEFINE_STATIC_PER_THREAD_DATA(uint32_t, seed, 0);
|
||||
|
||||
static uint32_t random_next(void);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user