diff options
author | Rob Clark <[email protected]> | 2020-02-21 13:10:09 -0800 |
---|---|---|
committer | Marge Bot <[email protected]> | 2020-02-28 16:53:41 +0000 |
commit | 2fa64729db95655d61b92c5e155a4746101c1cfc (patch) | |
tree | 07ab3bb0a3371c2687cb4d74fe73cc20fb5481e1 /src/gallium | |
parent | bab9db6c0263e74696f300520db6380ee0803322 (diff) |
freedreno: honor FD_MESA_DEBUG=nogrow
Signed-off-by: Rob Clark <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3989>
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/drivers/freedreno/freedreno_batch.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/gallium/drivers/freedreno/freedreno_batch.c b/src/gallium/drivers/freedreno/freedreno_batch.c index 8f3f7827ce3..0dc27adb156 100644 --- a/src/gallium/drivers/freedreno/freedreno_batch.c +++ b/src/gallium/drivers/freedreno/freedreno_batch.c @@ -39,6 +39,7 @@ static void batch_init(struct fd_batch *batch) { struct fd_context *ctx = batch->ctx; + enum fd_ringbuffer_flags flags = 0; unsigned size = 0; /* if kernel is too old to support unlimited # of cmd buffers, we @@ -51,21 +52,23 @@ batch_init(struct fd_batch *batch) if ((fd_device_version(ctx->screen->dev) < FD_VERSION_UNLIMITED_CMDS) || (fd_mesa_debug & FD_DBG_NOGROW)){ size = 0x100000; + } else { + flags = FD_RINGBUFFER_GROWABLE; } batch->submit = fd_submit_new(ctx->pipe); if (batch->nondraw) { batch->draw = fd_submit_new_ringbuffer(batch->submit, size, - FD_RINGBUFFER_PRIMARY | FD_RINGBUFFER_GROWABLE); + FD_RINGBUFFER_PRIMARY | flags); } else { batch->gmem = fd_submit_new_ringbuffer(batch->submit, size, - FD_RINGBUFFER_PRIMARY | FD_RINGBUFFER_GROWABLE); + FD_RINGBUFFER_PRIMARY | flags); batch->draw = fd_submit_new_ringbuffer(batch->submit, size, - FD_RINGBUFFER_GROWABLE); + flags); if (ctx->screen->gpu_id < 600) { batch->binning = fd_submit_new_ringbuffer(batch->submit, - size, FD_RINGBUFFER_GROWABLE); + size, flags); } } |