mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-20 05:10:11 +01:00
freedreno/a6xx: gen8 lrz support
Signed-off-by: Rob Clark <rob.clark@oss.qualcomm.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38930>
This commit is contained in:
parent
0e82a8d759
commit
a520752328
2 changed files with 12 additions and 7 deletions
|
|
@ -237,7 +237,7 @@ emit_lrz(fd_cs &cs, struct fd_batch *batch, struct fd_batch_subpass *subpass)
|
||||||
struct pipe_framebuffer_state *pfb = &batch->framebuffer;
|
struct pipe_framebuffer_state *pfb = &batch->framebuffer;
|
||||||
|
|
||||||
if (!subpass->lrz) {
|
if (!subpass->lrz) {
|
||||||
fd_crb crb(cs, 8);
|
fd_crb crb(cs, 9);
|
||||||
|
|
||||||
crb.add(GRAS_LRZ_BUFFER_BASE(CHIP));
|
crb.add(GRAS_LRZ_BUFFER_BASE(CHIP));
|
||||||
crb.add(GRAS_LRZ_BUFFER_PITCH(CHIP));
|
crb.add(GRAS_LRZ_BUFFER_PITCH(CHIP));
|
||||||
|
|
@ -249,6 +249,10 @@ emit_lrz(fd_cs &cs, struct fd_batch *batch, struct fd_batch_subpass *subpass)
|
||||||
crb.add(GRAS_LRZ_CNTL2(CHIP));
|
crb.add(GRAS_LRZ_CNTL2(CHIP));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (CHIP >= A8XX) {
|
||||||
|
crb.add(GRAS_LRZ_BUFFER_SLICE_PITCH(CHIP));
|
||||||
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -260,7 +264,7 @@ emit_lrz(fd_cs &cs, struct fd_batch *batch, struct fd_batch_subpass *subpass)
|
||||||
*/
|
*/
|
||||||
fd6_event_write<CHIP>(batch->ctx, cs, FD_LRZ_FLUSH);
|
fd6_event_write<CHIP>(batch->ctx, cs, FD_LRZ_FLUSH);
|
||||||
|
|
||||||
fd_crb crb(cs, 8);
|
fd_crb crb(cs, 9);
|
||||||
|
|
||||||
struct fd_resource *zsbuf = fd_resource(pfb->zsbuf.texture);
|
struct fd_resource *zsbuf = fd_resource(pfb->zsbuf.texture);
|
||||||
|
|
||||||
|
|
@ -290,6 +294,12 @@ emit_lrz(fd_cs &cs, struct fd_batch *batch, struct fd_batch_subpass *subpass)
|
||||||
.fc_enable = lrzfc_enabled<CHIP>(zsbuf),
|
.fc_enable = lrzfc_enabled<CHIP>(zsbuf),
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (CHIP >= A8XX) {
|
||||||
|
crb.add(GRAS_LRZ_BUFFER_SLICE_PITCH(CHIP,
|
||||||
|
zsbuf->lrz_layout.lrz_slice_pitch
|
||||||
|
));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Emit any needed lrz clears to the prologue cmds
|
/* Emit any needed lrz clears to the prologue cmds
|
||||||
|
|
|
||||||
|
|
@ -995,11 +995,6 @@ fd_screen_create(int fd,
|
||||||
screen->dev_info = info;
|
screen->dev_info = info;
|
||||||
screen->info = &screen->dev_info;
|
screen->info = &screen->dev_info;
|
||||||
|
|
||||||
if (screen->gen == 8) {
|
|
||||||
/* gen8 TODO */
|
|
||||||
fd_mesa_debug |= FD_DBG_NOLRZ;
|
|
||||||
}
|
|
||||||
|
|
||||||
switch (screen->gen) {
|
switch (screen->gen) {
|
||||||
case 2:
|
case 2:
|
||||||
fd2_screen_init(pscreen);
|
fd2_screen_init(pscreen);
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue