Searched refs:d_page (Results 1 - 3 of 3) sorted by relevance

/linux-4.1.27/drivers/gpu/drm/ttm/
H A Dttm_page_alloc_dma.c326 static void __ttm_dma_free_page(struct dma_pool *pool, struct dma_page *d_page) __ttm_dma_free_page() argument
328 dma_addr_t dma = d_page->dma; __ttm_dma_free_page()
329 dma_free_coherent(pool->dev, pool->size, d_page->vaddr, dma); __ttm_dma_free_page()
331 kfree(d_page); __ttm_dma_free_page()
332 d_page = NULL; __ttm_dma_free_page()
336 struct dma_page *d_page; __ttm_dma_alloc_page() local
338 d_page = kmalloc(sizeof(struct dma_page), GFP_KERNEL); __ttm_dma_alloc_page()
339 if (!d_page) __ttm_dma_alloc_page()
342 d_page->vaddr = dma_alloc_coherent(pool->dev, pool->size, __ttm_dma_alloc_page()
343 &d_page->dma, __ttm_dma_alloc_page()
345 if (d_page->vaddr) __ttm_dma_alloc_page()
346 d_page->p = virt_to_page(d_page->vaddr); __ttm_dma_alloc_page()
348 kfree(d_page); __ttm_dma_alloc_page()
349 d_page = NULL; __ttm_dma_alloc_page()
351 return d_page; __ttm_dma_alloc_page()
381 struct dma_page *d_page, *tmp; ttm_dma_pages_put() local
389 list_for_each_entry_safe(d_page, tmp, d_pages, page_list) { list_for_each_entry_safe()
390 list_del(&d_page->page_list); list_for_each_entry_safe()
391 __ttm_dma_free_page(pool, d_page); list_for_each_entry_safe()
395 static void ttm_dma_page_put(struct dma_pool *pool, struct dma_page *d_page) ttm_dma_page_put() argument
398 if (!(pool->type & IS_CACHED) && set_pages_array_wb(&d_page->p, 1)) ttm_dma_page_put()
402 list_del(&d_page->page_list); ttm_dma_page_put()
403 __ttm_dma_free_page(pool, d_page); ttm_dma_page_put()
685 struct dma_page *d_page, *tmp; ttm_dma_handle_caching_state_failure() local
693 list_for_each_entry_safe(d_page, tmp, d_pages, page_list) { list_for_each_entry_safe()
694 if (d_page->p != p) list_for_each_entry_safe()
697 list_del(&d_page->page_list); list_for_each_entry_safe()
698 __ttm_dma_free_page(pool, d_page); list_for_each_entry_safe()
822 struct dma_page *d_page; ttm_dma_page_pool_fill_locked() local
828 list_for_each_entry(d_page, &d_pages, page_list) { ttm_dma_page_pool_fill_locked()
848 struct dma_page *d_page; ttm_dma_pool_get_pages() local
856 d_page = list_first_entry(&pool->free_list, struct dma_page, page_list); ttm_dma_pool_get_pages()
857 ttm->pages[index] = d_page->p; ttm_dma_pool_get_pages()
858 ttm_dma->cpu_address[index] = d_page->vaddr; ttm_dma_pool_get_pages()
859 ttm_dma->dma_address[index] = d_page->dma; ttm_dma_pool_get_pages()
860 list_move_tail(&d_page->page_list, &ttm_dma->pages_list); ttm_dma_pool_get_pages()
936 struct dma_page *d_page, *next; ttm_dma_unpopulate() local
951 list_for_each_entry(d_page, &ttm_dma->pages_list, page_list) { ttm_dma_unpopulate()
952 ttm->pages[count] = d_page->p; ttm_dma_unpopulate()
975 list_for_each_entry_safe(d_page, next, &ttm_dma->pages_list, page_list) { ttm_dma_unpopulate()
977 d_page->p); ttm_dma_unpopulate()
978 ttm_dma_page_put(pool, d_page); ttm_dma_unpopulate()
/linux-4.1.27/mm/
H A Dzsmalloc.c1509 struct page *s_page, *d_page; zs_object_copy() local
1519 obj_to_location(dst, &d_page, &d_objidx); zs_object_copy()
1522 d_off = obj_idx_to_offset(d_page, d_objidx, class->size); zs_object_copy()
1531 d_addr = kmap_atomic(d_page); zs_object_copy()
1552 d_addr = kmap_atomic(d_page); zs_object_copy()
1559 d_page = get_next_page(d_page); zs_object_copy()
1560 BUG_ON(!d_page); zs_object_copy()
1561 d_addr = kmap_atomic(d_page); zs_object_copy()
1609 struct page *d_page; member in struct:zs_compact_control
1623 struct page *d_page = cc->d_page; migrate_zspage() local
1639 if (zspage_full(d_page)) { migrate_zspage()
1646 free_obj = obj_malloc(d_page, class, handle); migrate_zspage()
1738 cc.d_page = dst_page; __zs_compact()
/linux-4.1.27/kernel/power/
H A Dsnapshot.c1233 struct page *s_page, *d_page; copy_data_page() local
1237 d_page = pfn_to_page(dst_pfn); copy_data_page()
1240 dst = kmap_atomic(d_page); copy_data_page()
1245 if (PageHighMem(d_page)) { copy_data_page()
1250 dst = kmap_atomic(d_page); copy_data_page()
1254 safe_copy_page(page_address(d_page), s_page); copy_data_page()

Completed in 136 milliseconds