diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2014-08-29 10:14:35 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2014-08-29 10:14:35 +0100 |
commit | b822bc8c2c0b47dfc391c86c3e5764f718898dce (patch) | |
tree | 2d9be535521c2971645721726be4f53160900333 | |
parent | 8f584f83dc8440f0cbec7db3ed8a071d4896c25a (diff) |
sna/gen8: Check instead of asserting for a hang whilst setting up video state
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r-- | src/sna/gen8_render.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/sna/gen8_render.c b/src/sna/gen8_render.c index 826675ce..22df53db 100644 --- a/src/sna/gen8_render.c +++ b/src/sna/gen8_render.c @@ -193,10 +193,6 @@ static const struct blendinfo { #define FILL_FLAGS(op, format) GEN8_SET_FLAGS(FILL_SAMPLER, gen8_get_blend((op), false, (format)), GEN8_WM_KERNEL_NOMASK, FILL_VERTEX) #define FILL_FLAGS_NOBLEND GEN8_SET_FLAGS(FILL_SAMPLER, NO_BLEND, GEN8_WM_KERNEL_NOMASK, FILL_VERTEX) -#define VIDEO_SAMPLER \ - SAMPLER_OFFSET(SAMPLER_FILTER_BILINEAR, SAMPLER_EXTEND_PAD, \ - SAMPLER_FILTER_NEAREST, SAMPLER_EXTEND_NONE) - #define GEN8_SAMPLER(f) (((f) >> 20) & 0xfff) #define GEN8_BLEND(f) (((f) >> 4) & 0x7ff) #define GEN8_READS_DST(f) (((f) >> 15) & 1) @@ -3759,7 +3755,9 @@ gen8_render_video(struct sna *sna, kgem_set_mode(&sna->kgem, KGEM_RENDER, tmp.dst.bo); if (!kgem_check_bo(&sna->kgem, tmp.dst.bo, frame->bo, NULL)) { kgem_submit(&sna->kgem); - assert(kgem_check_bo(&sna->kgem, tmp.dst.bo, frame->bo, NULL)); + if (!kgem_check_bo(&sna->kgem, tmp.dst.bo, frame->bo, NULL)) + return false; + _kgem_set_mode(&sna->kgem, KGEM_RENDER); } |