Skip to content

Commit 51a96a2

Browse files
committed
drm/asahi: render: Fix meta1_blocks calculation for MSAA
Block count needs to be computed with an extra factor of the sample count. Signed-off-by: Asahi Lina <[email protected]>
1 parent 185978b commit 51a96a2

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

drivers/gpu/drm/asahi/hw/t600x.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ pub(crate) const HWCONFIG_T6002: super::HwConfig = HwConfig {
6262
preempt3_size: 0x20,
6363
clustering: Some(HwClusteringConfig {
6464
meta1_blocksize: 0x44,
65-
meta2_size: 0x190 * 8, // CHECK
65+
meta2_size: 0xc0 * 8,
6666
meta3_size: 0x280 * 8,
6767
meta4_size: 0x30 * 16,
6868
max_splits: 16,

drivers/gpu/drm/asahi/queue/render.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ impl super::Queue::ver {
136136
// No idea where this comes from, but it fits what macOS does...
137137
// TODO: layers?
138138
let meta1_blocks = if num_clusters > 1 {
139-
div_ceil(align(tiles_x, 2) * align(tiles_y, 4), 0x1980)
139+
div_ceil(align(tiles_x, 2) * align(tiles_y, 4) * cmdbuf.samples, 0x1980)
140140
} else {
141141
0
142142
};

0 commit comments

Comments
 (0)