1 /* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(C) 2019 Marvell International Ltd.
5 #ifndef _OTX2_IO_GENERIC_H_
6 #define _OTX2_IO_GENERIC_H_
8 #define otx2_load_pair(val0, val1, addr) \
10 val0 = rte_read64_relaxed((void *)(addr)); \
11 val1 = rte_read64_relaxed((uint8_t *)(addr) + 8); \
14 #define otx2_store_pair(val0, val1, addr) \
16 rte_write64_relaxed(val0, (void *)(addr)); \
17 rte_write64_relaxed(val1, (((uint8_t *)(addr)) + 8)); \
20 #define otx2_prefetch_store_keep(ptr) do {} while (0)
22 static inline uint64_t
23 otx2_atomic64_add_nosync(int64_t incr, int64_t *ptr)
31 static inline uint64_t
32 otx2_atomic64_add_sync(int64_t incr, int64_t *ptr)
41 otx2_lmt_submit(uint64_t io_address)
43 RTE_SET_USED(io_address);
48 static __rte_always_inline void
49 otx2_lmt_mov(void *out, const void *in, const uint32_t lmtext)
56 static __rte_always_inline void
57 otx2_lmt_mov_seg(void *out, const void *in, const uint16_t segdw)
63 #endif /* _OTX2_IO_GENERIC_H_ */