]> git.baikalelectronics.ru Git - kernel.git/commit
Merge branch 'safe-dirty-tlb-flush'
authorLinus Torvalds <torvalds@linux-foundation.org>
Sun, 27 Apr 2014 22:08:12 +0000 (15:08 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sun, 27 Apr 2014 22:08:12 +0000 (15:08 -0700)
commit331013ab1d4a257fe3c78192636b342ebeb17e8e
tree6eccadffcc04a7b66021ab3bd114cafcb52181c6
parent2385644ad6b432fdb519ab7d04a4dfc63153c80b
parent38860726c2a1cc8e87ddffc8ab1599db78ddfd75
Merge branch 'safe-dirty-tlb-flush'

This merges the patch to fix possible loss of dirty bit on munmap() or
madvice(DONTNEED).  If there are concurrent writers on other CPU's that
have the unmapped/unneeded page in their TLBs, their writes to the page
could possibly get lost if a third CPU raced with the TLB flush and did
a page_mkclean() before the page was fully written.

Admittedly, if you unmap() or madvice(DONTNEED) an area _while_ another
thread is still busy writing to it, you deserve all the lost writes you
could get.  But we kernel people hold ourselves to higher quality
standards than "crazy people deserve to lose", because, well, we've seen
people do all kinds of crazy things.

So let's get it right, just because we can, and we don't have to worry
about it.

* safe-dirty-tlb-flush:
  mm: split 'tlb_flush_mmu()' into tlb flushing and memory freeing parts