diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/channel_gk20a.c | 9 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/channel_gk20a.h | 1 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gr_gk20a.c | 3 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/vgpu/gr_vgpu.c | 5 |
4 files changed, 11 insertions, 7 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/channel_gk20a.c b/drivers/gpu/nvgpu/gk20a/channel_gk20a.c index 53b85ad8..444fec13 100644 --- a/drivers/gpu/nvgpu/gk20a/channel_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/channel_gk20a.c | |||
@@ -2501,6 +2501,12 @@ void gk20a_channel_event(struct channel_gk20a *ch) | |||
2501 | mutex_unlock(&ch->poll_events.lock); | 2501 | mutex_unlock(&ch->poll_events.lock); |
2502 | } | 2502 | } |
2503 | 2503 | ||
2504 | void gk20a_channel_post_event(struct channel_gk20a *ch) | ||
2505 | { | ||
2506 | gk20a_channel_event(ch); | ||
2507 | wake_up_interruptible_all(&ch->semaphore_wq); | ||
2508 | } | ||
2509 | |||
2504 | unsigned int gk20a_channel_poll(struct file *filep, poll_table *wait) | 2510 | unsigned int gk20a_channel_poll(struct file *filep, poll_table *wait) |
2505 | { | 2511 | { |
2506 | unsigned int mask = 0; | 2512 | unsigned int mask = 0; |
@@ -2656,8 +2662,7 @@ void gk20a_channel_semaphore_wakeup(struct gk20a *g) | |||
2656 | for (chid = 0; chid < f->num_channels; chid++) { | 2662 | for (chid = 0; chid < f->num_channels; chid++) { |
2657 | struct channel_gk20a *c = g->fifo.channel+chid; | 2663 | struct channel_gk20a *c = g->fifo.channel+chid; |
2658 | if (gk20a_channel_get(c)) { | 2664 | if (gk20a_channel_get(c)) { |
2659 | gk20a_channel_event(c); | 2665 | gk20a_channel_post_event(c); |
2660 | wake_up_interruptible_all(&c->semaphore_wq); | ||
2661 | gk20a_channel_update(c, 0); | 2666 | gk20a_channel_update(c, 0); |
2662 | gk20a_channel_put(c); | 2667 | gk20a_channel_put(c); |
2663 | } | 2668 | } |
diff --git a/drivers/gpu/nvgpu/gk20a/channel_gk20a.h b/drivers/gpu/nvgpu/gk20a/channel_gk20a.h index 4f0632dd..24a2fe11 100644 --- a/drivers/gpu/nvgpu/gk20a/channel_gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/channel_gk20a.h | |||
@@ -223,6 +223,7 @@ struct channel_gk20a *gk20a_get_channel_from_file(int fd); | |||
223 | void gk20a_channel_update(struct channel_gk20a *c, int nr_completed); | 223 | void gk20a_channel_update(struct channel_gk20a *c, int nr_completed); |
224 | unsigned int gk20a_channel_poll(struct file *filep, poll_table *wait); | 224 | unsigned int gk20a_channel_poll(struct file *filep, poll_table *wait); |
225 | void gk20a_channel_event(struct channel_gk20a *ch); | 225 | void gk20a_channel_event(struct channel_gk20a *ch); |
226 | void gk20a_channel_post_event(struct channel_gk20a *ch); | ||
226 | 227 | ||
227 | void gk20a_init_channel(struct gpu_ops *gops); | 228 | void gk20a_init_channel(struct gpu_ops *gops); |
228 | 229 | ||
diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c index bfb11566..6e3ea00a 100644 --- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c | |||
@@ -4890,8 +4890,7 @@ static int gk20a_gr_handle_semaphore_pending(struct gk20a *g, | |||
4890 | struct fifo_gk20a *f = &g->fifo; | 4890 | struct fifo_gk20a *f = &g->fifo; |
4891 | struct channel_gk20a *ch = &f->channel[isr_data->chid]; | 4891 | struct channel_gk20a *ch = &f->channel[isr_data->chid]; |
4892 | 4892 | ||
4893 | gk20a_channel_event(ch); | 4893 | gk20a_channel_post_event(ch); |
4894 | wake_up(&ch->semaphore_wq); | ||
4895 | 4894 | ||
4896 | return 0; | 4895 | return 0; |
4897 | } | 4896 | } |
diff --git a/drivers/gpu/nvgpu/vgpu/gr_vgpu.c b/drivers/gpu/nvgpu/vgpu/gr_vgpu.c index 373dfd56..4a22441c 100644 --- a/drivers/gpu/nvgpu/vgpu/gr_vgpu.c +++ b/drivers/gpu/nvgpu/vgpu/gr_vgpu.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * Virtualized GPU Graphics | 2 | * Virtualized GPU Graphics |
3 | * | 3 | * |
4 | * Copyright (c) 2014-2015, NVIDIA CORPORATION. All rights reserved. | 4 | * Copyright (c) 2014-2016, NVIDIA CORPORATION. All rights reserved. |
5 | * | 5 | * |
6 | * This program is free software; you can redistribute it and/or modify it | 6 | * This program is free software; you can redistribute it and/or modify it |
7 | * under the terms and conditions of the GNU General Public License, | 7 | * under the terms and conditions of the GNU General Public License, |
@@ -871,8 +871,7 @@ int vgpu_gr_isr(struct gk20a *g, struct tegra_vgpu_gr_intr_info *info) | |||
871 | wake_up(&ch->notifier_wq); | 871 | wake_up(&ch->notifier_wq); |
872 | break; | 872 | break; |
873 | case TEGRA_VGPU_GR_INTR_SEMAPHORE: | 873 | case TEGRA_VGPU_GR_INTR_SEMAPHORE: |
874 | gk20a_channel_event(ch); | 874 | gk20a_channel_post_event(ch); |
875 | wake_up(&ch->semaphore_wq); | ||
876 | break; | 875 | break; |
877 | case TEGRA_VGPU_GR_INTR_SEMAPHORE_TIMEOUT: | 876 | case TEGRA_VGPU_GR_INTR_SEMAPHORE_TIMEOUT: |
878 | gk20a_set_error_notifier(ch, | 877 | gk20a_set_error_notifier(ch, |