Index: contrib/ofed/include/udma_barrier.h =================================================================== --- contrib/ofed/include/udma_barrier.h (revision 336593) +++ contrib/ofed/include/udma_barrier.h (working copy) @@ -104,6 +104,10 @@ #include #include #define udma_to_device_barrier() dmb() +#elif defined(__riscv) +#include +#include +#define udma_to_device_barrier() fence() #else #error No architecture specific memory barrier defines found! #endif @@ -140,6 +144,8 @@ #define udma_from_device_barrier() mips_sync() #elif defined(__arm__) #define udma_from_device_barrier() dmb() +#elif defined(__riscv) +#define udma_from_device_barrier() fence() #else #error No architecture specific memory barrier defines found! #endif @@ -208,6 +214,8 @@ #define mmio_flush_writes() mips_sync() #elif defined(__arm__) #define mmio_flush_writes() dmb() +#elif defined(__riscv) +#define mmio_flush_writes() fence() #else #error No architecture specific memory barrier defines found! #endif