summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gm20b/fifo_gm20b.c
diff options
context:
space:
mode:
authorTerje Bergstrom <tbergstrom@nvidia.com>2017-10-16 17:58:17 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2017-10-17 17:05:19 -0400
commite039dcbc9dd7d0c47895bdbb49cdc3e1d11a3cae (patch)
tree38de57b02173520e7a279775f82e3b48e3c1aa87 /drivers/gpu/nvgpu/gm20b/fifo_gm20b.c
parent8f55976d4952020f1e7f257087bb79cfeb64f193 (diff)
gpu: nvgpu: Use nvgpu_rwsem as TSG channel lock
Use abstract nvgpu_rwsem as TSG channel list lock instead of the Linux specific rw_semaphore. JIRA NVGPU-259 Change-Id: I41a38b29d4651838b1962d69f102af1384e12cb6 Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1579935 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gm20b/fifo_gm20b.c')
-rw-r--r--drivers/gpu/nvgpu/gm20b/fifo_gm20b.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/gm20b/fifo_gm20b.c b/drivers/gpu/nvgpu/gm20b/fifo_gm20b.c
index d6429871..f4ddd92f 100644
--- a/drivers/gpu/nvgpu/gm20b/fifo_gm20b.c
+++ b/drivers/gpu/nvgpu/gm20b/fifo_gm20b.c
@@ -210,13 +210,13 @@ void gm20b_fifo_tsg_verify_status_ctx_reload(struct channel_gk20a *ch)
210 210
211 /* If CTX_RELOAD is set on a channel, move it to some other channel */ 211 /* If CTX_RELOAD is set on a channel, move it to some other channel */
212 if (gk20a_fifo_channel_status_is_ctx_reload(ch->g, ch->chid)) { 212 if (gk20a_fifo_channel_status_is_ctx_reload(ch->g, ch->chid)) {
213 down_read(&tsg->ch_list_lock); 213 nvgpu_rwsem_down_read(&tsg->ch_list_lock);
214 nvgpu_list_for_each_entry(temp_ch, &tsg->ch_list, channel_gk20a, ch_entry) { 214 nvgpu_list_for_each_entry(temp_ch, &tsg->ch_list, channel_gk20a, ch_entry) {
215 if (temp_ch->chid != ch->chid) { 215 if (temp_ch->chid != ch->chid) {
216 gm20b_fifo_set_ctx_reload(temp_ch); 216 gm20b_fifo_set_ctx_reload(temp_ch);
217 break; 217 break;
218 } 218 }
219 } 219 }
220 up_read(&tsg->ch_list_lock); 220 nvgpu_rwsem_up_read(&tsg->ch_list_lock);
221 } 221 }
222} 222}