From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751342AbdCPFoh (ORCPT ); Thu, 16 Mar 2017 01:44:37 -0400 Received: from mail-pg0-f67.google.com ([74.125.83.67]:34245 "EHLO mail-pg0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751093AbdCPFog (ORCPT ); Thu, 16 Mar 2017 01:44:36 -0400 Date: Thu, 16 Mar 2017 14:44:30 +0900 From: Sergey Senozhatsky To: Minchan Kim Cc: Sergey Senozhatsky , Andrew Morton , linux-kernel@vger.kernel.org, linux-mm@kvack.org, kernel-team@lge.com, Johannes Weiner , Michal Hocko , "Kirill A. Shutemov" , Anshuman Khandual Subject: Re: [PATCH v2 10/10] mm: remove SWAP_[SUCCESS|AGAIN|FAIL] Message-ID: <20170316054430.GA464@jagdpanzerIV.localdomain> References: <1489555493-14659-1-git-send-email-minchan@kernel.org> <1489555493-14659-11-git-send-email-minchan@kernel.org> <20170316044023.GA2597@jagdpanzerIV.localdomain> <20170316053313.GA19241@bbox> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170316053313.GA19241@bbox> User-Agent: Mutt/1.8.0 (2017-02-23) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On (03/16/17 14:33), Minchan Kim wrote: [..] > "There is no user for it" > > I was liar so need to be a honest guy. ha-ha-ha. I didn't say that :) [..] > @@ -1414,7 +1414,7 @@ static bool try_to_unmap_one(struct page *page, struct vm_area_struct *vma, > */ > if (unlikely(PageSwapBacked(page) != PageSwapCache(page))) { > WARN_ON_ONCE(1); > - ret = SWAP_FAIL; > + ret = false; > page_vma_mapped_walk_done(&pvmw); > break; > } one thing to notice here is that 'ret = false' and 'ret = SWAP_FAIL' are not the same and must produce different results. `ret' is bool and SWAP_FAIL was 2. it's return 1 vs return 0, isn't it? so was there a bug before? -ss