Lines Matching refs:mem
47 struct agp_memory *mem; member
55 struct agp_memory *mem; in ttm_agp_bind() local
59 mem = agp_allocate_memory(agp_be->bridge, ttm->num_pages, AGP_USER_MEMORY); in ttm_agp_bind()
60 if (unlikely(mem == NULL)) in ttm_agp_bind()
63 mem->page_count = 0; in ttm_agp_bind()
70 mem->pages[mem->page_count++] = page; in ttm_agp_bind()
72 agp_be->mem = mem; in ttm_agp_bind()
74 mem->is_flushed = 1; in ttm_agp_bind()
75 mem->type = (cached) ? AGP_USER_CACHED_MEMORY : AGP_USER_MEMORY; in ttm_agp_bind()
77 ret = agp_bind_memory(mem, node->start); in ttm_agp_bind()
88 if (agp_be->mem) { in ttm_agp_unbind()
89 if (agp_be->mem->is_bound) in ttm_agp_unbind()
90 return agp_unbind_memory(agp_be->mem); in ttm_agp_unbind()
91 agp_free_memory(agp_be->mem); in ttm_agp_unbind()
92 agp_be->mem = NULL; in ttm_agp_unbind()
101 if (agp_be->mem) in ttm_agp_destroy()
124 agp_be->mem = NULL; in ttm_agp_tt_create()