diff options
author | Ido Barnea <ibarnea@cisco.com> | 2017-02-05 15:21:19 +0200 |
---|---|---|
committer | Ido Barnea <ibarnea@cisco.com> | 2017-02-13 12:32:01 +0200 |
commit | 9ca4a157305e4e23a892ba9bafc9eee0f66954ce (patch) | |
tree | 1a8afcf815fd33e7623e3c16246abe86c01bc8fd /src/dpdk/lib/librte_eal/common/include/generic/rte_atomic.h | |
parent | 2dab8f65015e9fa90df395be6ee1a07e9ac71044 (diff) |
dpdk1702-rc2 upstream files unchanged + mlx5 driver rc3
Signed-off-by: Ido Barnea <ibarnea@cisco.com>
Diffstat (limited to 'src/dpdk/lib/librte_eal/common/include/generic/rte_atomic.h')
-rw-r--r-- | src/dpdk/lib/librte_eal/common/include/generic/rte_atomic.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/dpdk/lib/librte_eal/common/include/generic/rte_atomic.h b/src/dpdk/lib/librte_eal/common/include/generic/rte_atomic.h index bfb4fe44..7b81705b 100644 --- a/src/dpdk/lib/librte_eal/common/include/generic/rte_atomic.h +++ b/src/dpdk/lib/librte_eal/common/include/generic/rte_atomic.h @@ -42,6 +42,7 @@ */ #include <stdint.h> +#include <rte_common.h> #ifdef __DOXYGEN__ @@ -99,6 +100,33 @@ static inline void rte_smp_wmb(void); */ static inline void rte_smp_rmb(void); +/** + * General memory barrier for I/O device + * + * Guarantees that the LOAD and STORE operations that precede the + * rte_io_mb() call are visible to I/O device or CPU before the + * LOAD and STORE operations that follow it. + */ +static inline void rte_io_mb(void); + +/** + * Write memory barrier for I/O device + * + * Guarantees that the STORE operations that precede the + * rte_io_wmb() call are visible to I/O device before the STORE + * operations that follow it. + */ +static inline void rte_io_wmb(void); + +/** + * Read memory barrier for IO device + * + * Guarantees that the LOAD operations on I/O device that precede the + * rte_io_rmb() call are visible to CPU before the LOAD + * operations that follow it. + */ +static inline void rte_io_rmb(void); + #endif /* __DOXYGEN__ */ /** |