summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gp10b/gr_gp10b.h
diff options
context:
space:
mode:
authorDeepak Nibade <dnibade@nvidia.com>2015-12-18 02:05:04 -0500
committerDeepak Nibade <dnibade@nvidia.com>2016-12-27 04:52:10 -0500
commitde47308b2c2ef2d24951a7e1c4ece9964417c167 (patch)
treee35cf4a956fb2580cd63f50cdf9d422b2d0763df /drivers/gpu/nvgpu/gp10b/gr_gp10b.h
parent095bd5e59d896ebab12af25ac05aa4071257ecb1 (diff)
gpu: nvgpu: add CILP support for gp10b
Add CILP support for gp10b by defining below function pointers (with detailed explanation) pre_process_sm_exception() - for CILP enabled channels, get the mask of errors - if we need to broadcast the stop_trigger, suspend all SMs - otherwise suspend only current SM - clear hww_global_esr values in h/w - gr_gp10b_set_cilp_preempt_pending() - get ctx_id - using sideband method, program FECS to generate interrupt on next ctxsw - disable and preempt the channel/TSG - set cilp_preempt_pending = true - clear single step mode - resume current SM handle_fecs_error() - we get ctxsw_intr1 upon next ctxsw - clear this interrupt - get handle of channel on which we first triggered SM exception - gr_gp10b_clear_cilp_preempt_pending() - set cilp_preempt_pending = false - send events to channel and debug session fd Bug 200156699 Change-Id: Ia765db47e68fb968fada6409609af505c079df53 Signed-off-by: Deepak Nibade <dnibade@nvidia.com> Reviewed-on: http://git-master/r/925897 GVS: Gerrit_Virtual_Submit Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gp10b/gr_gp10b.h')
-rw-r--r--drivers/gpu/nvgpu/gp10b/gr_gp10b.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/gp10b/gr_gp10b.h b/drivers/gpu/nvgpu/gp10b/gr_gp10b.h
index 62b70a22..c35fb384 100644
--- a/drivers/gpu/nvgpu/gp10b/gr_gp10b.h
+++ b/drivers/gpu/nvgpu/gp10b/gr_gp10b.h
@@ -46,6 +46,8 @@ struct gr_t18x {
46 struct dentry *debugfs_force_preemption_gfxp; 46 struct dentry *debugfs_force_preemption_gfxp;
47 struct dentry *debugfs_dump_ctxsw_stats; 47 struct dentry *debugfs_dump_ctxsw_stats;
48 } ctx_vars; 48 } ctx_vars;
49
50 int cilp_preempt_pending_chid;
49}; 51};
50 52
51struct gr_ctx_desc_t18x { 53struct gr_ctx_desc_t18x {
@@ -53,6 +55,9 @@ struct gr_ctx_desc_t18x {
53 struct mem_desc spill_ctxsw_buffer; 55 struct mem_desc spill_ctxsw_buffer;
54 struct mem_desc betacb_ctxsw_buffer; 56 struct mem_desc betacb_ctxsw_buffer;
55 struct mem_desc pagepool_ctxsw_buffer; 57 struct mem_desc pagepool_ctxsw_buffer;
58 u32 ctx_id;
59 bool ctx_id_valid;
60 bool cilp_preempt_pending;
56}; 61};
57 62
58#define NVGPU_GR_PREEMPTION_MODE_GFXP 1 63#define NVGPU_GR_PREEMPTION_MODE_GFXP 1