summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/clk/clk_arb.h
diff options
context:
space:
mode:
authorMahantesh Kumbar <mkumbar@nvidia.com>2017-10-20 03:04:00 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2017-10-25 20:29:36 -0400
commit0dcf0ede812aa55aa106a5e6c2f86216fcbfd5e0 (patch)
tree6414aa6c9966e98b7c58a9700a8e76abe1f93999 /drivers/gpu/nvgpu/clk/clk_arb.h
parentc79112f3b1e2a428603e06486bd3cea83942c14e (diff)
gpu: nvgpu: move clk_arb to linux specific
- Clock arbiter has lot of linux dependent code so moved clk_arb.c to common/linux folder & clk_arb.h to include/nvgpu/clk_arb.h, this move helps to unblock QNX. - QNX must implement functions present under clk_arb.h as needed. JIRA NVGPU-33 Change-Id: I38369fafda9c2cb9ba2175b3e530e40d0c746601 Signed-off-by: Mahantesh Kumbar <mkumbar@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1582473 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/clk/clk_arb.h')
-rw-r--r--drivers/gpu/nvgpu/clk/clk_arb.h80
1 files changed, 0 insertions, 80 deletions
diff --git a/drivers/gpu/nvgpu/clk/clk_arb.h b/drivers/gpu/nvgpu/clk/clk_arb.h
deleted file mode 100644
index 8545e01b..00000000
--- a/drivers/gpu/nvgpu/clk/clk_arb.h
+++ /dev/null
@@ -1,80 +0,0 @@
1/*
2 * Copyright (c) 2016-2017, NVIDIA CORPORATION. All rights reserved.
3 *
4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"),
6 * to deal in the Software without restriction, including without limitation
7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 * and/or sell copies of the Software, and to permit persons to whom the
9 * Software is furnished to do so, subject to the following conditions:
10 *
11 * The above copyright notice and this permission notice shall be included in
12 * all copies or substantial portions of the Software.
13 *
14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
17 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
19 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20 * DEALINGS IN THE SOFTWARE.
21 */
22
23#ifndef _CLK_ARB_H_
24#define _CLK_ARB_H_
25
26struct gk20a;
27struct nvgpu_clk_session;
28
29int nvgpu_clk_arb_init_arbiter(struct gk20a *g);
30
31int nvgpu_clk_arb_get_arbiter_clk_range(struct gk20a *g, u32 api_domain,
32 u16 *min_mhz, u16 *max_mhz);
33
34int nvgpu_clk_arb_get_arbiter_actual_mhz(struct gk20a *g,
35 u32 api_domain, u16 *actual_mhz);
36
37int nvgpu_clk_arb_get_arbiter_effective_mhz(struct gk20a *g,
38 u32 api_domain, u16 *effective_mhz);
39
40int nvgpu_clk_arb_get_arbiter_clk_f_points(struct gk20a *g,
41 u32 api_domain, u32 *max_points, u16 *fpoints);
42
43u32 nvgpu_clk_arb_get_arbiter_clk_domains(struct gk20a *g);
44bool nvgpu_clk_arb_is_valid_domain(struct gk20a *g, u32 api_domain);
45
46void nvgpu_clk_arb_cleanup_arbiter(struct gk20a *g);
47
48int nvgpu_clk_arb_install_session_fd(struct gk20a *g,
49 struct nvgpu_clk_session *session);
50
51int nvgpu_clk_arb_init_session(struct gk20a *g,
52 struct nvgpu_clk_session **_session);
53
54void nvgpu_clk_arb_release_session(struct gk20a *g,
55 struct nvgpu_clk_session *session);
56
57int nvgpu_clk_arb_commit_request_fd(struct gk20a *g,
58 struct nvgpu_clk_session *session, int request_fd);
59
60int nvgpu_clk_arb_set_session_target_mhz(struct nvgpu_clk_session *session,
61 int fd, u32 api_domain, u16 target_mhz);
62
63int nvgpu_clk_arb_get_session_target_mhz(struct nvgpu_clk_session *session,
64 u32 api_domain, u16 *target_mhz);
65
66int nvgpu_clk_arb_install_event_fd(struct gk20a *g,
67 struct nvgpu_clk_session *session, int *event_fd, u32 alarm_mask);
68
69int nvgpu_clk_arb_install_request_fd(struct gk20a *g,
70 struct nvgpu_clk_session *session, int *event_fd);
71
72void nvgpu_clk_arb_schedule_vf_table_update(struct gk20a *g);
73
74int nvgpu_clk_arb_get_current_pstate(struct gk20a *g);
75
76void nvgpu_clk_arb_pstate_change_lock(struct gk20a *g, bool lock);
77
78void nvgpu_clk_arb_schedule_alarm(struct gk20a *g, u32 alarm);
79#endif /* _CLK_ARB_H_ */
80