summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorChristoph Bumiller <[email protected]>2011-10-14 22:19:01 +0200
committerChristoph Bumiller <[email protected]>2011-10-21 23:00:39 +0200
commit840bc04b43a3799eb4fce004672c765e0278fd31 (patch)
tree54d56bf9d7d4884d705e7ec6a35a14b18f88e613 /src/gallium
parent6db14200eb2ba09e4ab28f8880dae5d30cc861d0 (diff)
nvc0: emit state to allow GP to select the RT layer
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/drivers/nvc0/nvc0_shader_state.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gallium/drivers/nvc0/nvc0_shader_state.c b/src/gallium/drivers/nvc0/nvc0_shader_state.c
index 6d014ee8699..472bdb11aba 100644
--- a/src/gallium/drivers/nvc0/nvc0_shader_state.c
+++ b/src/gallium/drivers/nvc0/nvc0_shader_state.c
@@ -190,6 +190,7 @@ nvc0_gmtyprog_validate(struct nvc0_context *nvc0)
if (!gp) {
BEGIN_RING(chan, RING_3D(GP_SELECT), 1);
OUT_RING (chan, 0x40);
+ IMMED_RING(chan, RING_3D(LAYER), 0);
return;
}
if (!nvc0_program_validate(nvc0, gp))
@@ -201,7 +202,9 @@ nvc0_gmtyprog_validate(struct nvc0_context *nvc0)
BEGIN_RING(chan, RING_3D(SP_START_ID(4)), 1);
OUT_RING (chan, gp->code_base);
BEGIN_RING(chan, RING_3D(SP_GPR_ALLOC(4)), 1);
- OUT_RING (chan, gp->max_gpr);
+ OUT_RING (chan, gp->max_gpr);
+ BEGIN_RING(chan, RING_3D(LAYER), 1);
+ OUT_RING (chan, (gp->hdr[13] & (1 << 9)) ? NVC0_3D_LAYER_USE_GP : 0);
}
/* It's *is* kind of shader related. We need to inspect the program