[openib-general] Re: uverbs events
Roland Dreier
roland at topspin.com
Mon Apr 11 17:10:51 PDT 2005
ardavis> Redhat EL 4.0, 64-bit
OK, I found a system with that distro installed, although I can't test
the results of the build. However, I built libmthca with the same
CFLAGS that rpm seems to use, namely "-g -O2 -m64 -pipe". I found
that mthca_tavor_arm_cq() compiles to the following tiny fragment:
0000000000001d10 <mthca_tavor_arm_cq>:
1d10: 48 8b 07 mov (%rdi),%rax
1d13: 48 8b 90 a8 ef ff ff mov 0xffffffffffffefa8(%rax),%rdx
1d1a: 48 8b 44 24 f8 mov 0xfffffffffffffff8(%rsp),%rax
1d1f: 48 89 42 20 mov %rax,0x20(%rdx)
1d23: 31 c0 xor %eax,%eax
1d25: c3 retq
in other words, the compiler seems to be discarding all the
assignments to doorbell[0] and doorbell[1]. I'm not sure if this is a
compiler bug or what -- I need to investigate further. In any case
can you try the following patch to libmthca and see if it fixes
things:
Index: src/cq.c
===================================================================
--- src/cq.c (revision 2156)
+++ src/cq.c (working copy)
@@ -441,6 +441,8 @@ int mthca_tavor_arm_cq(struct ibv_cq *cq
to_mcq(cq)->cqn);
doorbell[1] = 0xffffffff;
+ mb();
+
mthca_write64(doorbell, to_mctx(cq->context), MTHCA_CQ_DOORBELL);
return 0;
More information about the general
mailing list