Mesa (master): i965/gen4-5: Fix segfaults with stencil-only depth/ stencil setups.
Eric Anholt
anholt at kemper.freedesktop.org
Wed Nov 28 19:46:31 UTC 2012
Module: Mesa
Branch: master
Commit: c8ed9f6262a73849a64c55bcfaac2a50e42e0945
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=c8ed9f6262a73849a64c55bcfaac2a50e42e0945
Author: Eric Anholt <eric at anholt.net>
Date: Mon Nov 26 14:46:11 2012 -0800
i965/gen4-5: Fix segfaults with stencil-only depth/stencil setups.
Fixes a ton of piglit regressions since the depthstencil fixes for gen6+.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=57309
Reviewed-by: Chad Versace <chad.versace at linux.intel.com>
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
---
src/mesa/drivers/dri/i965/brw_misc_state.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_misc_state.c b/src/mesa/drivers/dri/i965/brw_misc_state.c
index 9c07be2..b0a1918 100644
--- a/src/mesa/drivers/dri/i965/brw_misc_state.c
+++ b/src/mesa/drivers/dri/i965/brw_misc_state.c
@@ -554,8 +554,10 @@ static void emit_depthbuffer(struct brw_context *brw)
/* If there's a packed depth/stencil bound to stencil only, we need to
* emit the packed depth/stencil buffer packet.
*/
- if (!depth_irb && stencil_irb && !separate_stencil)
+ if (!depth_irb && stencil_irb && !separate_stencil) {
depth_irb = stencil_irb;
+ depth_mt = stencil_mt;
+ }
if (intel->gen >= 6)
len = 7;
More information about the mesa-commit
mailing list