The change for GPU hanging in
13bab58f04c1ec6d0d52760eab490a0997d9abe2
fell back even when rb == NULL, which is wrong for GLES2 and caused
segfaulting in GLES2 conformance. For the GPU hang case (where the
broken 2D driver failed to allocate a BO for the window system
renderbuffer), it also would assertion fail/segfault immediately after
the fallback setup when the renderbuffer map failed.
Fixes GLES2 conformance packed_depth_stencil.
Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
struct intel_renderbuffer *irb = intel_renderbuffer(rb);
struct intel_region *region = irb ? irb->region : NULL;
- if (region == NULL || region->buffer == NULL) {
- brw->intel.Fallback = GL_TRUE; /* boolean, not bitfield */
- return;
- }
-
- brw_add_validated_bo(brw, region->buffer);
+ if (region)
+ brw_add_validated_bo(brw, region->buffer);
nr_surfaces = SURF_INDEX_DRAW(i) + 1;
}
}
struct intel_renderbuffer *irb = intel_renderbuffer(rb);
struct intel_region *region = irb ? irb->region : NULL;
- if (region == NULL || region->buffer == NULL) {
- brw->intel.Fallback = GL_TRUE; /* boolean, not bitfield */
- return;
- }
-
- brw_add_validated_bo(brw, region->buffer);
+ if (region)
+ brw_add_validated_bo(brw, region->buffer);
nr_surfaces = SURF_INDEX_DRAW(i) + 1;
}
}