[PATCH v5 07/13] mm: khugepaged: collapse_pte_mapped_thp() use pte_offset_map_rw_nolock()

Muchun Song muchun.song at linux.dev
Thu Sep 26 17:07:12 AEST 2024



> On Sep 26, 2024, at 14:46, Qi Zheng <zhengqi.arch at bytedance.com> wrote:
> 
> In collapse_pte_mapped_thp(), we may modify the pte and pmd entry after
> acquring the ptl, so convert it to using pte_offset_map_rw_nolock(). At
> this time, the pte_same() check is not performed after the PTL held. So we
> should get pgt_pmd and do pmd_same() check after the ptl held.
> 
> Signed-off-by: Qi Zheng <zhengqi.arch at bytedance.com>

Reviewed-by: Muchun Song <muchun.song at linux.dev>

Thanks.



More information about the Linuxppc-dev mailing list