diff options
author | Deepak Nibade <dnibade@nvidia.com> | 2016-04-01 05:14:46 -0400 |
---|---|---|
committer | Terje Bergstrom <tbergstrom@nvidia.com> | 2016-04-19 11:15:37 -0400 |
commit | 1c96bc6942cdae7f4e90563687da7d068aea90bc (patch) | |
tree | 88e4923169670cbd9a8a50a03f8ca0ddba879e80 /drivers/gpu/nvgpu/gk20a/channel_gk20a.h | |
parent | 2b2f84219c4bd21be9a7abf34334ec6d443c6c38 (diff) |
gpu: nvgpu: add lock for fences
All pre/post fence accesses in last_submit are
currently protected by submit lock
In order to remove the submit lock, move all fence
accesses under own lock i.e. fence_lock
Bug 200187553
Change-Id: I0132d1933dc92db8c5ed8c9311e49a030aa2d38c
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/1120409
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/channel_gk20a.h')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/channel_gk20a.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/channel_gk20a.h b/drivers/gpu/nvgpu/gk20a/channel_gk20a.h index d8951b94..74c920e4 100644 --- a/drivers/gpu/nvgpu/gk20a/channel_gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/channel_gk20a.h | |||
@@ -152,9 +152,9 @@ struct channel_gk20a { | |||
152 | 152 | ||
153 | bool cmds_pending; | 153 | bool cmds_pending; |
154 | struct { | 154 | struct { |
155 | /* These fences should be accessed with submit_lock held. */ | ||
156 | struct gk20a_fence *pre_fence; | 155 | struct gk20a_fence *pre_fence; |
157 | struct gk20a_fence *post_fence; | 156 | struct gk20a_fence *post_fence; |
157 | struct mutex fence_lock; | ||
158 | } last_submit; | 158 | } last_submit; |
159 | 159 | ||
160 | void (*remove_support)(struct channel_gk20a *); | 160 | void (*remove_support)(struct channel_gk20a *); |