drm/amdkfd: Clear MODE.VSKIP in gfx9 trap handler

If user shader issues S_SETVSKIP then this state will persist when
executing the trap handler, causing vector instructions to be
skipped.

VSKIP state is already saved/restored through the MODE register.

Signed-off-by: Jay Cornwall <jay.cornwall@amd.com>
Reviewed-by: Lancelot Six <lancelot.six@amd.com>
Suggested-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Jay Cornwall 2025-01-07 21:59:06 -06:00 committed by Alex Deucher
parent a0db1ea0dd
commit 1241b64d4b
2 changed files with 1366 additions and 1359 deletions

File diff suppressed because it is too large Load Diff

View File

@ -447,7 +447,9 @@ L_SAVE:
s_getreg_b32 s_save_m0, hwreg(HW_REG_MODE) //MODE
write_hwreg_to_mem(s_save_m0, s_save_buf_rsrc0, s_save_mem_offset)
// Clear VSKIP state now that MODE.VSKIP has been saved.
// If user shader set it then vector instructions would be skipped.
s_setvskip 0,0
/* the first wave in the threadgroup */
s_and_b32 s_save_tmp, s_save_spi_init_hi, S_SAVE_SPI_INIT_FIRST_WAVE_MASK // extract fisrt wave bit