Commit 9bb3fd60 authored by Ma Wupeng's avatar Ma Wupeng Committed by Wupeng Ma
Browse files

arm64: mm: Add copy mc support for all migrate_page

hulk inclusion
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/IB0OV7



--------------------------------

Commit 45dbef4c ("mm: page_eject: Add mc support during offline page")
brings mcs support for migrate_page, however this is only enabled for
feature page eject which is only enabled in arm64. Since this support can
works in any scenarios, remove the restriction(PF_MCS) and make it works
for all migrate_page in arm64.

Signed-off-by: default avatarMa Wupeng <mawupeng1@huawei.com>
parent 85d3522e
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -743,9 +743,8 @@ int migrate_page_extra(struct address_space *mapping,

	BUG_ON(PageWriteback(page));	/* Writeback must be complete */

	if (unlikely(IS_ENABLED(CONFIG_ARCH_HAS_COPY_MC) &&
		     (current->flags & PF_MCS) &&
		     (mode != MIGRATE_SYNC_NO_COPY)))
	if (IS_ENABLED(CONFIG_ARM64) && IS_ENABLED(CONFIG_ARCH_HAS_COPY_MC) &&
	    (mode != MIGRATE_SYNC_NO_COPY))
		return migrate_page_mc_extra(mapping, newpage, page, mode,
					     extra_count);