Lines Matching refs:gfp
574 static struct page *alloc_dma_pages(gfp_t gfp, size_t bytes, u64 phys_limit) in alloc_dma_pages() argument
581 page = alloc_pages(gfp, order); in alloc_dma_pages()
613 u64 phys_limit, gfp_t gfp) in swiotlb_alloc_tlb() argument
621 if (!gfpflags_allow_blocking(gfp) && dev && force_dma_unencrypted(dev)) { in swiotlb_alloc_tlb()
627 return dma_alloc_from_pool(dev, bytes, &vaddr, gfp, in swiotlb_alloc_tlb()
631 gfp &= ~GFP_ZONEMASK; in swiotlb_alloc_tlb()
633 gfp |= __GFP_DMA; in swiotlb_alloc_tlb()
635 gfp |= __GFP_DMA32; in swiotlb_alloc_tlb()
637 while (IS_ERR(page = alloc_dma_pages(gfp, bytes, phys_limit))) { in swiotlb_alloc_tlb()
640 !(gfp & (__GFP_DMA32 | __GFP_DMA))) in swiotlb_alloc_tlb()
641 gfp |= __GFP_DMA32; in swiotlb_alloc_tlb()
643 !(gfp & __GFP_DMA)) in swiotlb_alloc_tlb()
644 gfp = (gfp & ~__GFP_DMA32) | __GFP_DMA; in swiotlb_alloc_tlb()
685 unsigned int nareas, u64 phys_limit, gfp_t gfp) in swiotlb_alloc_pool() argument
699 pool = kzalloc(pool_size, gfp); in swiotlb_alloc_pool()
705 while (!(tlb = swiotlb_alloc_tlb(dev, tlb_size, phys_limit, gfp))) { in swiotlb_alloc_pool()
715 __get_free_pages(gfp, slot_order); in swiotlb_alloc_pool()