summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers
diff options
context:
space:
mode:
authorChristian König <[email protected]>2012-07-25 22:39:15 +0200
committerChristian König <[email protected]>2012-07-30 15:01:51 +0200
commit1fb8ee62faf081e6a5588e99620a9883e3788c46 (patch)
tree654a852d8af23679b299ee8e731bff02a8d05763 /src/gallium/drivers
parentf18fd255cf283cdf4ba9326d437d1543fd38a139 (diff)
radeonsi: fix shader binding
Signed-off-by: Christian König <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r--src/gallium/drivers/radeonsi/si_state.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/gallium/drivers/radeonsi/si_state.c b/src/gallium/drivers/radeonsi/si_state.c
index c417c9cac65..a80e169b007 100644
--- a/src/gallium/drivers/radeonsi/si_state.c
+++ b/src/gallium/drivers/radeonsi/si_state.c
@@ -1649,7 +1649,10 @@ static void si_bind_vs_shader(struct pipe_context *ctx, void *state)
rctx->shader_dirty = true;
rctx->vs_shader = shader;
- si_pm4_bind_state(rctx, vs, shader->pm4);
+
+ if (shader) {
+ si_pm4_bind_state(rctx, vs, shader->pm4);
+ }
}
static void si_bind_ps_shader(struct pipe_context *ctx, void *state)
@@ -1662,7 +1665,10 @@ static void si_bind_ps_shader(struct pipe_context *ctx, void *state)
rctx->shader_dirty = true;
rctx->ps_shader = shader;
- si_pm4_bind_state(rctx, ps, shader->pm4);
+
+ if (shader) {
+ si_pm4_bind_state(rctx, ps, shader->pm4);
+ }
}
static void si_delete_vs_shader(struct pipe_context *ctx, void *state)