gallium/radeon: use radeon_emit_array
authorNicolai Hähnle <nicolai.haehnle@amd.com>
Fri, 6 May 2016 22:07:10 +0000 (17:07 -0500)
committerNicolai Hähnle <nicolai.haehnle@amd.com>
Tue, 17 May 2016 20:28:39 +0000 (15:28 -0500)
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/gallium/drivers/r600/r600_state_common.c

index eed46b0922daee01b871e454dda1929b7c9a7f89..42838c28d9366f6d890aba0e607f72655de79f79 100644 (file)
@@ -1907,8 +1907,7 @@ static void r600_draw_vbo(struct pipe_context *ctx, const struct pipe_draw_info
                        radeon_emit(cs, PKT3(PKT3_DRAW_INDEX_IMMD, 1 + size_dw, render_cond_bit));
                        radeon_emit(cs, info.count);
                        radeon_emit(cs, V_0287F0_DI_SRC_SEL_IMMEDIATE);
-                       memcpy(cs->buf+cs->cdw, ib.user_buffer, size_bytes);
-                       cs->cdw += size_dw;
+                       radeon_emit_array(cs, ib.user_buffer, size_dw);
                } else {
                        uint64_t va = r600_resource(ib.buffer)->gpu_address + ib.offset;