summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a/tsg_gk20a.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/tsg_gk20a.h')
-rw-r--r--drivers/gpu/nvgpu/gk20a/tsg_gk20a.h44
1 files changed, 44 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/tsg_gk20a.h b/drivers/gpu/nvgpu/gk20a/tsg_gk20a.h
new file mode 100644
index 00000000..2530a4bd
--- /dev/null
+++ b/drivers/gpu/nvgpu/gk20a/tsg_gk20a.h
@@ -0,0 +1,44 @@
1/*
2 * Copyright (c) 2014, NVIDIA CORPORATION. All rights reserved.
3 *
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms and conditions of the GNU General Public License,
6 * version 2, as published by the Free Software Foundation.
7 *
8 * This program is distributed in the hope it will be useful, but WITHOUT
9 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
10 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
11 * more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16#ifndef __TSG_GK20A_H_
17#define __TSG_GK20A_H_
18
19#define NVGPU_INVALID_TSG_ID (-1)
20
21bool gk20a_is_channel_marked_as_tsg(struct channel_gk20a *ch);
22
23int gk20a_tsg_dev_release(struct inode *inode, struct file *filp);
24int gk20a_tsg_dev_open(struct inode *inode, struct file *filp);
25long gk20a_tsg_dev_ioctl(struct file *filp,
26 unsigned int cmd, unsigned long arg);
27
28int gk20a_init_tsg_support(struct gk20a *g, u32 tsgid);
29
30int gk20a_bind_runnable_channel_to_tsg(struct channel_gk20a *ch, int tsgid);
31int gk20a_unbind_channel_from_tsg(struct channel_gk20a *ch, int tsgid);
32
33struct tsg_gk20a {
34 struct gk20a *g;
35
36 bool in_use;
37 int tsgid;
38
39 struct list_head ch_runnable_list;
40 int num_runnable_channels;
41 struct mutex ch_list_lock;
42};
43
44#endif /* __TSG_GK20A_H_ */