diff options
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r-- | src/gallium/drivers/nvc0/nvc0_video.c | 18 | ||||
-rw-r--r-- | src/gallium/drivers/nvc0/nvc0_video_bsp.c | 2 | ||||
-rw-r--r-- | src/gallium/drivers/nvc0/nvc0_video_ppp.c | 2 | ||||
-rw-r--r-- | src/gallium/drivers/nvc0/nvc0_video_vp.c | 2 |
4 files changed, 15 insertions, 9 deletions
diff --git a/src/gallium/drivers/nvc0/nvc0_video.c b/src/gallium/drivers/nvc0/nvc0_video.c index 462637b1a8b..cf61804bd0f 100644 --- a/src/gallium/drivers/nvc0/nvc0_video.c +++ b/src/gallium/drivers/nvc0/nvc0_video.c @@ -440,7 +440,7 @@ nvc0_create_decoder(struct pipe_context *context, #if NVC0_DEBUG_FENCE ret = nouveau_bo_new(screen->device, NOUVEAU_BO_GART|NOUVEAU_BO_MAP, - 0, 0x1000, &cfg, &dec->fence_bo); + 0, 0x1000, NULL, &dec->fence_bo); if (ret) goto fail; @@ -450,36 +450,42 @@ nvc0_create_decoder(struct pipe_context *context, dec->comm = (struct comm *)(dec->fence_map + (COMM_OFFSET/sizeof(*dec->fence_map))); /* So lets test if the fence is working? */ + PUSH_SPACE(push[0], 6); + PUSH_REFN (push[0], dec->fence_bo, NOUVEAU_BO_GART|NOUVEAU_BO_RDWR); BEGIN_NVC0(push[0], SUBC_BSP(0x240), 3); PUSH_DATAh(push[0], dec->fence_bo->offset); PUSH_DATA (push[0], dec->fence_bo->offset); PUSH_DATA (push[0], dec->fence_seq); BEGIN_NVC0(push[0], SUBC_BSP(0x304), 1); - PUSH_DATA (push[0], 1); + PUSH_DATA (push[0], 0); PUSH_KICK (push[0]); + PUSH_SPACE(push[1], 6); + PUSH_REFN (push[1], dec->fence_bo, NOUVEAU_BO_GART|NOUVEAU_BO_RDWR); BEGIN_NVC0(push[1], SUBC_VP(0x240), 3); PUSH_DATAh(push[1], (dec->fence_bo->offset + 0x10)); PUSH_DATA (push[1], (dec->fence_bo->offset + 0x10)); PUSH_DATA (push[1], dec->fence_seq); BEGIN_NVC0(push[1], SUBC_VP(0x304), 1); - PUSH_DATA (push[1], 1); + PUSH_DATA (push[1], 0); PUSH_KICK (push[1]); + PUSH_SPACE(push[2], 6); + PUSH_REFN (push[2], dec->fence_bo, NOUVEAU_BO_GART|NOUVEAU_BO_RDWR); BEGIN_NVC0(push[2], SUBC_PPP(0x240), 3); PUSH_DATAh(push[2], (dec->fence_bo->offset + 0x20)); PUSH_DATA (push[2], (dec->fence_bo->offset + 0x20)); PUSH_DATA (push[2], dec->fence_seq); BEGIN_NVC0(push[2], SUBC_PPP(0x304), 1); - PUSH_DATA (push[2], 1); + PUSH_DATA (push[2], 0); PUSH_KICK (push[2]); usleep(100); - while (dec->fence_seq > dec->fence_map[0] && - dec->fence_seq > dec->fence_map[4] && + while (dec->fence_seq > dec->fence_map[0] || + dec->fence_seq > dec->fence_map[4] || dec->fence_seq > dec->fence_map[8]) { debug_printf("%u: %u %u %u\n", dec->fence_seq, dec->fence_map[0], dec->fence_map[4], dec->fence_map[8]); usleep(100); diff --git a/src/gallium/drivers/nvc0/nvc0_video_bsp.c b/src/gallium/drivers/nvc0/nvc0_video_bsp.c index 6fe5018cd38..09e78aa5059 100644 --- a/src/gallium/drivers/nvc0/nvc0_video_bsp.c +++ b/src/gallium/drivers/nvc0/nvc0_video_bsp.c @@ -406,7 +406,7 @@ nvc0_decoder_bsp(struct nvc0_decoder *dec, union pipe_desc desc, do { usleep(100); if ((spin++ & 0xff) == 0xff) { - debug_printf("%u: %u\n", dec->fence_seq, dec->fence_map[0]); + debug_printf("b%u: %u\n", dec->fence_seq, dec->fence_map[0]); dump_comm_bsp(dec->comm); } } while (dec->fence_seq > dec->fence_map[0]); diff --git a/src/gallium/drivers/nvc0/nvc0_video_ppp.c b/src/gallium/drivers/nvc0/nvc0_video_ppp.c index b5369124129..4eb5932e051 100644 --- a/src/gallium/drivers/nvc0/nvc0_video_ppp.c +++ b/src/gallium/drivers/nvc0/nvc0_video_ppp.c @@ -132,7 +132,7 @@ nvc0_decoder_ppp(struct nvc0_decoder *dec, union pipe_desc desc, struct nvc0_vid do { usleep(100); if ((spin++ & 0xff) == 0xff) - debug_printf("ppp%u: %u\n", dec->fence_seq, dec->fence_map[8]); + debug_printf("p%u: %u\n", dec->fence_seq, dec->fence_map[8]); } while (dec->fence_seq > dec->fence_map[8]); } #else diff --git a/src/gallium/drivers/nvc0/nvc0_video_vp.c b/src/gallium/drivers/nvc0/nvc0_video_vp.c index 8b3f81b3ea8..eab544da2d3 100644 --- a/src/gallium/drivers/nvc0/nvc0_video_vp.c +++ b/src/gallium/drivers/nvc0/nvc0_video_vp.c @@ -653,7 +653,7 @@ nvc0_decoder_vp(struct nvc0_decoder *dec, union pipe_desc desc, do { usleep(100); if ((spin++ & 0xff) == 0xff) { - debug_printf("vp%u: %u\n", dec->fence_seq, dec->fence_map[4]); + debug_printf("v%u: %u\n", dec->fence_seq, dec->fence_map[4]); dump_comm_vp(dec, dec->comm, comm_seq, inter_bo, slice_size << 8); } } while (dec->fence_seq > dec->fence_map[4]); |