mirror of
https://github.com/elwrcl/intel-hard-graphics.git
synced 2026-10-31 10:58:03 +03:00
hasvk: Account for frames wider than 128 MBs on gen7.
Fixes corruption and GPU hangs observed with a 4096 wide video. Assisted-by: Claude
This commit is contained in:
1 parent
bd3d4fc732
commit
fac6387b34
1 file changed
+4
-2
@@ -709,8 +709,10 @@ add_video_buffers(struct anv_device *device,
|
||||
* or 8192 bytes per MB row (128 MBs * 64 bytes).
|
||||
*/
|
||||
if (device->info->ver == 7) {
|
||||
/* 128 MBs/row * h_mb rows * 64 bytes/MB = h_mb * 8192 */
|
||||
size = h_mb * 8192;
|
||||
/* However for frames wider than 128 MBs we need to make sure we
|
||||
* don't overrun and silently corrupt the buffer.
|
||||
*/
|
||||
size = h_mb * MAX2(w_mb, 128u) * 64;
|
||||
} else {
|
||||
/* XXX: Is this correct for Broadwell? */
|
||||
size = w_mb * h_mb * 128;
|
||||
|
||||
Reference in new issue
Block a user