mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-27 14:50:10 +01:00
etnaviv: rs: fix MSAA alignment adjustment
The RS window alignment restrictions apply to the downsampled side of the blit, so we must increase the blit size alignment by the MSAA scale to avoid RS hangs. If a multi-pipe resolve is used (when the GPU doesn't have the singlebuffer feature) then the Y alignment needs to be increased by the number of pixel pipes. The resource allocation has already been fixed to take this additional alignment requirement into account. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19066>
This commit is contained in:
parent
6dfae66016
commit
0ff96aaef3
1 changed files with 5 additions and 2 deletions
|
|
@ -686,8 +686,11 @@ etna_try_rs_blit(struct pipe_context *pctx,
|
|||
* Note: the RS width/height are converted to source samples here. */
|
||||
unsigned int width = blit_info->src.box.width * msaa_xscale;
|
||||
unsigned int height = blit_info->src.box.height * msaa_yscale;
|
||||
unsigned int w_align = ETNA_RS_WIDTH_MASK + 1;
|
||||
unsigned int h_align = ETNA_RS_HEIGHT_MASK + 1;
|
||||
unsigned int w_align = (ETNA_RS_WIDTH_MASK + 1) * msaa_xscale;
|
||||
unsigned int h_align = (ETNA_RS_HEIGHT_MASK + 1) * msaa_yscale;
|
||||
|
||||
if (!ctx->screen->specs.single_buffer)
|
||||
h_align *= ctx->screen->specs.pixel_pipes;
|
||||
|
||||
if (width & (w_align - 1) && width >= src_lev->width * msaa_xscale && width >= dst_lev->width)
|
||||
width = align(width, w_align);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue