<div dir="ltr">Hi all,<br><br>I am writing RDMA_WRITE latency(Round Trip Latency) application using OFED user verbs and kernel verbs.<br><br>In both applications i am using technique like polling on the last byte of rdma target buffer on the responder side<br>
(even though it is not standard),to find RDMA_WRITE completion.<br><br>Steps followed in user space rdma_write <br>1. allocated memory using malloc, <br>2. registered memory using ibv_reg_mr, REMOTE access is enabled,<br>
3. requested rdma_write from initiator, completion entry is success,<br>4. responder is polling(spinning) on the last byte of receive buffer to be set, responder is able to see last byte set.<br><br>Steps followed in kernel space rdma_write<br>
1. allocated memory using kmalloc,<br>2. registered memory using ib_reg_phys_mr, REMOTE access is enabled,<br>3. requested rdma_write from initiator, completion entry is success,<br>4. responder is polling(spinning) on the last byte of receive buffer to be set. Responder is not able to find buffer updatation.<br>
<br>If i use ib_dma_sync_single_for_cpu() before accessing the buffer on Responder side, Responder is able to see updated data(last byte set).<br><br>Please help me to understand following,<br>Is this buffer updation problem is because of CPU cache, or some other.  <br>
If it is CPU cache problem, then how user space is able to get updated data without any explicit dma synchronization.<br><br>Test setup is  <br>arch: x86_64  <br>Linux kernel :2.6.18-194.el5 (RHEL 5.5)<br>OFED : 1.5.4 <br>
<br>Thanks in advance <br>Jagadeesh.<br><br></div>