xref: /OK3568_Linux_fs/kernel/drivers/gpu/arm/bifrost/hwcnt/backend/mali_kbase_hwcnt_backend_csf_if_fw.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1 /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
2 /*
3  *
4  * (C) COPYRIGHT 2021-2022 ARM Limited. All rights reserved.
5  *
6  * This program is free software and is provided to you under the terms of the
7  * GNU General Public License version 2 as published by the Free Software
8  * Foundation, and any use by you of this program is subject to the terms
9  * of such GNU license.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, you can access it online at
18  * http://www.gnu.org/licenses/gpl-2.0.html.
19  *
20  */
21 
22 /*
23  * Concrete implementation of kbase_hwcnt_backend_csf_if interface for CSF FW
24  */
25 
26 #ifndef _KBASE_HWCNT_BACKEND_CSF_IF_FW_H_
27 #define _KBASE_HWCNT_BACKEND_CSF_IF_FW_H_
28 
29 #include "hwcnt/backend/mali_kbase_hwcnt_backend_csf_if.h"
30 
31 /**
32  * kbase_hwcnt_backend_csf_if_fw_create() - Create a firmware CSF interface
33  *                                          of hardware counter backend.
34  * @kbdev: Non-NULL pointer to Kbase device.
35  * @if_fw: Non-NULL pointer to backend interface structure that is filled in on
36  *         creation success.
37  * Return: 0 on success, else error code.
38  */
39 int kbase_hwcnt_backend_csf_if_fw_create(struct kbase_device *kbdev,
40 					 struct kbase_hwcnt_backend_csf_if *if_fw);
41 
42 /**
43  * kbase_hwcnt_backend_csf_if_fw_destroy() - Destroy a firmware CSF interface of
44  *                                           hardware counter backend.
45  * @if_fw: Pointer to a CSF interface to destroy.
46  */
47 void kbase_hwcnt_backend_csf_if_fw_destroy(struct kbase_hwcnt_backend_csf_if *if_fw);
48 
49 #endif /* _KBASE_HWCNT_BACKEND_CSF_IF_FW_H_ */
50