rk: ion: resolve build err
[firefly-linux-kernel-4.4.55.git] / drivers / gpu / arm / t6xx / kbase / src / common / mali_kbase_pm_ca_fixed.c
1 /*
2  *
3  * (C) COPYRIGHT ARM Limited. All rights reserved.
4  *
5  * This program is free software and is provided to you under the terms of the
6  * GNU General Public License version 2 as published by the Free Software
7  * Foundation, and any use by you of this program is subject to the terms
8  * of such GNU licence.
9  *
10  * A copy of the licence is included with the program, and can also be obtained
11  * from Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
12  * Boston, MA  02110-1301, USA.
13  *
14  */
15
16
17
18 /**
19  * @file mali_kbase_pm_ca_fixed.c
20  * A power policy implementing fixed core availability
21  */
22
23 #include <kbase/src/common/mali_kbase.h>
24 #include <kbase/src/common/mali_kbase_pm.h>
25
26 static void fixed_init(struct kbase_device *kbdev)
27 {
28         kbdev->pm.ca_in_transition = MALI_FALSE;
29 }
30
31 static void fixed_term(struct kbase_device *kbdev)
32 {
33         CSTD_UNUSED(kbdev);
34 }
35
36 static u64 fixed_get_core_mask(struct kbase_device *kbdev)
37 {
38         return kbdev->shader_present_bitmap;
39 }
40
41 static void fixed_update_core_status (struct kbase_device *kbdev, u64 cores_ready, u64 cores_transitioning)
42 {
43         CSTD_UNUSED(kbdev);
44         CSTD_UNUSED(cores_ready);
45         CSTD_UNUSED(cores_transitioning);
46 }
47
48 /** The @ref kbase_pm_policy structure for the fixed power policy.
49  *
50  * This is the static structure that defines the fixed power policy's callback and name.
51  */
52 const kbase_pm_ca_policy kbase_pm_ca_fixed_policy_ops = {
53         "fixed",                        /* name */
54         fixed_init,                     /* init */
55         fixed_term,                     /* term */
56         fixed_get_core_mask,            /* get_core_mask */
57         fixed_update_core_status,       /* update_core_status */
58         0u,                             /* flags */
59         KBASE_PM_CA_POLICY_ID_FIXED,    /* id */
60 };
61
62 KBASE_EXPORT_TEST_API(kbase_pm_ca_fixed_policy_ops)