drm/amdkfd: Sign-extend TMA address in trap handler
authorJay Cornwall <jay.cornwall@amd.com>
Wed, 12 Jul 2023 20:51:47 +0000 (15:51 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 7 Aug 2023 21:14:06 +0000 (17:14 -0400)
commit05c899eacc0412bae0581add19c4062db8bdffda
treefd2af9bfda2c5dfecccdc7ba32d3529a1a63cfe2
parent96c211f1f9ef82183493f4ceed4e347b52849149
drm/amdkfd: Sign-extend TMA address in trap handler

SMEM instructions can reach addresses above 47 bits but require
bit 47 to be sign-extended through bits [63:48].

This allows the TMA to be relocated in a following patch.

Signed-off-by: Jay Cornwall <jay.cornwall@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdkfd/cwsr_trap_handler.h
drivers/gpu/drm/amd/amdkfd/cwsr_trap_handler_gfx10.asm
drivers/gpu/drm/amd/amdkfd/cwsr_trap_handler_gfx9.asm