#define MAX_RENDER_TARGETS A6XX_MAX_RENDER_TARGETS
-#define FD_DBG_MSGS 0x0001
-#define FD_DBG_DISASM 0x0002
-#define FD_DBG_DCLEAR 0x0004
-#define FD_DBG_DDRAW 0x0008
-#define FD_DBG_NOSCIS 0x0010
-#define FD_DBG_DIRECT 0x0020
-#define FD_DBG_NOBYPASS 0x0040
-#define FD_DBG_FRAGHALF 0x0080
-#define FD_DBG_NOBIN 0x0100
-#define FD_DBG_NOGMEM 0x0200
-#define FD_DBG_GLSL120 0x0400
-#define FD_DBG_SHADERDB 0x0800
-#define FD_DBG_FLUSH 0x1000
-#define FD_DBG_DEQP 0x2000
-#define FD_DBG_INORDER 0x4000
-#define FD_DBG_BSTAT 0x8000
-#define FD_DBG_NOGROW 0x10000
-#define FD_DBG_LRZ 0x20000
-#define FD_DBG_NOINDR 0x40000
-#define FD_DBG_NOBLIT 0x80000
-#define FD_DBG_HIPRIO 0x100000
-#define FD_DBG_TTILE 0x200000
-#define FD_DBG_PERFC 0x400000
-#define FD_DBG_NOUBWC 0x800000
-#define FD_DBG_NOLRZ 0x1000000
+enum fd_debug_flag {
+ FD_DBG_MSGS = BITFIELD_BIT(0),
+ FD_DBG_DISASM = BITFIELD_BIT(1),
+ FD_DBG_DCLEAR = BITFIELD_BIT(2),
+ FD_DBG_DDRAW = BITFIELD_BIT(3),
+ FD_DBG_NOSCIS = BITFIELD_BIT(4),
+ FD_DBG_DIRECT = BITFIELD_BIT(5),
+ FD_DBG_NOBYPASS = BITFIELD_BIT(6),
+ FD_DBG_FRAGHALF = BITFIELD_BIT(7),
+ FD_DBG_NOBIN = BITFIELD_BIT(8),
+ FD_DBG_NOGMEM = BITFIELD_BIT(9),
+ FD_DBG_GLSL120 = BITFIELD_BIT(10),
+ FD_DBG_SHADERDB = BITFIELD_BIT(11),
+ FD_DBG_FLUSH = BITFIELD_BIT(12),
+ FD_DBG_DEQP = BITFIELD_BIT(13),
+ FD_DBG_INORDER = BITFIELD_BIT(14),
+ FD_DBG_BSTAT = BITFIELD_BIT(15),
+ FD_DBG_NOGROW = BITFIELD_BIT(16),
+ FD_DBG_LRZ = BITFIELD_BIT(17),
+ FD_DBG_NOINDR = BITFIELD_BIT(18),
+ FD_DBG_NOBLIT = BITFIELD_BIT(19),
+ FD_DBG_HIPRIO = BITFIELD_BIT(20),
+ FD_DBG_TTILE = BITFIELD_BIT(21),
+ FD_DBG_PERFC = BITFIELD_BIT(22),
+ FD_DBG_NOUBWC = BITFIELD_BIT(23),
+ FD_DBG_NOLRZ = BITFIELD_BIT(24),
+ FD_DBG_NOTILE = BITFIELD_BIT(25),
+};
+
extern int fd_mesa_debug;
extern bool fd_binning_enabled;