[RFC PATCH v2 3/3] mm, thp: fix comment inconsistency for swapin readahead functions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



After fixing swapin issues, comment lines stayed as in old version.
This patch updates the comments.

Signed-off-by: Ebru Akagunduz <ebru.akagunduz@xxxxxxxxx>
Reported-by: Hillf Danton <hillf.zj@xxxxxxxxxxxxxxx>
---
Changes in v2:
 - Newly created in this version.

 mm/huge_memory.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/mm/huge_memory.c b/mm/huge_memory.c
index ff96765..5cb0fd9 100644
--- a/mm/huge_memory.c
+++ b/mm/huge_memory.c
@@ -2441,8 +2441,8 @@ static bool __collapse_huge_page_swapin(struct mm_struct *mm,
 		/* do_swap_page returns VM_FAULT_RETRY with released mmap_sem */
 		if (ret & VM_FAULT_RETRY) {
 			down_read(&mm->mmap_sem);
-			/* vma is no longer available, don't continue to swapin */
 			if (hugepage_vma_revalidate(mm, address)) {
+				/* vma is no longer available, don't continue to swapin */
 				trace_mm_collapse_huge_page_swapin(mm, swapped_in, referenced, 0);
 				return false;
 			}
@@ -2512,8 +2512,8 @@ static void collapse_huge_page(struct mm_struct *mm,
 
 	/*
 	 * __collapse_huge_page_swapin always returns with mmap_sem
-	 * locked.  If it fails, release mmap_sem and jump directly
-	 * out.  Continuing to collapse causes inconsistency.
+	 * locked. If it fails, we release mmap_sem and jump out_nolock.
+	 * Continuing to collapse causes inconsistency.
 	 */
 	if (!__collapse_huge_page_swapin(mm, vma, address, pmd, referenced)) {
 		mem_cgroup_cancel_charge(new_page, memcg, true);
-- 
1.9.1

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]