diff options
author | Konsta Holtta <kholtta@nvidia.com> | 2016-05-25 06:13:56 -0400 |
---|---|---|
committer | Terje Bergstrom <tbergstrom@nvidia.com> | 2016-06-22 11:30:05 -0400 |
commit | f438c66598cf169ec7669bc659c7b23587b5bab3 (patch) | |
tree | 0d280f93aa7945d3ca14a3a864fe17836c6345b8 /drivers/gpu/nvgpu/gk20a/gr_gk20a.h | |
parent | 10b75f9cdd2184e9728b7d38dd037330d1c20704 (diff) |
gpu: nvgpu: force clean patch ctx begin/end
This patch_context map/unmap pair has become a mere wrapper for the more
general gk20a_mem_{begin,end}(). To be consistent about mappings,
require that each patch_write is surrounded by an explicit begin/end
pair, instead of relying on possible inefficient per-write map/unmap.
Remove also the cpu_va check from .._write_end() since the buffers may
be exist in vidmem without a cpu mapping.
JIRA DNVGPU-24
Change-Id: Ia05d52d3d712f2d63730eedc078845fde3e217c1
Signed-off-by: Konsta Holtta <kholtta@nvidia.com>
Reviewed-on: http://git-master/r/1157298
GVS: Gerrit_Virtual_Submit
Reviewed-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/gr_gk20a.h')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gr_gk20a.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.h b/drivers/gpu/nvgpu/gk20a/gr_gk20a.h index 189994ef..ad6d8049 100644 --- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.h | |||
@@ -530,11 +530,11 @@ int gr_gk20a_update_hwpm_ctxsw_mode(struct gk20a *g, | |||
530 | bool enable_hwpm_ctxsw); | 530 | bool enable_hwpm_ctxsw); |
531 | 531 | ||
532 | struct channel_ctx_gk20a; | 532 | struct channel_ctx_gk20a; |
533 | int gr_gk20a_ctx_patch_write(struct gk20a *g, struct channel_ctx_gk20a *ch_ctx, | 533 | void gr_gk20a_ctx_patch_write(struct gk20a *g, struct channel_ctx_gk20a *ch_ctx, |
534 | u32 addr, u32 data, bool patch); | 534 | u32 addr, u32 data, bool patch); |
535 | int gr_gk20a_ctx_patch_write_begin(struct gk20a *g, | 535 | int gr_gk20a_ctx_patch_write_begin(struct gk20a *g, |
536 | struct channel_ctx_gk20a *ch_ctx); | 536 | struct channel_ctx_gk20a *ch_ctx); |
537 | int gr_gk20a_ctx_patch_write_end(struct gk20a *g, | 537 | void gr_gk20a_ctx_patch_write_end(struct gk20a *g, |
538 | struct channel_ctx_gk20a *ch_ctx); | 538 | struct channel_ctx_gk20a *ch_ctx); |
539 | void gr_gk20a_commit_global_pagepool(struct gk20a *g, | 539 | void gr_gk20a_commit_global_pagepool(struct gk20a *g, |
540 | struct channel_ctx_gk20a *ch_ctx, | 540 | struct channel_ctx_gk20a *ch_ctx, |