aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/linux-yocto-4.14.71/1343-drm-amdkfd-Fix-debugfs-dumping-of-KFD-HQDs.patch
diff options
context:
space:
mode:
Diffstat (limited to 'common/recipes-kernel/linux/linux-yocto-4.14.71/1343-drm-amdkfd-Fix-debugfs-dumping-of-KFD-HQDs.patch')
-rw-r--r--common/recipes-kernel/linux/linux-yocto-4.14.71/1343-drm-amdkfd-Fix-debugfs-dumping-of-KFD-HQDs.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/common/recipes-kernel/linux/linux-yocto-4.14.71/1343-drm-amdkfd-Fix-debugfs-dumping-of-KFD-HQDs.patch b/common/recipes-kernel/linux/linux-yocto-4.14.71/1343-drm-amdkfd-Fix-debugfs-dumping-of-KFD-HQDs.patch
new file mode 100644
index 00000000..d46451c4
--- /dev/null
+++ b/common/recipes-kernel/linux/linux-yocto-4.14.71/1343-drm-amdkfd-Fix-debugfs-dumping-of-KFD-HQDs.patch
@@ -0,0 +1,35 @@
+From 3d9f7788600cdf7f6077066adb8c5513f6b4d5ec Mon Sep 17 00:00:00 2001
+From: Felix Kuehling <Felix.Kuehling@amd.com>
+Date: Wed, 15 Nov 2017 18:01:11 -0500
+Subject: [PATCH 1343/4131] drm/amdkfd: Fix debugfs dumping of KFD HQDs
+
+Use shared_resources.queue_bitmap to determine the queues available
+for KFD in each pipe.
+
+Change-Id: I621bcd1fe9baa55084c231ff9d9bee46f176fd5c
+Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
+---
+ drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c b/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c
+index 56fa027..3a09cbc 100644
+--- a/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c
++++ b/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c
+@@ -1737,7 +1737,13 @@ int device_queue_manager_debugfs_hqds(struct seq_file *m, void *data)
+ int r = 0;
+
+ for (pipe = 0; pipe < get_pipes_per_mec(dqm); pipe++) {
++ int pipe_offset = pipe * get_queues_per_pipe(dqm);
++
+ for (queue = 0; queue < get_queues_per_pipe(dqm); queue++) {
++ if (!test_bit(pipe_offset + queue,
++ dqm->dev->shared_resources.queue_bitmap))
++ continue;
++
+ r = dqm->dev->kfd2kgd->hqd_dump(
+ dqm->dev->kgd, pipe, queue, &dump, &n_regs);
+ if (r)
+--
+2.7.4
+