diff options
| author | Garrett D'Amore <garrett@damore.org> | 2017-01-01 13:32:32 -0800 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2017-01-01 13:32:32 -0800 |
| commit | f0bf079dca01acb6dfc07af03226a0cae7a90010 (patch) | |
| tree | 6cddec8c026c31d88b5659a8ba89801c421158bc /src/platform/posix/posix_impl.h | |
| parent | 4c7e52ff0a5ad05164c05a4fbf99de1cdb4090bc (diff) | |
| download | nng-f0bf079dca01acb6dfc07af03226a0cae7a90010.tar.gz nng-f0bf079dca01acb6dfc07af03226a0cae7a90010.tar.bz2 nng-f0bf079dca01acb6dfc07af03226a0cae7a90010.zip | |
New thread infrastructure -- not used anywhere yet, but tested.
Diffstat (limited to 'src/platform/posix/posix_impl.h')
| -rw-r--r-- | src/platform/posix/posix_impl.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/platform/posix/posix_impl.h b/src/platform/posix/posix_impl.h index 2df96c71..5ca7812f 100644 --- a/src/platform/posix/posix_impl.h +++ b/src/platform/posix/posix_impl.h @@ -41,6 +41,23 @@ struct nni_cond { pthread_cond_t cv; pthread_mutex_t * mx; }; + +// These types are provided for here, to permit them to be directly inlined +// elsewhere. + +struct nni_plat_mtx { + pthread_mutex_t mtx; +}; + +struct nni_plat_thr { + pthread_t tid; +}; + +struct nni_plat_cv { + pthread_cond_t cv; + pthread_mutex_t *mtx; +}; + #endif #endif // PLATFORM_POSIX_IMPL_H |
