diff options
Diffstat (limited to 'drivers/gpu/nvgpu/vgpu')
-rw-r--r-- | drivers/gpu/nvgpu/vgpu/fifo_vgpu.c | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/vgpu/fifo_vgpu.c b/drivers/gpu/nvgpu/vgpu/fifo_vgpu.c index dad9464a..9591c72a 100644 --- a/drivers/gpu/nvgpu/vgpu/fifo_vgpu.c +++ b/drivers/gpu/nvgpu/vgpu/fifo_vgpu.c | |||
@@ -102,6 +102,23 @@ static void vgpu_channel_free_inst(struct gk20a *g, struct channel_gk20a *ch) | |||
102 | WARN_ON(err || msg.ret); | 102 | WARN_ON(err || msg.ret); |
103 | } | 103 | } |
104 | 104 | ||
105 | static void vgpu_channel_enable(struct channel_gk20a *ch) | ||
106 | { | ||
107 | struct gk20a_platform *platform = gk20a_get_platform(ch->g->dev); | ||
108 | struct tegra_vgpu_cmd_msg msg; | ||
109 | struct tegra_vgpu_channel_config_params *p = | ||
110 | &msg.params.channel_config; | ||
111 | int err; | ||
112 | |||
113 | gk20a_dbg_fn(""); | ||
114 | |||
115 | msg.cmd = TEGRA_VGPU_CMD_CHANNEL_ENABLE; | ||
116 | msg.handle = platform->virt_handle; | ||
117 | p->handle = ch->virt_ctx; | ||
118 | err = vgpu_comm_sendrecv(&msg, sizeof(msg), sizeof(msg)); | ||
119 | WARN_ON(err || msg.ret); | ||
120 | } | ||
121 | |||
105 | static void vgpu_channel_disable(struct channel_gk20a *ch) | 122 | static void vgpu_channel_disable(struct channel_gk20a *ch) |
106 | { | 123 | { |
107 | struct gk20a_platform *platform = gk20a_get_platform(ch->g->dev); | 124 | struct gk20a_platform *platform = gk20a_get_platform(ch->g->dev); |
@@ -741,7 +758,7 @@ void vgpu_init_fifo_ops(struct gpu_ops *gops) | |||
741 | { | 758 | { |
742 | gops->fifo.bind_channel = vgpu_channel_bind; | 759 | gops->fifo.bind_channel = vgpu_channel_bind; |
743 | gops->fifo.unbind_channel = vgpu_channel_unbind; | 760 | gops->fifo.unbind_channel = vgpu_channel_unbind; |
744 | gops->fifo.enable_channel = NULL; | 761 | gops->fifo.enable_channel = vgpu_channel_enable; |
745 | gops->fifo.disable_channel = vgpu_channel_disable; | 762 | gops->fifo.disable_channel = vgpu_channel_disable; |
746 | gops->fifo.alloc_inst = vgpu_channel_alloc_inst; | 763 | gops->fifo.alloc_inst = vgpu_channel_alloc_inst; |
747 | gops->fifo.free_inst = vgpu_channel_free_inst; | 764 | gops->fifo.free_inst = vgpu_channel_free_inst; |