diff options
author | Terje Bergstrom <tbergstrom@nvidia.com> | 2017-06-20 15:18:47 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2017-06-21 20:34:49 -0400 |
commit | 92c43deefca150854193c6720717d56b61989c23 (patch) | |
tree | 2dbfdcdb3a0809b80d4fc50e1d882326e54c7d17 /drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c | |
parent | 2ffbdc50d884215ba043e8afd3c3bcbefd1e66f8 (diff) |
gpu: nvgpu: Remove Linux devnode fields from gk20a
Move Linux devnode related fields to a new header file os_linux.h.
The class structure is defined in module.c, so move its declaration
to module.h.
JIRA NVGPU-38
Change-Id: I5d8920169064f4289ff61004f7f81543a9aba221
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/1505927
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c b/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c index ceee1ae9..c189a00c 100644 --- a/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c | |||
@@ -25,6 +25,7 @@ | |||
25 | #include "gk20a.h" | 25 | #include "gk20a.h" |
26 | #include "platform_gk20a.h" | 26 | #include "platform_gk20a.h" |
27 | #include "gr_gk20a.h" | 27 | #include "gr_gk20a.h" |
28 | #include "common/linux/os_linux.h" | ||
28 | 29 | ||
29 | #include <nvgpu/log.h> | 30 | #include <nvgpu/log.h> |
30 | #include <nvgpu/atomic.h> | 31 | #include <nvgpu/atomic.h> |
@@ -266,6 +267,7 @@ static int gk20a_ctxsw_dev_ioctl_poll(struct gk20a_ctxsw_dev *dev) | |||
266 | 267 | ||
267 | int gk20a_ctxsw_dev_open(struct inode *inode, struct file *filp) | 268 | int gk20a_ctxsw_dev_open(struct inode *inode, struct file *filp) |
268 | { | 269 | { |
270 | struct nvgpu_os_linux *l; | ||
269 | struct gk20a *g; | 271 | struct gk20a *g; |
270 | struct gk20a_ctxsw_trace *trace; | 272 | struct gk20a_ctxsw_trace *trace; |
271 | struct gk20a_ctxsw_dev *dev; | 273 | struct gk20a_ctxsw_dev *dev; |
@@ -276,8 +278,8 @@ int gk20a_ctxsw_dev_open(struct inode *inode, struct file *filp) | |||
276 | /* only one VM for now */ | 278 | /* only one VM for now */ |
277 | const int vmid = 0; | 279 | const int vmid = 0; |
278 | 280 | ||
279 | g = container_of(inode->i_cdev, struct gk20a, ctxsw.cdev); | 281 | l = container_of(inode->i_cdev, struct nvgpu_os_linux, ctxsw.cdev); |
280 | g = gk20a_get(g); | 282 | g = gk20a_get(&l->g); |
281 | if (!g) | 283 | if (!g) |
282 | return -ENODEV; | 284 | return -ENODEV; |
283 | 285 | ||