From f51b960af18f697a187fe2ed4918fb95495e5569 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Ol=C5=A1=C3=A1k?= Date: Thu, 23 Nov 2023 18:05:10 -0500 Subject: [PATCH] radeonsi/gfx11: fix unaligned SET_CONTEXT_PAIRS_PACKED It set an invalid register. Luckily it didn't cause any issues. Fixes: 2ac6816b70d7bb - radeonsi/gfx11: use SET_CONTEXT_REG_PAIRS_PACKED for other states Reviewed-by: Pierre-Eric Pelloux-Prayer Part-of: --- src/gallium/drivers/radeonsi/si_build_pm4.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/drivers/radeonsi/si_build_pm4.h b/src/gallium/drivers/radeonsi/si_build_pm4.h index 6ce53255cfe..24e79908070 100644 --- a/src/gallium/drivers/radeonsi/si_build_pm4.h +++ b/src/gallium/drivers/radeonsi/si_build_pm4.h @@ -339,7 +339,7 @@ if (__cs_context_reg_count >= 2) { \ /* Align the count to 2 by duplicating the first register. */ \ if (__cs_context_reg_count % 2 == 1) { \ - gfx11_set_context_reg(__cs_context_regs[0].reg_offset[0] + SI_CONTEXT_REG_OFFSET, \ + gfx11_set_context_reg(SI_CONTEXT_REG_OFFSET + __cs_context_regs[0].reg_offset[0] * 4, \ __cs_context_regs[0].reg_value[0]); \ } \ assert(__cs_context_reg_count % 2 == 0); \