diff options
author | Thomas Zimmermann <tzimmermann@suse.de> | 2020-06-09 11:08:19 +0200 |
---|---|---|
committer | Thomas Zimmermann <tzimmermann@suse.de> | 2020-06-10 10:16:43 +0200 |
commit | d18ee06b4889bf7da412069ef60baeaaca3ac6f4 (patch) | |
tree | 0a8b690ca1695f40320f8349b344214aa993f59c /include/drm/drm_gem_shmem_helper.h | |
parent | ad0f449bebc79b01583c711684fefcdc9620320a (diff) |
drm/shmem-helper: Add .gem_create_object helper that sets map_cached flag
The helper drm_gem_shmem_create_object_cached() allocates an GEM SHMEM
object and sets the map_cached flag. Useful for drivers that want cached
mappings.
v3:
* style fixes
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200609090820.20256-2-tzimmermann@suse.de
Diffstat (limited to 'include/drm/drm_gem_shmem_helper.h')
-rw-r--r-- | include/drm/drm_gem_shmem_helper.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/drm/drm_gem_shmem_helper.h b/include/drm/drm_gem_shmem_helper.h index 294b2931c4cc..5381f0c8cf6f 100644 --- a/include/drm/drm_gem_shmem_helper.h +++ b/include/drm/drm_gem_shmem_helper.h @@ -132,6 +132,10 @@ struct drm_gem_shmem_object * drm_gem_shmem_create_with_handle(struct drm_file *file_priv, struct drm_device *dev, size_t size, uint32_t *handle); + +struct drm_gem_object * +drm_gem_shmem_create_object_cached(struct drm_device *dev, size_t size); + int drm_gem_shmem_dumb_create(struct drm_file *file, struct drm_device *dev, struct drm_mode_create_dumb *args); |