]> git.droids-corp.org - dpdk.git/blobdiff - drivers/common/octeontx2/otx2_common.h
common/octeontx2: add IO handling APIs
[dpdk.git] / drivers / common / octeontx2 / otx2_common.h
index b4e008b1474604e4986408671fb8c54c9a8b33c7..b0c19266b238caf8145162b22a8476ae6f93ac4e 100644 (file)
@@ -6,6 +6,8 @@
 #define _OTX2_COMMON_H_
 
 #include <rte_common.h>
+#include <rte_io.h>
+#include <rte_memory.h>
 
 #include "hw/otx2_rvu.h"
 #include "hw/otx2_nix.h"
 #define __hot   __attribute__((hot))
 #endif
 
+/* IO Access */
+#define otx2_read64(addr) rte_read64_relaxed((void *)(addr))
+#define otx2_write64(val, addr) rte_write64_relaxed((val), (void *)(addr))
+
+#if defined(RTE_ARCH_ARM64)
+#include "otx2_io_arm64.h"
+#else
+#include "otx2_io_generic.h"
+#endif
+
 #endif /* _OTX2_COMMON_H_ */