aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/winsys/xlib/xlib_softpipe.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/winsys/xlib/xlib_softpipe.c')
-rw-r--r--src/gallium/winsys/xlib/xlib_softpipe.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/gallium/winsys/xlib/xlib_softpipe.c b/src/gallium/winsys/xlib/xlib_softpipe.c
index 71f12b2b47a..762ebd98477 100644
--- a/src/gallium/winsys/xlib/xlib_softpipe.c
+++ b/src/gallium/winsys/xlib/xlib_softpipe.c
@@ -207,8 +207,7 @@ xm_buffer_unmap(struct pipe_winsys *pws, struct pipe_buffer *buf)
}
static void
-xm_buffer_destroy(struct pipe_winsys *pws,
- struct pipe_buffer *buf)
+xm_buffer_destroy(struct pipe_buffer *buf)
{
struct xm_buffer *oldBuf = xm_buffer(buf);
@@ -338,7 +337,7 @@ xm_buffer_create(struct pipe_winsys *pws,
}
#endif
- buffer->base.refcount = 1;
+ pipe_reference_init(&buffer->base.reference, 1);
buffer->base.alignment = alignment;
buffer->base.usage = usage;
buffer->base.size = size;
@@ -359,7 +358,7 @@ static struct pipe_buffer *
xm_user_buffer_create(struct pipe_winsys *pws, void *ptr, unsigned bytes)
{
struct xm_buffer *buffer = CALLOC_STRUCT(xm_buffer);
- buffer->base.refcount = 1;
+ pipe_reference_init(&buffer->base.reference, 1);
buffer->base.size = bytes;
buffer->userBuffer = TRUE;
buffer->data = ptr;