Lines Matching +full:tlb +full:- +full:split

1 /* SPDX-License-Identifier: GPL-2.0 */
28 bool madvise_free_huge_pmd(struct mmu_gather *tlb, struct vm_area_struct *vma,
30 int zap_huge_pmd(struct mmu_gather *tlb, struct vm_area_struct *vma, pmd_t *pmd,
32 int zap_huge_pud(struct mmu_gather *tlb, struct vm_area_struct *vma, pud_t *pud,
36 int change_huge_pmd(struct mmu_gather *tlb, struct vm_area_struct *vma,
74 * and including PMD_ORDER, except order-0 (which is not "huge") and order-1
77 #define THP_ORDERS_ALL_ANON ((BIT(PMD_ORDER + 1) - 1) & ~(BIT(0) | BIT(1)))
81 * file is never split and the MAX_PAGECACHE_ORDER limit does not apply to
87 ((BIT(MAX_PAGECACHE_ORDER + 1) - 1) & ~BIT(0))
112 #define HPAGE_PMD_ORDER (HPAGE_PMD_SHIFT-PAGE_SHIFT)
114 #define HPAGE_PMD_MASK (~(HPAGE_PMD_SIZE - 1))
117 #define HPAGE_PUD_ORDER (HPAGE_PUD_SHIFT-PAGE_SHIFT)
119 #define HPAGE_PUD_MASK (~(HPAGE_PUD_SIZE - 1))
195 return fls_long(orders) - 1; in highest_order()
206 * - For file vma, check if the linear page offset of vma is
207 * order-aligned within the file. The hugepage is
208 * guaranteed to be order-aligned within the file, but we must
209 * check that the order-aligned addresses in the VMA map to
210 * order-aligned offsets within the file, else the hugepage will
212 * - For all vmas, check if the haddr is in an aligned hugepage
223 if (!IS_ALIGNED((vma->vm_start >> PAGE_SHIFT) - vma->vm_pgoff, in thp_vma_suitable_order()
230 if (haddr < vma->vm_start || haddr + hpage_size > vma->vm_end) in thp_vma_suitable_order()
269 * thp_vma_allowable_orders - determine hugepage orders that are allowed for vma
271 * @vm_flags: use these vm_flags instead of vma->vm_flags
277 * bit at the corresponding bit position (bit-2 corresponds to order-2, bit-3
278 * corresponds to order-3, etc). Order-0 is never considered a hugepage order.
328 test_bit(MMF_DISABLE_THP, &vma->vm_mm->flags); in vma_thp_disabled()
355 * try_folio_split - try to split a @folio at @page using non uniform split.
356 * @folio: folio to be split
357 * @page: split to order-0 at the given page
358 * @list: store the after-split folios
360 * Try to split a @folio at @page using non uniform split to order-0, if
361 * non uniform split is not supported, fall back to uniform split.
363 * Return: 0: split is successful, otherwise split failed.
374 return split_huge_page_to_list_to_order(&folio->page, list, in try_folio_split()
388 * expects the same page that has been split to be locked when in split_huge_page()
391 * page to be split. in split_huge_page()
417 int change_huge_pud(struct mmu_gather *tlb, struct vm_area_struct *vma,
422 change_huge_pud(struct mmu_gather *tlb, struct vm_area_struct *vma, in change_huge_pud() argument
469 * folio_test_pmd_mappable - Can we map this folio with a PMD?
601 return -EINVAL; in hugepage_madvise()
608 return -EINVAL; in madvise_collapse()
678 static inline int change_huge_pud(struct mmu_gather *tlb, in change_huge_pud() argument
690 return split_huge_page_to_list_to_order(&folio->page, list, new_order); in split_folio_to_list_to_order()