Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2018-08-03 14:21:47 +0200
committerTakashi Iwai <tiwai@suse.de>2018-08-03 14:22:23 +0200
commit7cea46b99136faafa52b841759e59adbf4c6ea25 (patch)
tree65e4c58d6c07d31ece32a009fe873ec1ae53553b
parenta514876d058f3caea5ff1432ae0cec95b568ee1f (diff)
drm/nouveau/fifo/gk104-: poll for runlist update completion
(bsc#1051510).
-rw-r--r--patches.drivers/drm-nouveau-fifo-gk104-poll-for-runlist-update-compl43
-rw-r--r--series.conf1
2 files changed, 44 insertions, 0 deletions
diff --git a/patches.drivers/drm-nouveau-fifo-gk104-poll-for-runlist-update-compl b/patches.drivers/drm-nouveau-fifo-gk104-poll-for-runlist-update-compl
new file mode 100644
index 0000000000..16b5976640
--- /dev/null
+++ b/patches.drivers/drm-nouveau-fifo-gk104-poll-for-runlist-update-compl
@@ -0,0 +1,43 @@
+From 4f2fc25c0f8bcc8db1b8a7b21e88c3d7f35c5acb Mon Sep 17 00:00:00 2001
+From: Ben Skeggs <bskeggs@redhat.com>
+Date: Tue, 8 May 2018 20:39:46 +1000
+Subject: [PATCH] drm/nouveau/fifo/gk104-: poll for runlist update completion
+Git-commit: 4f2fc25c0f8bcc8db1b8a7b21e88c3d7f35c5acb
+Patch-mainline: v4.18-rc1
+References: bsc#1051510
+
+Newer HW doesn't appear to send this event, which will cause long delays
+in runlist updates if they don't complete immediately.
+
+RM doesn't use these events anywhere, and an NVGPU commit message notes
+that polling is the preferred method even on HW that supports the event.
+
+Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
+Acked-by: Takashi Iwai <tiwai@suse.de>
+
+---
+ drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c b/drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c
+index afb3ed06ec89..2b8e0d3d2d96 100644
+--- a/drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c
++++ b/drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c
+@@ -170,10 +170,10 @@ gk104_fifo_runlist_commit(struct gk104_fifo *fifo, int runl)
+ (target << 28));
+ nvkm_wr32(device, 0x002274, (runl << 20) | nr);
+
+- if (wait_event_timeout(fifo->runlist[runl].wait,
+- !(nvkm_rd32(device, 0x002284 + (runl * 0x08))
+- & 0x00100000),
+- msecs_to_jiffies(2000)) == 0)
++ if (nvkm_msec(device, 2000,
++ if (!(nvkm_rd32(device, 0x002284 + (runl * 0x08)) & 0x00100000))
++ break;
++ ) < 0)
+ nvkm_error(subdev, "runlist %d update timeout\n", runl);
+ unlock:
+ mutex_unlock(&subdev->mutex);
+--
+2.18.0
+
diff --git a/series.conf b/series.conf
index 317ca2d731..5c6212885b 100644
--- a/series.conf
+++ b/series.conf
@@ -14656,6 +14656,7 @@
patches.drivers/drm-amdgpu-Add-APU-support-in-vi_set_vce_clocks
patches.drivers/drm-amdgpu-Remove-VRAM-from-shared-bo-domains
patches.drivers/drm-radeon-fix-mode_valid-s-return-type
+ patches.drivers/drm-nouveau-fifo-gk104-poll-for-runlist-update-compl
patches.drivers/0001-drm-tegra-Acquire-a-reference-to-the-IOVA-cache.patch
patches.drivers/0001-gpu-host1x-Acquire-a-reference-to-the-IOVA-cache.patch
patches.drivers/drm-exynos-dsi-mask-frame-done-interrupt