diff options
author | Dave Airlie <airlied@redhat.com> | 2011-02-06 21:16:14 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2011-02-06 21:16:14 -0500 |
commit | ff72145badb834e8051719ea66e024784d000cb4 (patch) | |
tree | 39dc5fc512e3e0836713de9defb91ea8b4033aa2 /drivers/gpu/drm/radeon/radeon.h | |
parent | 1f692a14cbfbeb11f9a9c16f25c8ecb8ab50d3d5 (diff) |
drm: dumb scanout create/mmap for intel/radeon (v3)
This is just an idea that might or might not be a good idea,
it basically adds two ioctls to create a dumb and map a dumb buffer
suitable for scanout. The handle can be passed to the KMS ioctls to create
a framebuffer.
It looks to me like it would be useful in the following cases:
a) in development drivers - we can always provide a shadowfb fallback.
b) libkms users - we can clean up libkms a lot and avoid linking
to libdrm_*.
c) plymouth via libkms is a lot easier.
Userspace bits would be just calls + mmaps. We could probably
mark these handles somehow as not being suitable for acceleartion
so as top stop people who are dumber than dumb.
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon.h')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/radeon.h index 56c48b67ef3d..a4605362c528 100644 --- a/drivers/gpu/drm/radeon/radeon.h +++ b/drivers/gpu/drm/radeon/radeon.h | |||
@@ -288,6 +288,15 @@ int radeon_gem_object_pin(struct drm_gem_object *obj, uint32_t pin_domain, | |||
288 | uint64_t *gpu_addr); | 288 | uint64_t *gpu_addr); |
289 | void radeon_gem_object_unpin(struct drm_gem_object *obj); | 289 | void radeon_gem_object_unpin(struct drm_gem_object *obj); |
290 | 290 | ||
291 | int radeon_mode_dumb_create(struct drm_file *file_priv, | ||
292 | struct drm_device *dev, | ||
293 | struct drm_mode_create_dumb *args); | ||
294 | int radeon_mode_dumb_mmap(struct drm_file *filp, | ||
295 | struct drm_device *dev, | ||
296 | uint32_t handle, uint64_t *offset_p); | ||
297 | int radeon_mode_dumb_destroy(struct drm_file *file_priv, | ||
298 | struct drm_device *dev, | ||
299 | uint32_t handle); | ||
291 | 300 | ||
292 | /* | 301 | /* |
293 | * GART structures, functions & helpers | 302 | * GART structures, functions & helpers |