diff options
author | Sidath Senanayake <sidaths@google.com> | 2017-05-18 14:43:17 +0200 |
---|---|---|
committer | Sidath Senanayake <sidaths@google.com> | 2017-05-18 14:43:17 +0200 |
commit | 6f5ab3baed824941f168ab133469f997d4450146 (patch) | |
tree | 95dcbadaa979f84a8d75c0919af1b85c5afd1924 /mali_kbase/mali_kbase_jd_debugfs.c | |
parent | 48f3554a4abf9ce182253fb5415a1a26b0790998 (diff) | |
download | gpu-6f5ab3baed824941f168ab133469f997d4450146.tar.gz |
Mali Bifrost DDK r6p0 KMD
Provenance:
b67d8663a (collaborate/EAC/b_r6p0)
BX304L01B-BU-00000-r6p0-01rel0
BX304L06A-BU-00000-r6p0-01rel0
BX304X07X-BU-00000-r6p0-01rel0
Signed-off-by: Sidath Senanayake <sidaths@google.com>
Change-Id: I6b19113374d523be9a75a252d672731600e991d6
Diffstat (limited to 'mali_kbase/mali_kbase_jd_debugfs.c')
-rw-r--r-- | mali_kbase/mali_kbase_jd_debugfs.c | 63 |
1 files changed, 31 insertions, 32 deletions
diff --git a/mali_kbase/mali_kbase_jd_debugfs.c b/mali_kbase/mali_kbase_jd_debugfs.c index 47ea426..c8b37c4 100644 --- a/mali_kbase/mali_kbase_jd_debugfs.c +++ b/mali_kbase/mali_kbase_jd_debugfs.c @@ -1,6 +1,6 @@ /* * - * (C) COPYRIGHT 2014-2016 ARM Limited. All rights reserved. + * (C) COPYRIGHT 2014-2017 ARM Limited. All rights reserved. * * This program is free software and is provided to you under the terms of the * GNU General Public License version 2 as published by the Free Software @@ -15,63 +15,58 @@ -#include <linux/seq_file.h> +#ifdef CONFIG_DEBUG_FS +#include <linux/seq_file.h> #include <mali_kbase.h> - #include <mali_kbase_jd_debugfs.h> #include <mali_kbase_dma_fence.h> - -#ifdef CONFIG_DEBUG_FS +#if defined(CONFIG_SYNC) || defined(CONFIG_SYNC_FILE) +#include <mali_kbase_sync.h> +#endif struct kbase_jd_debugfs_depinfo { u8 id; char type; }; -#ifdef CONFIG_SYNC -#include <mali_kbase_sync.h> -#include "sync.h" -#endif /* CONFIG_SYNC */ - - static void kbase_jd_debugfs_fence_info(struct kbase_jd_atom *atom, struct seq_file *sfile) { -#ifdef CONFIG_SYNC - struct sync_fence *fence = atom->fence; - int status; +#if defined(CONFIG_SYNC) || defined(CONFIG_SYNC_FILE) + struct kbase_sync_fence_info info; + int res; switch (atom->core_req & BASE_JD_REQ_SOFT_JOB_TYPE) { case BASE_JD_REQ_SOFT_FENCE_TRIGGER: - if (!fence) + res = kbase_sync_fence_out_info_get(atom, &info); + if (0 == res) { + seq_printf(sfile, "Sa([%p]%d) ", + info.fence, info.status); break; - - status = kbase_fence_get_status(fence); - - seq_printf(sfile, "Sa([%p]%d) ", - fence, status); - break; + } case BASE_JD_REQ_SOFT_FENCE_WAIT: - if (!fence) + res = kbase_sync_fence_in_info_get(atom, &info); + if (0 == res) { + seq_printf(sfile, "Wa([%p]%d) ", + info.fence, info.status); break; - - status = kbase_fence_get_status(fence); - - seq_printf(sfile, "Wa([%p]%d) ", - fence, status); - break; + } default: break; } -#endif /* CONFIG_SYNC */ +#endif /* CONFIG_SYNC || CONFIG_SYNC_FILE */ #ifdef CONFIG_MALI_DMA_FENCE if (atom->core_req & BASE_JD_REQ_EXTERNAL_RESOURCES) { - struct kbase_dma_fence_cb *cb; + struct kbase_fence_cb *cb; if (atom->dma_fence.fence) { +#if (LINUX_VERSION_CODE < KERNEL_VERSION(4, 10, 0)) struct fence *fence = atom->dma_fence.fence; +#else + struct dma_fence *fence = atom->dma_fence.fence; +#endif seq_printf(sfile, #if (LINUX_VERSION_CODE < KERNEL_VERSION(4, 8, 0)) @@ -81,13 +76,17 @@ static void kbase_jd_debugfs_fence_info(struct kbase_jd_atom *atom, #endif fence->context, fence->seqno, - fence_is_signaled(fence) ? + dma_fence_is_signaled(fence) ? "signaled" : "active"); } list_for_each_entry(cb, &atom->dma_fence.callbacks, node) { +#if (LINUX_VERSION_CODE < KERNEL_VERSION(4, 10, 0)) struct fence *fence = cb->fence; +#else + struct dma_fence *fence = cb->fence; +#endif seq_printf(sfile, #if (LINUX_VERSION_CODE < KERNEL_VERSION(4, 8, 0)) @@ -97,7 +96,7 @@ static void kbase_jd_debugfs_fence_info(struct kbase_jd_atom *atom, #endif fence->context, fence->seqno, - fence_is_signaled(fence) ? + dma_fence_is_signaled(fence) ? "signaled" : "active"); } } |