diff options
author | Debarshi Dutta <ddutta@nvidia.com> | 2017-08-03 06:04:44 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2017-08-17 17:26:47 -0400 |
commit | 98186ec2c2127c2af65a34f9e697e04f518a79ab (patch) | |
tree | 08ad87f3bf8c739e96b36f01728a8f7a30749a0e /drivers/gpu/nvgpu/gk20a/channel_gk20a.h | |
parent | 49dc335cfe588179cbb42d8bab53bc76ba88b28f (diff) |
gpu: nvgpu: Add wrapper over atomic_t and atomic64_t
- added wrapper structs nvgpu_atomic_t and nvgpu_atomic64_t over
atomic_t and atomic64_t
- added nvgpu_atomic_* and nvgpu_atomic64_* APIs to access the above
wrappers.
JIRA NVGPU-121
Change-Id: I61667bb0a84c2fc475365abb79bffb42b8b4786a
Signed-off-by: Debarshi Dutta <ddutta@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1533044
Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
GVS: Gerrit_Virtual_Submit
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/channel_gk20a.h')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/channel_gk20a.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/channel_gk20a.h b/drivers/gpu/nvgpu/gk20a/channel_gk20a.h index a9ccd93f..f022e630 100644 --- a/drivers/gpu/nvgpu/gk20a/channel_gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/channel_gk20a.h | |||
@@ -24,6 +24,7 @@ | |||
24 | #include <nvgpu/lock.h> | 24 | #include <nvgpu/lock.h> |
25 | #include <nvgpu/timers.h> | 25 | #include <nvgpu/timers.h> |
26 | #include <nvgpu/cond.h> | 26 | #include <nvgpu/cond.h> |
27 | #include <nvgpu/atomic.h> | ||
27 | 28 | ||
28 | struct gk20a; | 29 | struct gk20a; |
29 | struct gr_gk20a; | 30 | struct gr_gk20a; |
@@ -173,7 +174,7 @@ struct channel_gk20a { | |||
173 | 174 | ||
174 | struct nvgpu_spinlock ref_obtain_lock; | 175 | struct nvgpu_spinlock ref_obtain_lock; |
175 | bool referenceable; | 176 | bool referenceable; |
176 | atomic_t ref_count; | 177 | nvgpu_atomic_t ref_count; |
177 | struct nvgpu_cond ref_count_dec_wq; | 178 | struct nvgpu_cond ref_count_dec_wq; |
178 | #if GK20A_CHANNEL_REFCOUNT_TRACKING | 179 | #if GK20A_CHANNEL_REFCOUNT_TRACKING |
179 | /* | 180 | /* |
@@ -191,7 +192,7 @@ struct channel_gk20a { | |||
191 | 192 | ||
192 | int chid; | 193 | int chid; |
193 | bool wdt_enabled; | 194 | bool wdt_enabled; |
194 | atomic_t bound; | 195 | nvgpu_atomic_t bound; |
195 | bool first_init; | 196 | bool first_init; |
196 | bool vpr; | 197 | bool vpr; |
197 | bool deterministic; | 198 | bool deterministic; |