diff options
Diffstat (limited to 'libdrm')
-rw-r--r-- | libdrm/xf86drm.c | 19 | ||||
-rw-r--r-- | libdrm/xf86mm.h | 8 |
2 files changed, 6 insertions, 21 deletions
diff --git a/libdrm/xf86drm.c b/libdrm/xf86drm.c index bb2b3abe..c450a985 100644 --- a/libdrm/xf86drm.c +++ b/libdrm/xf86drm.c @@ -2698,8 +2698,8 @@ static void drmBOCopyReply(const struct drm_bo_info_rep *rep, drmBO *buf) -int drmBOCreate(int fd, unsigned long start, unsigned long size, - unsigned pageAlignment, void *user_buffer, drm_bo_type_t type, +int drmBOCreate(int fd, unsigned long size, + unsigned pageAlignment, void *user_buffer, uint64_t mask, unsigned hint, drmBO *buf) { @@ -2713,23 +2713,11 @@ int drmBOCreate(int fd, unsigned long start, unsigned long size, req->mask = mask; req->hint = hint; req->size = size; - req->type = type; req->page_alignment = pageAlignment; + req->buffer_start = (unsigned long) user_buffer; buf->virtual = NULL; - switch(type) { - case drm_bo_type_dc: - req->buffer_start = start; - break; - case drm_bo_type_user: - req->buffer_start = (unsigned long) user_buffer; - buf->virtual = user_buffer; - break; - default: - return -EINVAL; - } - do { ret = ioctl(fd, DRM_IOCTL_BO_CREATE, &arg); } while (ret != 0 && errno == EAGAIN); @@ -2777,7 +2765,6 @@ int drmBOReference(int fd, unsigned handle, drmBO *buf) return -errno; drmBOCopyReply(rep, buf); - buf->type = drm_bo_type_dc; buf->mapVirtual = NULL; buf->mapCount = 0; buf->virtual = NULL; diff --git a/libdrm/xf86mm.h b/libdrm/xf86mm.h index cacd13af..0dac7eff 100644 --- a/libdrm/xf86mm.h +++ b/libdrm/xf86mm.h @@ -106,7 +106,6 @@ typedef struct _drmFence typedef struct _drmBO { - drm_bo_type_t type; unsigned handle; uint64_t mapHandle; uint64_t flags; @@ -179,10 +178,9 @@ extern int drmBOCreateList(int numTarget, drmBOList *list); * Buffer object functions. */ -extern int drmBOCreate(int fd, unsigned long start, unsigned long size, - unsigned pageAlignment,void *user_buffer, - drm_bo_type_t type, uint64_t mask, - unsigned hint, drmBO *buf); +extern int drmBOCreate(int fd, unsigned long size, + unsigned pageAlignment, void *user_buffer, + uint64_t mask, unsigned hint, drmBO *buf); extern int drmBODestroy(int fd, drmBO *buf); extern int drmBOReference(int fd, unsigned handle, drmBO *buf); extern int drmBOUnReference(int fd, drmBO *buf); |