panfrost: Add a debug flag to disable AFBC
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7076>
This commit is contained in:
@@ -65,6 +65,7 @@ static const struct debug_named_value debug_options[] = {
|
|||||||
{"nofp16", PAN_DBG_NOFP16, "Disable 16-bit support"},
|
{"nofp16", PAN_DBG_NOFP16, "Disable 16-bit support"},
|
||||||
{"bifrost", PAN_DBG_BIFROST, "Enable experimental Mali G31 and G52 support"},
|
{"bifrost", PAN_DBG_BIFROST, "Enable experimental Mali G31 and G52 support"},
|
||||||
{"gl3", PAN_DBG_GL3, "Enable experimental GL 3.x implementation, up to 3.3"},
|
{"gl3", PAN_DBG_GL3, "Enable experimental GL 3.x implementation, up to 3.3"},
|
||||||
|
{"noafbc", PAN_DBG_NO_AFBC, "Disable AFBC support"},
|
||||||
DEBUG_NAMED_VALUE_END
|
DEBUG_NAMED_VALUE_END
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -695,6 +696,9 @@ panfrost_create_screen(int fd, struct renderonly *ro)
|
|||||||
|
|
||||||
dev->debug = debug_get_flags_option("PAN_MESA_DEBUG", debug_options, 0);
|
dev->debug = debug_get_flags_option("PAN_MESA_DEBUG", debug_options, 0);
|
||||||
|
|
||||||
|
if (dev->debug & PAN_DBG_NO_AFBC)
|
||||||
|
dev->quirks |= MIDGARD_NO_AFBC;
|
||||||
|
|
||||||
if (ro) {
|
if (ro) {
|
||||||
dev->ro = renderonly_dup(ro);
|
dev->ro = renderonly_dup(ro);
|
||||||
if (!dev->ro) {
|
if (!dev->ro) {
|
||||||
|
@@ -37,5 +37,6 @@
|
|||||||
#define PAN_DBG_NOFP16 0x0040
|
#define PAN_DBG_NOFP16 0x0040
|
||||||
#define PAN_DBG_BIFROST 0x0080
|
#define PAN_DBG_BIFROST 0x0080
|
||||||
#define PAN_DBG_GL3 0x0100
|
#define PAN_DBG_GL3 0x0100
|
||||||
|
#define PAN_DBG_NO_AFBC 0x0200
|
||||||
|
|
||||||
#endif /* PAN_UTIL_H */
|
#endif /* PAN_UTIL_H */
|
||||||
|
Reference in New Issue
Block a user