| .. | .. |
|---|
| 1 | 1 | // SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note |
|---|
| 2 | 2 | /* |
|---|
| 3 | 3 | * |
|---|
| 4 | | - * (C) COPYRIGHT 2019-2021 ARM Limited. All rights reserved. |
|---|
| 4 | + * (C) COPYRIGHT 2019-2022 ARM Limited. All rights reserved. |
|---|
| 5 | 5 | * |
|---|
| 6 | 6 | * This program is free software and is provided to you under the terms of the |
|---|
| 7 | 7 | * GNU General Public License version 2 as published by the Free Software |
|---|
| .. | .. |
|---|
| 27 | 27 | #include <gpu/mali_kbase_gpu_regmap.h> |
|---|
| 28 | 28 | #include <mali_kbase.h> |
|---|
| 29 | 29 | #include <mali_kbase_ctx_sched.h> |
|---|
| 30 | | -#include <mali_kbase_dma_fence.h> |
|---|
| 31 | 30 | #include <mali_kbase_kinstr_jm.h> |
|---|
| 32 | 31 | #include <mali_kbase_mem_linux.h> |
|---|
| 33 | 32 | #include <mali_kbase_mem_pool_group.h> |
|---|
| .. | .. |
|---|
| 36 | 35 | |
|---|
| 37 | 36 | #if IS_ENABLED(CONFIG_DEBUG_FS) |
|---|
| 38 | 37 | #include <mali_kbase_debug_mem_view.h> |
|---|
| 38 | +#include <mali_kbase_debug_mem_zones.h> |
|---|
| 39 | +#include <mali_kbase_debug_mem_allocs.h> |
|---|
| 39 | 40 | #include <mali_kbase_mem_pool_debugfs.h> |
|---|
| 40 | 41 | |
|---|
| 41 | 42 | void kbase_context_debugfs_init(struct kbase_context *const kctx) |
|---|
| 42 | 43 | { |
|---|
| 43 | 44 | kbase_debug_mem_view_init(kctx); |
|---|
| 45 | + kbase_debug_mem_zones_init(kctx); |
|---|
| 46 | + kbase_debug_mem_allocs_init(kctx); |
|---|
| 44 | 47 | kbase_mem_pool_debugfs_init(kctx->kctx_dentry, kctx); |
|---|
| 45 | 48 | kbase_jit_debugfs_init(kctx); |
|---|
| 46 | 49 | kbasep_jd_debugfs_ctx_init(kctx); |
|---|
| .. | .. |
|---|
| 110 | 113 | flush_workqueue(kctx->jctx.job_done_wq); |
|---|
| 111 | 114 | } |
|---|
| 112 | 115 | |
|---|
| 116 | +/** |
|---|
| 117 | + * kbase_context_free - Free kcontext at its destruction |
|---|
| 118 | + * |
|---|
| 119 | + * @kctx: kcontext to be freed |
|---|
| 120 | + */ |
|---|
| 113 | 121 | static void kbase_context_free(struct kbase_context *kctx) |
|---|
| 114 | 122 | { |
|---|
| 115 | 123 | kbase_timeline_post_kbase_context_destroy(kctx); |
|---|
| .. | .. |
|---|
| 121 | 129 | { NULL, kbase_context_free, NULL }, |
|---|
| 122 | 130 | { kbase_context_common_init, kbase_context_common_term, |
|---|
| 123 | 131 | "Common context initialization failed" }, |
|---|
| 124 | | - { kbase_dma_fence_init, kbase_dma_fence_term, |
|---|
| 125 | | - "DMA fence initialization failed" }, |
|---|
| 126 | 132 | { kbase_context_mem_pool_group_init, kbase_context_mem_pool_group_term, |
|---|
| 127 | 133 | "Memory pool group initialization failed" }, |
|---|
| 128 | 134 | { kbase_mem_evictable_init, kbase_mem_evictable_deinit, |
|---|