Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1601935

Re: [PATCH v2 10/10] mm: remove SWAP_[SUCCESS|AGAIN|FAIL]

From Minchan Kim <minchan@kernel.org>
Newsgroups linux.kernel
Subject Re: [PATCH v2 10/10] mm: remove SWAP_[SUCCESS|AGAIN|FAIL]
Date 2017-03-16 06:40 +0100
Message-ID <tlwiJ-223-13@gated-at.bofh.it> (permalink)
References <tl9Fv-2US-3@gated-at.bofh.it> <tl9Fw-2US-15@gated-at.bofh.it> <tlvwl-1oS-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hey, Sergey,

On Thu, Mar 16, 2017 at 01:40:23PM +0900, Sergey Senozhatsky wrote:
> Hello,
> 
> 
> On (03/15/17 14:24), Minchan Kim wrote:
> > There is no user for it. Remove it.
> > 
> 
> there is one.
> 
> mm/rmap.c
> 
> try_to_unmap_one()
> ...
> 	if (unlikely(PageSwapBacked(page) != PageSwapCache(page))) {
> 		WARN_ON_ONCE(1);
> 		ret = SWAP_FAIL;
> 		page_vma_mapped_walk_done(&pvmw);
> 		break;
> 	}

"There is no user for it"

I was liar so need to be a honest guy.
Thanks, Sergey!

Andrew, Please make me honest. Sorry about that.

From 286eae763d145338dc6c437258a741f293fab609 Mon Sep 17 00:00:00 2001
From: Minchan Kim <minchan@kernel.org>
Date: Thu, 16 Mar 2017 14:20:42 +0900
Subject: [PATCH] mm: use false instead of SWAP_FAIL

There was mistake with git-rebase.
SWAP_FAIL was removed. Use false.
It could be folded into mm-make-ttus-return-boolean.patch.

Reported-by: Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
Signed-off-by: Minchan Kim <minchan@kernel.org>
---
 mm/rmap.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/mm/rmap.c b/mm/rmap.c
index aa25fde..2422758 100644
--- a/mm/rmap.c
+++ b/mm/rmap.c
@@ -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;
 			}
-- 
2.7.4

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v2 10/10] mm: remove SWAP_[SUCCESS|AGAIN|FAIL] Minchan Kim <minchan@kernel.org> - 2017-03-15 06:30 +0100
  Re: [PATCH v2 10/10] mm: remove SWAP_[SUCCESS|AGAIN|FAIL] Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2017-03-16 05:50 +0100
    Re: [PATCH v2 10/10] mm: remove SWAP_[SUCCESS|AGAIN|FAIL] Minchan Kim <minchan@kernel.org> - 2017-03-16 06:40 +0100
      Re: [PATCH v2 10/10] mm: remove SWAP_[SUCCESS|AGAIN|FAIL] Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2017-03-16 06:50 +0100
        Re: [PATCH v2 10/10] mm: remove SWAP_[SUCCESS|AGAIN|FAIL] Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2017-03-16 07:00 +0100
        Re: [PATCH v2 10/10] mm: remove SWAP_[SUCCESS|AGAIN|FAIL] Minchan Kim <minchan@kernel.org> - 2017-03-16 07:30 +0100
  Re: [PATCH v2 10/10] mm: remove SWAP_[SUCCESS|AGAIN|FAIL] kbuild test robot <lkp@intel.com> - 2017-03-16 20:00 +0100

csiph-web