summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2011-10-17 17:16:16 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2011-10-17 17:59:53 +0100
commit29ca1a3922cb0e6f3d7b71857a252e5de81941b5 (patch)
treecd7672db2263e43b83124ead53047e78274892b9
parent88bc10878830dffefda6ed905c1f598d7a7d67ef (diff)
sna/gen3: More removal of memset(0)
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r--src/sna/gen3_render.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/sna/gen3_render.c b/src/sna/gen3_render.c
index a6afbb1d..11b56ac0 100644
--- a/src/sna/gen3_render.c
+++ b/src/sna/gen3_render.c
@@ -3745,6 +3745,8 @@ gen3_render_fill(struct sna *sna, uint8_t alu,
tmp->base.src.u.gen3.type = SHADER_CONSTANT;
tmp->base.src.u.gen3.mode =
sna_rgba_for_color(color, dst->drawable.depth);
+ tmp->base.mask.u.gen3.type = SHADER_NONE;
+ tmp->base.u.gen3.num_constants = 0;
if (!kgem_check_bo(&sna->kgem, dst_bo, NULL))
kgem_submit(&sna->kgem);
@@ -3757,7 +3759,6 @@ gen3_render_fill(struct sna *sna, uint8_t alu,
return TRUE;
}
-
static Bool
gen3_render_fill_one_try_blt(struct sna *sna, PixmapPtr dst, struct kgem_bo *bo,
uint32_t color,
@@ -3806,7 +3807,6 @@ gen3_render_fill_one(struct sna *sna, PixmapPtr dst, struct kgem_bo *bo,
if (alu == GXclear)
color = 0;
- memset(&tmp, 0, sizeof(tmp));
tmp.op = color == 0 ? PictOpClear : PictOpSrc;
tmp.dst.pixmap = dst;
tmp.dst.width = dst->drawable.width;
@@ -3819,6 +3819,8 @@ gen3_render_fill_one(struct sna *sna, PixmapPtr dst, struct kgem_bo *bo,
tmp.src.u.gen3.type = SHADER_CONSTANT;
tmp.src.u.gen3.mode =
sna_rgba_for_color(color, dst->drawable.depth);
+ tmp.mask.u.gen3.mode = SHADER_NONE;
+ tmp.u.gen3.num_constants = 0;
if (!kgem_check_bo(&sna->kgem, bo, NULL)) {
kgem_submit(&sna->kgem);