[openib-general] HP ZX1 and HP IB cards...

Roland Dreier roland at topspin.com
Fri Dec 3 14:26:12 PST 2004


    Grant> I tried but it worked with the patch. :^(

Of course it would ... :)

    >> doorbell[0] = cpu_to_be32(MTHCA_EQ_DB_SET_CI | eqn);
    >> doorbell[1] = cpu_to_be32(ci);

    Grant> This doesn't feel very safe to me.  If write ordering is
    Grant> required here, writel() or wmb() is necessary.  Let me look
    Grant> over this code and see if the ordering is enforced
    Grant> elsewhere.

I'm not positive but I think it should be OK.  doorbell is just a
temporary variable that gets passed to mthca_write64(), which
essentially does a __raw_writeq(*(u64 *) doorbell).  On ia64,
__raw_writeq is #defined to be writeq, so ordering should be OK
there.  And surely ia64 ordering is strong enough that the CPU won't
try to do the writeq before the writes to doorbell complete, right?

On the other hand, the fact that changing the timing with printks
makes things work does make it look like there may be some sort of
ordering problem...

 - R.




More information about the general mailing list