OSDN Git Service

drm/amdkfd: Separate trap handler assembly code and its hex values
authorYong Zhao <yong.zhao@amd.com>
Tue, 1 May 2018 21:56:06 +0000 (17:56 -0400)
committerOded Gabbay <oded.gabbay@gmail.com>
Tue, 1 May 2018 21:56:06 +0000 (17:56 -0400)
commit0db54b24ad676c3f2d0cf5291c9d170e3e15f213
treecb3b3c7bdcc10a86fc7375a20628e220ce9926bb
parenta2e94158b83185c9dac430cb53bff26737a786ef
drm/amdkfd: Separate trap handler assembly code and its hex values

Since the assembly code is inside "#if 0", it is ineffective. Despite that,
during debugging, we need to change the assembly code, extract it into
a separate file and compile the new file into hex values using sp3.
That process also requires us to remove "#if 0" and modify lines starting
with "#", so that sp3 can successfully compile the new file.

With this change, all the above chore is no longer needed, and
cwsr_trap_handler_gfx*.asm can be directly used by sp3 to generate its
hex values.

Signed-off-by: Yong Zhao <yong.zhao@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
drivers/gpu/drm/amd/amdkfd/cwsr_trap_handler.h [new file with mode: 0644]
drivers/gpu/drm/amd/amdkfd/cwsr_trap_handler_gfx8.asm
drivers/gpu/drm/amd/amdkfd/cwsr_trap_handler_gfx9.asm
drivers/gpu/drm/amd/amdkfd/kfd_device.c