summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/cell
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2009-03-04 09:34:46 -0700
committerBrian Paul <brianp@vmware.com>2009-03-04 09:34:46 -0700
commitca06c0c16d09d58f96736aa095e1a592862a9427 (patch)
tree220db1f7504d7142b044e305e2a0f78f53918c45 /src/gallium/drivers/cell
parentfba923ff4415ce8a14c890dea65bcb07b2f87fb5 (diff)
cell: update cell driver after gallium reference count changes
Diffstat (limited to 'src/gallium/drivers/cell')
-rw-r--r--src/gallium/drivers/cell/ppu/cell_state_shader.c4
-rw-r--r--src/gallium/drivers/cell/ppu/cell_texture.c5
2 files changed, 3 insertions, 6 deletions
diff --git a/src/gallium/drivers/cell/ppu/cell_state_shader.c b/src/gallium/drivers/cell/ppu/cell_state_shader.c
index bf517ea563..6568c784fe 100644
--- a/src/gallium/drivers/cell/ppu/cell_state_shader.c
+++ b/src/gallium/drivers/cell/ppu/cell_state_shader.c
@@ -193,9 +193,7 @@ cell_set_constant_buffer(struct pipe_context *pipe,
draw_flush(cell->draw);
/* note: reference counting */
- pipe_buffer_reference(pipe->screen,
- &cell->constants[shader].buffer,
- buf->buffer);
+ pipe_buffer_reference(&cell->constants[shader].buffer, buf->buffer);
if (shader == PIPE_SHADER_VERTEX)
cell->dirty |= CELL_NEW_VS_CONSTANTS;
diff --git a/src/gallium/drivers/cell/ppu/cell_texture.c b/src/gallium/drivers/cell/ppu/cell_texture.c
index bc6afa94a8..e26594448f 100644
--- a/src/gallium/drivers/cell/ppu/cell_texture.c
+++ b/src/gallium/drivers/cell/ppu/cell_texture.c
@@ -129,7 +129,7 @@ cell_texture_destroy(struct pipe_texture *pt)
struct cell_texture *ct = cell_texture(pt);
if (ct->mapped) {
- pipe_buffer_unmap(screen, ct->buffer);
+ pipe_buffer_unmap(ct->buffer->screen, ct->buffer);
ct->mapped = NULL;
}
@@ -308,7 +308,7 @@ cell_get_tex_surface(struct pipe_screen *screen,
static void
-cell_tex_surface_destroy(struct pipe_surface *s)
+cell_tex_surface_destroy(struct pipe_surface *surf)
{
pipe_texture_reference(&surf->texture, NULL);
FREE(surf);
@@ -336,7 +336,6 @@ cell_get_tex_transfer(struct pipe_screen *screen,
ctrans = CALLOC_STRUCT(cell_transfer);
if (ctrans) {
struct pipe_transfer *pt = &ctrans->base;
- pipe_reference_init(&pt->reference, 1);
pipe_texture_reference(&pt->texture, texture);
pt->format = texture->format;
pt->block = texture->block;