On Mon, 9 Jan 2012, KOSAKI Motohiro wrote:2012/1/6 Hugh Dickins<hughd@xxxxxxxxxx>:
[ check_move_unevictable_page(s) ]
Leave out the "rotate unevictable list" block: that's a leftover
from when this was used for /proc/sys/vm/scan_unevictable_pages,
whose flawed handling involved looking at pages at tail of LRU.
Was there significance to the sequence first ClearPageUnevictable,
then test page_evictable, then SetPageUnevictable here? I think
not, we're under LRU lock, and have no barriers between those.
If I understand correctly, this is not exactly correct. Because of,
Thank you for giving it serious thought:
such races are hard work to think about.
PG_mlocked operation is not protected by LRU lock. So, I think we
Right. But I don't see that I've made a significant change there.
I may be being lazy, and rushing back to answer you, without giving
constructive thought to what the precise race is that you see, and
how we might fix it. If the case you have in mind is easy for you
to describe in detail, please do so; but don't hesitate to tell me
to my own work for myself!