On Thu, Apr 4, 2013 at 11:35 AM, Hugh Dickins <hughd@xxxxxxxxxx> wrote: > > find_vma() can be called by multiple threads with read lock > held on mm->mmap_sem and any of them can update mm->mmap_cache. > Prevent compiler from re-fetching mm->mmap_cache, because other > readers could update it in the meantime: Ack. I do wonder if we should mark the unlocked update too some way (also in find_vma()), although it's probably not a problem in practice since there's no way the compiler can reasonably really do anything odd with it. We *could* make that an ACCESS_ONCE() write too just to highlight the fact that it's an unlocked write to this optimistic data structure. Anyway, applied. Linus -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>