Skip to content
Snippets Groups Projects
Commit d331e4ed authored by Alyssa Rosenzweig's avatar Alyssa Rosenzweig Committed by Dylan Baker
Browse files

panfrost: Inline pan_fbd_has_zs_crc_ext


It has a single user -- in a section of code that only runs for MFBD GPUs and
that has already decided whether to use CRCs -- so inlining it simplifies its
definition greatly and may avoid redeciding the CRC setting.

[Note for mesa-stable maintainers: This is not a bug fix but is marked for
backport so the next patch applies cleanly.]

Signed-off-by: default avatarAlyssa Rosenzweig <alyssa@collabora.com>
Cc: mesa-stable
Part-of: <mesa/mesa!16983>
(cherry picked from commit cac0578e)
parent e4da9d82
No related branches found
No related tags found
Loading
......@@ -175,7 +175,7 @@
"description": "panfrost: Inline pan_fbd_has_zs_crc_ext",
"nominated": true,
"nomination_type": 0,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": null
},
......
......@@ -637,7 +637,7 @@ GENX(pan_emit_fbd)(const struct panfrost_device *dev,
unsigned tile_size;
unsigned internal_cbuf_size = pan_internal_cbuf_size(fb, &tile_size);
int crc_rt = GENX(pan_select_crc_rt)(fb);
bool has_zs_crc_ext = pan_fbd_has_zs_crc_ext(fb);
bool has_zs_crc_ext = (fb->zs.view.zs || fb->zs.view.s || crc_rt >= 0);
pan_section_pack(fbd, FRAMEBUFFER, PARAMETERS, cfg) {
#if PAN_ARCH >= 6
......
......@@ -151,14 +151,6 @@ GENX(pan_emit_tls)(const struct pan_tls_info *info,
int
GENX(pan_select_crc_rt)(const struct pan_fb_info *fb);
static inline bool
pan_fbd_has_zs_crc_ext(const struct pan_fb_info *fb)
{
return PAN_ARCH >= 5 &&
(fb->zs.view.zs || fb->zs.view.s ||
GENX(pan_select_crc_rt)(fb) >= 0);
}
unsigned
GENX(pan_emit_fbd)(const struct panfrost_device *dev,
const struct pan_fb_info *fb,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment