Lines Matching full:gem

29  * This library provides &struct drm_gem_vram_object (GEM VRAM), a GEM
34 * manager for simple framebuffer devices with dedicated video memory. GEM
38 * With the GEM interface userspace applications create, manage and destroy
39 * graphics buffers, such as an on-screen framebuffer. GEM does not provide
46 * left in VRAM, inactive GEM objects can be moved to system memory.
83 * interfaces for GEM buffer management and initializes file operations to
84 * allow for accessing created GEM buffers. With this setup, the DRM driver
85 * manages an area of video RAM with VRAM MM and provides GEM VRAM objects
117 * up; only release the GEM object. in drm_gem_vram_cleanup()
170 * drm_gem_vram_create() - Creates a VRAM-backed GEM object
175 * GEM objects are allocated by calling struct drm_driver.gem_create_object,
176 * if set. Otherwise kzalloc() will be used. Drivers can set their own GEM
178 * are set, the new GEM object will use the default functions from GEM VRAM
190 struct drm_gem_object *gem; in drm_gem_vram_create() local
199 gem = dev->driver->gem_create_object(dev, size); in drm_gem_vram_create()
200 if (IS_ERR(gem)) in drm_gem_vram_create()
201 return ERR_CAST(gem); in drm_gem_vram_create()
202 gbo = drm_gem_vram_of_gem(gem); in drm_gem_vram_create()
207 gem = &gbo->bo.base; in drm_gem_vram_create()
210 if (!gem->funcs) in drm_gem_vram_create()
211 gem->funcs = &drm_gem_vram_object_funcs; in drm_gem_vram_create()
213 ret = drm_gem_object_init(dev, gem, size); in drm_gem_vram_create()
239 * drm_gem_vram_put() - Releases a reference to a VRAM-backed GEM object
240 * @gbo: the GEM VRAM object
261 * drm_gem_vram_offset() - Returns a GEM VRAM object's offset in video memory
262 * @gbo: the GEM VRAM object
304 * drm_gem_vram_pin() - Pins a GEM VRAM object in a region.
305 * @gbo: the GEM VRAM object
348 * drm_gem_vram_unpin() - Unpins a GEM VRAM object
349 * @gbo: the GEM VRAM object
371 * drm_gem_vram_vmap() - Pins and maps a GEM VRAM object into kernel address
373 * @gbo: The GEM VRAM object to map
374 * @map: Returns the kernel virtual address of the VRAM GEM object's backing
377 * The vmap function pins a GEM VRAM object to its current location, either
381 * unmap and unpin the GEM VRAM object.
415 * drm_gem_vram_vunmap() - Unmaps and unpins a GEM VRAM object
416 * @gbo: The GEM VRAM object to unmap
417 * @map: Kernel virtual address where the VRAM GEM object was mapped
419 * A call to drm_gem_vram_vunmap() unmaps and unpins a GEM VRAM buffer. See
555 * @gem: GEM object. Refers to &struct drm_gem_vram_object.gem
557 static void drm_gem_vram_object_free(struct drm_gem_object *gem) in drm_gem_vram_object_free() argument
559 struct drm_gem_vram_object *gbo = drm_gem_vram_of_gem(gem); in drm_gem_vram_object_free()
622 * pins the GEM VRAM objects of the plane's new framebuffer to VRAM.
672 * During plane updates, this function unpins the GEM VRAM
699 * During plane updates, this function pins the GEM VRAM
721 * During plane updates, this function unpins the GEM VRAM
739 * @gem: The GEM object to pin
745 static int drm_gem_vram_object_pin(struct drm_gem_object *gem) in drm_gem_vram_object_pin() argument
747 struct drm_gem_vram_object *gbo = drm_gem_vram_of_gem(gem); in drm_gem_vram_object_pin()
763 * @gem: The GEM object to unpin
765 static void drm_gem_vram_object_unpin(struct drm_gem_object *gem) in drm_gem_vram_object_unpin() argument
767 struct drm_gem_vram_object *gbo = drm_gem_vram_of_gem(gem); in drm_gem_vram_object_unpin()
775 * @gem: The GEM object to map
776 * @map: Returns the kernel virtual address of the VRAM GEM object's backing
782 static int drm_gem_vram_object_vmap(struct drm_gem_object *gem, in drm_gem_vram_object_vmap() argument
785 struct drm_gem_vram_object *gbo = drm_gem_vram_of_gem(gem); in drm_gem_vram_object_vmap()
793 * @gem: The GEM object to unmap
794 * @map: Kernel virtual address where the VRAM GEM object was mapped
796 static void drm_gem_vram_object_vunmap(struct drm_gem_object *gem, in drm_gem_vram_object_vunmap() argument
799 struct drm_gem_vram_object *gbo = drm_gem_vram_of_gem(gem); in drm_gem_vram_object_vunmap()
805 * GEM object funcs
862 /* TTM may pass BOs that are not GEM VRAM BOs. */ in bo_driver_evict_flags()
875 /* TTM may pass BOs that are not GEM VRAM BOs. */ in bo_driver_delete_mem_notify()