Re: [PATCH v2 4/7] mm/khugepaged: fix outdated comments

From: David Hildenbrand (Arm)

Date: Wed Jul 29 2026 - 06:00:59 EST



> * UFFDIO_MOVE is prevented to race as well thanks to the
> * mmap_lock.
> @@ -1643,7 +1643,8 @@ static enum scan_result collapse_scan_pmd(struct mm_struct *mm,
>
> /*
> * If PMD is the only enabled order, enforce max_ptes_none, otherwise
> - * scan all pages to populate the bitmap for mTHP collapse.
> + * scan all pages to populate the bitmap for mTHP collapse. The bitmap
> + * is then checked again in mthp_collapse() for each attempted order.

Why use () here but not in the other cases above? (e.g., collapse_scan_pmd)

--
Cheers,

David