intel/dev: improve descriptions of workaround macros.

Instructions for INTEL_WA_{num}_GFX_VER macros were confusing and
contradicted itself.

Acked-by: Caio Oliveira <caio.oliveira@intel.com>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Acked-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26898>
This commit is contained in:
Mark Janes 2024-01-04 14:59:36 -08:00 committed by Marge Bot
parent d6c258d9ee
commit 7354d3a947

View file

@ -77,18 +77,20 @@ enum intel_workaround_id {
INTEL_WA_NUM
};
/* These defines are used to identify when a workaround potentially applies
* in genxml code. They should not be used directly. intel_needs_workaround()
* checks these definitions to eliminate bitset tests at compile time.
/* These defines apply workarounds to a subset of platforms within a graphics
* generation. They must be used in conjunction with intel_needs_workaround()
* to check platform details. Use these macros to compile out genxml code on
* generations where it can never execute. Whenever possible, prefer use of
* INTEL_NEEDS_WA_{num} instead of INTEL_WA_{num}_GFX_VER
*/
% for a in wa_def:
#define INTEL_WA_${a}_GFX_VER ${wa_macro[a]}
% endfor
/* These defines are suitable for use to compile out genxml code using #if
* guards. Workarounds that apply to part of a generation must use a
* combination of run time checks and INTEL_WA_{NUM}_GFX_VER macros. Those
* workarounds are 'poisoned' below.
/* These defines may be used to compile out genxml workaround implementations
* using #if guards. If a definition has been 'poisoned' below, then it applies to a
* subset of a graphics generation. In that case, use INTEL_WA_{NUM}_GFX_VER macros
* in conjunction with calls to intel_needs_workaround().
*/
% for a in partial_gens:
% if partial_gens[a]: