diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2019-10-13 06:35:26 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2019-10-13 06:35:26 +0000 |
commit | 0e199fc8ccefabf20659e6b4e88d70a76496aaec (patch) | |
tree | 6d32275e1bc2b7b6fe974ef5d21216be109e4b9d | |
parent | 6873b4d43002b1539aaa097bd2ca3a7b75a2ff50 (diff) |
drm/amdgpu: Fix KFD-related kernel oops on Hawaii
From Felix Kuehling
e0af3b19ad77b4a2c53ef05c1c11e2f58462d59c in linux 4.19.y/4.19.79
dcafbd50f2e4d5cc964aae409fb5691b743fba23 in mainline linux
-rw-r--r-- | sys/dev/pci/drm/amd/amdgpu/amdgpu_ib.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/pci/drm/amd/amdgpu/amdgpu_ib.c b/sys/dev/pci/drm/amd/amdgpu/amdgpu_ib.c index 51b5e977ca8..f4e9d1b10e3 100644 --- a/sys/dev/pci/drm/amd/amdgpu/amdgpu_ib.c +++ b/sys/dev/pci/drm/amd/amdgpu/amdgpu_ib.c @@ -139,7 +139,8 @@ int amdgpu_ib_schedule(struct amdgpu_ring *ring, unsigned num_ibs, /* ring tests don't use a job */ if (job) { vm = job->vm; - fence_ctx = job->base.s_fence->scheduled.context; + fence_ctx = job->base.s_fence ? + job->base.s_fence->scheduled.context : 0; } else { vm = NULL; fence_ctx = 0; |