mirror of
https://github.com/torvalds/linux.git
synced 2026-05-25 23:52:08 +02:00
mm/huge_memory: remove unnecessary VM_BUG_ON_PAGE()
This has been around since the beginnings of the THP implementation. I think we can safely assume that, if we have a THP folio, it will have a head page. Link: https://lkml.kernel.org/r/f3fa8eb4634ccb2e78209f570cc1a769a02ce93e.1774029655.git.ljs@kernel.org Signed-off-by: Lorenzo Stoakes (Oracle) <ljs@kernel.org> Reviewed-by: Baolin Wang <baolin.wang@linux.alibaba.com> Reviewed-by: Suren Baghdasaryan <surenb@google.com> Cc: Barry Song <baohua@kernel.org> Cc: David Hildenbrand <david@kernel.org> Cc: Dev Jain <dev.jain@arm.com> Cc: Lance Yang <lance.yang@linux.dev> Cc: Liam Howlett <liam.howlett@oracle.com> Cc: Michal Hocko <mhocko@suse.com> Cc: Mike Rapoport <rppt@kernel.org> Cc: Nico Pache <npache@redhat.com> Cc: Qi Zheng <zhengqi.arch@bytedance.com> Cc: Ryan Roberts <ryan.roberts@arm.com> Cc: Zi Yan <ziy@nvidia.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
This commit is contained in:
parent
7217744e0a
commit
07f264680a
|
|
@ -2452,7 +2452,6 @@ bool zap_huge_pmd(struct mmu_gather *tlb, struct vm_area_struct *vma,
|
|||
folio = page_folio(page);
|
||||
folio_remove_rmap_pmd(folio, page, vma);
|
||||
WARN_ON_ONCE(folio_mapcount(folio) < 0);
|
||||
VM_BUG_ON_PAGE(!PageHead(page), page);
|
||||
} else if (pmd_is_valid_softleaf(orig_pmd)) {
|
||||
const softleaf_t entry = softleaf_from_pmd(orig_pmd);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user