mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 00:58:05 +02:00
asahi: Identify attachment length field
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11730>
This commit is contained in:
parent
b8bc5ed297
commit
4c99510d3b
2 changed files with 4 additions and 2 deletions
|
|
@ -473,7 +473,7 @@
|
|||
<field name="Total size" start="1:0" size="32" type="uint"/>
|
||||
<field name="Unk 2" start="2:0" size="32" default="0x7" type="hex"/>
|
||||
<field name="Attachment offset 1" start="8:0" size="32" type="uint"/>
|
||||
<field name="Unk 3" start="9:0" size="32" default="0x18" type="hex"/>
|
||||
<field name="Attachment length" start="9:0" size="32" type="uint"/>
|
||||
<field name="Attachment offset 2" start="10:0" size="32" type="uint"/>
|
||||
<field name="Unknown offset" start="11:0" size="32" type="uint"/>
|
||||
<field name="Unk 4" start="12:0" size="32" default="0x30" type="hex"/>
|
||||
|
|
|
|||
|
|
@ -202,10 +202,11 @@ demo_cmdbuf(uint64_t *buf, size_t size,
|
|||
EMIT_ZERO_WORDS(cmdbuf, 12);
|
||||
|
||||
unsigned offset_attachments = (cmdbuf->offset * 4);
|
||||
unsigned nr_attachments = 1;
|
||||
EMIT32(cmdbuf, 0); // 0x758
|
||||
EMIT32(cmdbuf, 0);
|
||||
EMIT32(cmdbuf, 0);
|
||||
EMIT32(cmdbuf, 0x1); // number of attachments (includes depth/stencil) stored to
|
||||
EMIT32(cmdbuf, nr_attachments);
|
||||
|
||||
/* A single attachment follows, depth/stencil have their own attachments */
|
||||
agx_pack((cmdbuf->map + cmdbuf->offset), IOGPU_ATTACHMENT, cfg) {
|
||||
|
|
@ -225,6 +226,7 @@ demo_cmdbuf(uint64_t *buf, size_t size,
|
|||
cfg.total_size = total_size;
|
||||
cfg.attachment_offset_1 = offset_attachments;
|
||||
cfg.attachment_offset_2 = offset_attachments;
|
||||
cfg.attachment_length = nr_attachments * AGX_IOGPU_ATTACHMENT_LENGTH;
|
||||
cfg.unknown_offset = offset_unk;
|
||||
cfg.encoder = encoder_ptr;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue