Skip to contentSkip to conversation

mm-huge_memory-use-helper-macro-is_err_or_null-in-split_huge_pages_pid.patch removed from -mm tree

merged mm-stable Andrew Morton 1 participant 1 message Jul 18, 2022

lore
Share & tools
lore

Andrew Morton

author tree notice Applied
#0 lore raw

The quilt patch titled
Subject: mm/huge_memory: use helper macro IS_ERR_OR_NULL in split_huge_pages_pid
has been removed from the -mm tree. Its filename was
mm-huge_memory-use-helper-macro-is_err_or_null-in-split_huge_pages_pid.patch

This patch was dropped because it was merged into the mm-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: Miaohe Lin <[email protected]>
Subject: mm/huge_memory: use helper macro IS_ERR_OR_NULL in split_huge_pages_pid
Date: Mon, 4 Jul 2022 21:22:01 +0800

Use helper macro IS_ERR_OR_NULL to check the validity of page to simplify the code. Minor readability improvement.

---

 mm/huge_memory.c |    4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
mm/huge_memory.c renamed from mm/huge_memory.c~mm-huge_memory-use-helper-macro-is_err_or_null-in-split_huge_pages_pid +1 -3
@@ -2958,9 +2958,7 @@ static int split_huge_pages_pid(int pid,
 		/* FOLL_DUMP to ignore special (like zero) pages */
 		page = follow_page(vma, addr, FOLL_GET | FOLL_DUMP);
 
-		if (IS_ERR(page))
-			continue;
-		if (!page || is_zone_device_page(page))
+		if (IS_ERR_OR_NULL(page) || is_zone_device_page(page))
 			continue;
 
 		if (!is_transparent_hugepage(page))

_

Patches currently in -mm which might be from [email protected] are

mm-hugetlb-avoid-corrupting-page-mapping-in-hugetlb_mcopy_atomic_pte.patch mm-page_alloc-minor-clean-up-for-memmap_init_compound.patch mm-mmapc-fix-missing-call-to-vm_unacct_memory-in-mmap_region.patch filemap-minor-cleanup-for-filemap_write_and_wait_range.patch mm-remove-obsolete-comment-in-do_fault_around.patch