summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r300
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2014-04-11 20:34:46 +0200
committerMarek Olšák <[email protected]>2014-04-16 14:02:51 +0200
commitb2238b3452b0bcf3c1216c20c9918f9f0664b464 (patch)
tree2d5c1495530758f977a9c435f0c8632e4d653b37 /src/gallium/drivers/r300
parent927213f33d0379c34033048d24592715d3f7ef96 (diff)
winsys/radeon: remove cs_write_reloc, add simpler cs_get_reloc
The only difference is that it doesn't write to the CS and only returns the index. Reviewed-by: Christian König <[email protected]>
Diffstat (limited to 'src/gallium/drivers/r300')
-rw-r--r--src/gallium/drivers/r300/r300_cs.h3
-rw-r--r--src/gallium/drivers/r300/r300_emit.c4
2 files changed, 4 insertions, 3 deletions
diff --git a/src/gallium/drivers/r300/r300_cs.h b/src/gallium/drivers/r300/r300_cs.h
index 744e19e44e2..748d6eacc9e 100644
--- a/src/gallium/drivers/r300/r300_cs.h
+++ b/src/gallium/drivers/r300/r300_cs.h
@@ -109,7 +109,8 @@
#define OUT_CS_RELOC(r) do { \
assert((r)); \
assert((r)->cs_buf); \
- cs_winsys->cs_write_reloc(cs_copy, (r)->cs_buf); \
+ OUT_CS(0xc0001000); /* PKT3_NOP */ \
+ OUT_CS(cs_winsys->cs_get_reloc(cs_copy, (r)->cs_buf) * 4); \
CS_USED_DW(2); \
} while (0)
diff --git a/src/gallium/drivers/r300/r300_emit.c b/src/gallium/drivers/r300/r300_emit.c
index d99b91919c4..9f164139213 100644
--- a/src/gallium/drivers/r300/r300_emit.c
+++ b/src/gallium/drivers/r300/r300_emit.c
@@ -1043,8 +1043,8 @@ void r300_emit_vertex_arrays_swtcl(struct r300_context *r300, boolean indexed)
OUT_CS(0);
assert(r300->vbo_cs);
- cs_winsys->cs_write_reloc(cs_copy, r300->vbo_cs);
- CS_USED_DW(2);
+ OUT_CS(0xc0001000); /* PKT3_NOP */
+ OUT_CS(r300->rws->cs_get_reloc(r300->cs, r300->vbo_cs) * 4);
END_CS;
}