blob: fc82995ef10d05a9a4efd76447892b9e2863e64a [file] [log] [blame]
rjw1f884582022-01-06 17:20:42 +08001/*
2 * * Copyright (C) 2018 MediaTek Inc.
3 * *
4 * * This program is free software: you can redistribute it and/or modify
5 * * it under the terms of the GNU General Public License version 2 as
6 * * published by the Free Software Foundation.
7 * *
8 * * This program is distributed in the hope that it will be useful,
9 * * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * * GNU General Public License for more details.
12 * */
13
14
15#ifndef MET_POWER
16#define MET_POWER
17
18enum {
19 _PM_QOS_RESERVED = 0,
20 _PM_QOS_CPU_DMA_LATENCY,
21 _PM_QOS_NETWORK_LATENCY,
22 _PM_QOS_NETWORK_THROUGHPUT,
23 _PM_QOS_MEMORY_BANDWIDTH,
24
25 _PM_QOS_CPU_MEMORY_BANDWIDTH,
26 _PM_QOS_GPU_MEMORY_BANDWIDTH,
27 _PM_QOS_MM_MEMORY_BANDWIDTH,
28 _PM_QOS_OTHER_MEMORY_BANDWIDTH,
29 _PM_QOS_MM0_BANDWIDTH_LIMITER,
30 _PM_QOS_MM1_BANDWIDTH_LIMITER,
31
32 _PM_QOS_DDR_OPP,
33 _PM_QOS_VCORE_OPP,
34 _PM_QOS_SCP_VCORE_REQUEST,
35 _PM_QOS_POWER_MODEL_DDR_REQUEST,
36 _PM_QOS_POWER_MODEL_VCORE_REQUEST,
37 _PM_QOS_VCORE_DVFS_FORCE_OPP,
38
39 _PM_QOS_DISP_FREQ,
40 _PM_QOS_MDP_FREQ,
41 _PM_QOS_VDEC_FREQ,
42 _PM_QOS_VENC_FREQ,
43 _PM_QOS_IMG_FREQ,
44 _PM_QOS_CAM_FREQ,
45 _PM_QOS_VVPU_OPP,
46 _PM_QOS_VMDLA_OPP,
47 _PM_QOS_ISP_HRT_BANDWIDTH,
48 _PM_QOS_APU_MEMORY_BANDWIDTH,
49 /* insert new class ID */
50 _PM_QOS_NUM_CLASSES,
51};
52/* Action requested to pm_qos_update_target */
53enum _pm_qos_req_action {
54 _PM_QOS_ADD_REQ, /* Add a new request */
55 _PM_QOS_UPDATE_REQ, /* Update an existing request */
56 _PM_QOS_REMOVE_REQ /* Remove an existing request */
57};
58
59extern void pm_qos_update_request(int pm_qos_class, s32 value, char *owner);
60extern void pm_qos_update_target(unsigned int action, int prev_value, int curr_value);
61
62#endif /* MET_DRV */
63