[openib-general] Re: [PATCH 53 of 53] ipath - add memory barrier when waiting for writes

Roland Dreier rdreier at cisco.com
Mon May 15 08:57:41 PDT 2006


 >  static void i2c_wait_for_writes(struct ipath_devdata *dd)
 >  {
 > +	mb();
 >  	(void)ipath_read_kreg32(dd, dd->ipath_kregs->kr_scratch);
 >  }

This needs a comment explaining why it's needed.  A memory barrier
before a readl() looks very strange since readl() should be ordered anyway.

 - R.



More information about the general mailing list