On Tue, May 13, 2008 at 08:45:51AM -0700, Linus Torvalds wrote: > > > On Tue, 13 May 2008, Nick Piggin wrote: > > > > No, *everyone* (except arch-only non-alpha developer) needs to know about > > it. > > Umm. In architecture files, by definition, only alpha needs to know about > it. > > That was very much an architecture-specific file: we're talking about > asm-x86/pgtable_32.h here. > > > x86 especially is a reference and often is a proving ground for code that > > becomes generic, so I'd say even x86 developers should need to know about > > it too. > > And in reference files that are architecture-specific, there is absolutely > *no point* in ever having read_barrier_depends(). Because even if another > architecture copies it, it's better off without it. Uh, I don't follow your logic. The "reference" Linux memory model requires it, so I don't see how you can justify saying it is wrong just because a *specific* architecture doesn't need it. I think that regardless of whether it is required or not, it is good to have in order to prompt the reader to think about memory ordering. I also think it is a good idea to use smp_rmb/smp_wmb in x86 only code even though that is a noop too. -- To unsubscribe from this list: send the line "unsubscribe linux-arch" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html