Re: [RFC 04/11] mm: remove SWAP_MLOCK check for SWAP_SUCCESS in ttu

2017-03-07 Thread Minchan Kim
On Tue, Mar 07, 2017 at 05:26:43PM +0300, Kirill A. Shutemov wrote: > On Thu, Mar 02, 2017 at 03:39:18PM +0900, Minchan Kim wrote: > > If the page is mapped and rescue in ttuo, page_mapcount(page) == 0 cannot > > be true so page_mapcount check in ttu is enough to return SWAP_SUCCESS. > > IOW, SWAP_

Re: [RFC 04/11] mm: remove SWAP_MLOCK check for SWAP_SUCCESS in ttu

2017-03-07 Thread Kirill A. Shutemov
On Thu, Mar 02, 2017 at 03:39:18PM +0900, Minchan Kim wrote: > If the page is mapped and rescue in ttuo, page_mapcount(page) == 0 cannot > be true so page_mapcount check in ttu is enough to return SWAP_SUCCESS. > IOW, SWAP_MLOCK check is redundant so remove it. > > Signed-off-by: Minchan Kim > --

Re: [RFC 04/11] mm: remove SWAP_MLOCK check for SWAP_SUCCESS in ttu

2017-03-02 Thread Minchan Kim
On Thu, Mar 02, 2017 at 08:21:46PM +0530, Anshuman Khandual wrote: > On 03/02/2017 12:09 PM, Minchan Kim wrote: > > If the page is mapped and rescue in ttuo, page_mapcount(page) == 0 cannot > > Nit: "ttuo" is very cryptic. Please expand it. No problem. > > > be true so page_mapcount check in tt

Re: [RFC 04/11] mm: remove SWAP_MLOCK check for SWAP_SUCCESS in ttu

2017-03-02 Thread Anshuman Khandual
On 03/02/2017 12:09 PM, Minchan Kim wrote: > If the page is mapped and rescue in ttuo, page_mapcount(page) == 0 cannot Nit: "ttuo" is very cryptic. Please expand it. > be true so page_mapcount check in ttu is enough to return SWAP_SUCCESS. > IOW, SWAP_MLOCK check is redundant so remove it. Right