On Tue, 26 Jul 2011, Oliver Neukum wrote:

> Hi,
> 
> this code made me think:
> 
>                                 /* Give this link TRB to the hardware */
>                                 wmb();
>                                 next->link.control ^= cpu_to_le32(TRB_CYCLE);
> 
> Can you do this or may there be a CPU that speculatively writes before
> it reads next->link.control ?

CPUs never do speculative writes.  And even if they did, the wmb() 
would prevent the speculative write from preceding any statement that 
comes before the memory barrier.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-arm-msm" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to