summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau/nouveau_fence.h
diff options
context:
space:
mode:
authorDanilo Krummrich <dakr@redhat.com>2023-08-04 20:23:48 +0200
committerDanilo Krummrich <dakr@redhat.com>2023-08-04 20:34:37 +0200
commitf124eef76f855d9f3df8827cb1e166f96994042c (patch)
treeb20774843f812b756f9e57a2598a35127fa6f55f /drivers/gpu/drm/nouveau/nouveau_fence.h
parent7f2a0b50b2b20308a19602b51c647566c62e144c (diff)
downloadlinux-stable-f124eef76f855d9f3df8827cb1e166f96994042c.tar.gz
linux-stable-f124eef76f855d9f3df8827cb1e166f96994042c.tar.bz2
linux-stable-f124eef76f855d9f3df8827cb1e166f96994042c.zip
drm/nouveau: fence: fail to emit when fence context is killed
The new VM_BIND UAPI implementation introduced in subsequent commits will allow asynchronous jobs processing push buffers and emitting fences. If a fence context is killed, e.g. due to a channel fault, jobs which are already queued for execution might still emit new fences. In such a case a job would hang forever. To fix that, fail to emit a new fence on a killed fence context with -ENODEV to unblock the job. Reviewed-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Danilo Krummrich <dakr@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230804182406.5222-9-dakr@redhat.com
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_fence.h')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_fence.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_fence.h b/drivers/gpu/drm/nouveau/nouveau_fence.h
index 7c73c7c9834a..2c72d96ef17d 100644
--- a/drivers/gpu/drm/nouveau/nouveau_fence.h
+++ b/drivers/gpu/drm/nouveau/nouveau_fence.h
@@ -44,7 +44,7 @@ struct nouveau_fence_chan {
char name[32];
struct nvif_event event;
- int notify_ref, dead;
+ int notify_ref, dead, killed;
};
struct nouveau_fence_priv {