Lines Matching refs:agp_be
52 struct ttm_agp_backend *agp_be = container_of(ttm, struct ttm_agp_backend, ttm); in ttm_agp_bind() local
58 if (agp_be->mem) in ttm_agp_bind()
61 mem = agp_allocate_memory(agp_be->bridge, ttm->num_pages, AGP_USER_MEMORY); in ttm_agp_bind()
74 agp_be->mem = mem; in ttm_agp_bind()
89 struct ttm_agp_backend *agp_be = container_of(ttm, struct ttm_agp_backend, ttm); in ttm_agp_unbind() local
91 if (agp_be->mem) { in ttm_agp_unbind()
92 if (agp_be->mem->is_bound) { in ttm_agp_unbind()
93 agp_unbind_memory(agp_be->mem); in ttm_agp_unbind()
96 agp_free_memory(agp_be->mem); in ttm_agp_unbind()
97 agp_be->mem = NULL; in ttm_agp_unbind()
104 struct ttm_agp_backend *agp_be = container_of(ttm, struct ttm_agp_backend, ttm); in ttm_agp_is_bound() local
109 return (agp_be->mem != NULL); in ttm_agp_is_bound()
115 struct ttm_agp_backend *agp_be = container_of(ttm, struct ttm_agp_backend, ttm); in ttm_agp_destroy() local
117 if (agp_be->mem) in ttm_agp_destroy()
120 kfree(agp_be); in ttm_agp_destroy()
128 struct ttm_agp_backend *agp_be; in ttm_agp_tt_create() local
130 agp_be = kmalloc(sizeof(*agp_be), GFP_KERNEL); in ttm_agp_tt_create()
131 if (!agp_be) in ttm_agp_tt_create()
134 agp_be->mem = NULL; in ttm_agp_tt_create()
135 agp_be->bridge = bridge; in ttm_agp_tt_create()
137 if (ttm_tt_init(&agp_be->ttm, bo, page_flags, ttm_write_combined, 0)) { in ttm_agp_tt_create()
138 kfree(agp_be); in ttm_agp_tt_create()
142 return &agp_be->ttm; in ttm_agp_tt_create()