mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-02 22:30:11 +01:00
i965/miptree: Fix can_blit_slice()
Check the destination's row pitch against the BLT engine's row pitch limitation as well. Fixes:0288fe8d04("i965/miptree: Use the correct BLT pitch") v2: Fix the Fixes tag (Dylan). Check the destination row pitch (Chris). Reported-by: Dylan Baker <dylan@pnwbakers.com> Cc: <mesa-stable@lists.freedesktop.org> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> (cherry picked from commitb041fc0649)
This commit is contained in:
parent
dae1fc89a4
commit
627b874516
1 changed files with 3 additions and 4 deletions
|
|
@ -3545,10 +3545,9 @@ can_blit_slice(struct intel_mipmap_tree *mt,
|
|||
const struct intel_miptree_map *map)
|
||||
{
|
||||
/* See intel_miptree_blit() for details on the 32k pitch limit. */
|
||||
if (intel_miptree_blt_pitch(mt) >= 32768)
|
||||
return false;
|
||||
|
||||
return true;
|
||||
const unsigned src_blt_pitch = intel_miptree_blt_pitch(mt);
|
||||
const unsigned dst_blt_pitch = ALIGN(map->w * mt->cpp, 64);
|
||||
return src_blt_pitch < 32768 && dst_blt_pitch < 32768;
|
||||
}
|
||||
|
||||
static bool
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue