diff options
author | Patrick Lerda <[email protected]> | 2019-05-13 00:03:22 +0200 |
---|---|---|
committer | Patrick Lerda <[email protected]> | 2019-05-13 13:32:55 +0200 |
commit | 38c5a5a8b51bdeab1672a8a8ea54caa27ffdafee (patch) | |
tree | 8af18350e00abbc0886be02f5f7de6bb4f93ce90 /src/gallium/drivers/lima/lima_state.c | |
parent | f53ebfb4503a1ae054539df1c414b86c3b1966d9 (diff) |
lima: refactor plb_max_blk
Move plb_max_blk to lima_screen, and add a new debug option:
LIMA_PLB_MAX_BLK
Signed-off-by: Patrick Lerda <[email protected]>
Reviewed-by: Qiang Yu <[email protected]>
Diffstat (limited to 'src/gallium/drivers/lima/lima_state.c')
-rw-r--r-- | src/gallium/drivers/lima/lima_state.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gallium/drivers/lima/lima_state.c b/src/gallium/drivers/lima/lima_state.c index 1621618c865..3cb8c57ffc8 100644 --- a/src/gallium/drivers/lima/lima_state.c +++ b/src/gallium/drivers/lima/lima_state.c @@ -58,13 +58,15 @@ lima_set_framebuffer_state(struct pipe_context *pctx, int width = align(framebuffer->width, 16) >> 4; int height = align(framebuffer->height, 16) >> 4; if (fb->tiled_w != width || fb->tiled_h != height) { + struct lima_screen *screen = lima_screen(ctx->base.screen); + fb->tiled_w = width; fb->tiled_h = height; fb->shift_h = 0; fb->shift_w = 0; - int limit = ctx->plb_max_blk; + int limit = screen->plb_max_blk; while ((width * height) > limit) { if (width >= height) { width = (width + 1) >> 1; |