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


Groups > linux.kernel > #1711738

[RFC PATCH 4/4] mm: hwpoison: soft offline supports thp migration

From Zi Yan <zi.yan@sent.com>
Newsgroups linux.kernel
Subject [RFC PATCH 4/4] mm: hwpoison: soft offline supports thp migration
Date 2017-08-15 04:00 +0200
Message-ID <uezjd-3jP-29@gated-at.bofh.it> (permalink)
References <uezjc-3jP-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Zi Yan <zi.yan@cs.rutgers.edu>

This patch enables thp migration for soft offline.

Signed-off-by: Zi Yan <zi.yan@cs.rutgers.edu>
---
 mm/memory-failure.c | 19 -------------------
 1 file changed, 19 deletions(-)

diff --git a/mm/memory-failure.c b/mm/memory-failure.c
index c05107548d72..02ae1aff51a4 100644
--- a/mm/memory-failure.c
+++ b/mm/memory-failure.c
@@ -1712,25 +1712,6 @@ static int __soft_offline_page(struct page *page, int flags, int *split)
 static int soft_offline_in_use_page(struct page *page, int flags, int *split)
 {
 	int ret;
-	struct page *hpage = compound_head(page);
-
-	if (!PageHuge(page) && PageTransHuge(hpage)) {
-		lock_page(hpage);
-		if (!PageAnon(hpage) || unlikely(split_huge_page(hpage))) {
-			unlock_page(hpage);
-			if (!PageAnon(hpage))
-				pr_info("soft offline: %#lx: non anonymous thp\n", page_to_pfn(page));
-			else
-				pr_info("soft offline: %#lx: thp split failed\n", page_to_pfn(page));
-			put_hwpoison_page(hpage);
-			return -EBUSY;
-		}
-		if (split)
-			*split = 1;
-		unlock_page(hpage);
-		get_hwpoison_page(page);
-		put_hwpoison_page(hpage);
-	}
 
 	if (PageHuge(page))
 		ret = soft_offline_huge_page(page, flags);
-- 
2.13.2

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


Thread

[RFC PATCH 0/4] mm: hwpoison: soft-offline support for thp migration Zi Yan <zi.yan@sent.com> - 2017-08-15 04:00 +0200
  [RFC PATCH 3/4] mm: soft-offline: retry to split and soft-offline the raw error if the original THP offlining fails. Zi Yan <zi.yan@sent.com> - 2017-08-15 04:00 +0200
    Re: [RFC PATCH 3/4] mm: soft-offline: retry to split and  soft-offline the raw error if the original THP offlining fails. Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> - 2017-08-24 09:40 +0200
  [RFC PATCH 4/4] mm: hwpoison: soft offline supports thp migration Zi Yan <zi.yan@sent.com> - 2017-08-15 04:00 +0200
  [RFC PATCH 1/4] mm: madvise: read loop's step size beforehand in madvise_inject_error(), prepare for THP support. Zi Yan <zi.yan@sent.com> - 2017-08-15 04:00 +0200
    Re: [RFC PATCH 1/4] mm: madvise: read loop's step size beforehand  in madvise_inject_error(), prepare for THP support. Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> - 2017-08-23 10:00 +0200
      Re: [RFC PATCH 1/4] mm: madvise: read loop's step size beforehand in  madvise_inject_error(), prepare for THP support. "Zi Yan" <zi.yan@sent.com> - 2017-08-23 16:30 +0200
        Re: [RFC PATCH 1/4] mm: madvise: read loop's step size beforehand  in madvise_inject_error(), prepare for THP support. Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> - 2017-08-24 06:40 +0200
          Re: [RFC PATCH 1/4] mm: madvise: read loop's step size beforehand in  madvise_inject_error(), prepare for THP support. "Zi Yan" <zi.yan@sent.com> - 2017-08-24 16:40 +0200

csiph-web