diff options
author | Moses Reuben <moses.reuben@amd.com> | 2018-07-12 04:32:48 +0200 |
---|---|---|
committer | Oded Gabbay <oded.gabbay@gmail.com> | 2018-07-12 04:32:48 +0200 |
commit | 101fee63cbb0a3df9e54aaafbfad0ab5821a34e6 (patch) | |
tree | e603449b08fb82d2244f3c4c06ada1f1f47b6120 /drivers/gpu/drm/amd/amdkfd/kfd_events.c | |
parent | drm/amdkfd: Fix error codes in kfd_get_process (diff) | |
download | linux-101fee63cbb0a3df9e54aaafbfad0ab5821a34e6.tar.xz linux-101fee63cbb0a3df9e54aaafbfad0ab5821a34e6.zip |
drm/amdkfd: send SIGSEGV to process upon KFD_EVENT_TYPE_MEMORY
Signed-off-by: Moses Reuben <moses.reuben@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Acked-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdkfd/kfd_events.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdkfd/kfd_events.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_events.c b/drivers/gpu/drm/amd/amdkfd/kfd_events.c index 5562e94e786a..3d5a8332e8c0 100644 --- a/drivers/gpu/drm/amd/amdkfd/kfd_events.c +++ b/drivers/gpu/drm/amd/amdkfd/kfd_events.c @@ -850,6 +850,13 @@ static void lookup_events_by_type_and_signal(struct kfd_process *p, ev->memory_exception_data = *ev_data; } + if (type == KFD_EVENT_TYPE_MEMORY) { + dev_warn(kfd_device, + "Sending SIGSEGV to HSA Process with PID %d ", + p->lead_thread->pid); + send_sig(SIGSEGV, p->lead_thread, 0); + } + /* Send SIGTERM no event of type "type" has been found*/ if (send_signal) { if (send_sigterm) { |