diff options
author | Marek Olšák <[email protected]> | 2015-09-10 19:25:14 +0200 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2015-09-24 19:51:43 +0200 |
commit | ae418a7b5640aadb625bb7a7d6e4aa0a98ccb77f (patch) | |
tree | c67582fa3b4ea0cf51f937e738defa42be32212d /src/gallium/drivers/radeonsi/si_pipe.c | |
parent | b737d9c1dce073aa36b21c33cb30fbae89c38153 (diff) |
radeonsi: handle dummy constant buffer allocation failure
Cc: 11.0 <[email protected]>
Acked-by: Christian König <[email protected]>
Reviewed-by: Michel Dänzer <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeonsi/si_pipe.c')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_pipe.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeonsi/si_pipe.c b/src/gallium/drivers/radeonsi/si_pipe.c index 01fa5252f71..9edee50ac8a 100644 --- a/src/gallium/drivers/radeonsi/si_pipe.c +++ b/src/gallium/drivers/radeonsi/si_pipe.c @@ -180,6 +180,8 @@ static struct pipe_context *si_create_context(struct pipe_screen *screen, if (sctx->b.chip_class == CIK) { sctx->null_const_buf.buffer = pipe_buffer_create(screen, PIPE_BIND_CONSTANT_BUFFER, PIPE_USAGE_DEFAULT, 16); + if (!sctx->null_const_buf.buffer) + goto fail; sctx->null_const_buf.buffer_size = sctx->null_const_buf.buffer->width0; for (shader = 0; shader < SI_NUM_SHADERS; shader++) { |