summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gp106/gr_gp106.c
diff options
context:
space:
mode:
authorTerje Bergstrom <tbergstrom@nvidia.com>2017-11-09 18:12:41 -0500
committermobile promotions <svcmobile_promotions@nvidia.com>2017-11-17 19:29:41 -0500
commit9d04e970937657d11620d812c29a5d10828440fc (patch)
tree78d06a0773317241ddfdc9d2b1bc6c871f3175c7 /drivers/gpu/nvgpu/gp106/gr_gp106.c
parent35ae4194a05d47aa6d79353428f81f2ca47ce90f (diff)
gpu: nvgpu: Remove separation of t18x code
Remove separation of t18x specific code and fields and the associated ifdefs. We can build T18x code in always. Change-Id: I4e8eae9c30335632a2da48b418c6138193831b4f Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1595431 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gp106/gr_gp106.c')
-rw-r--r--drivers/gpu/nvgpu/gp106/gr_gp106.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/drivers/gpu/nvgpu/gp106/gr_gp106.c b/drivers/gpu/nvgpu/gp106/gr_gp106.c
index fea337e7..bed08fed 100644
--- a/drivers/gpu/nvgpu/gp106/gr_gp106.c
+++ b/drivers/gpu/nvgpu/gp106/gr_gp106.c
@@ -140,11 +140,11 @@ int gr_gp106_set_ctxsw_preemption_mode(struct gk20a *g,
140{ 140{
141 int err = 0; 141 int err = 0;
142 142
143 if (class == PASCAL_B && g->gr.t18x.ctx_vars.force_preemption_gfxp) 143 if (class == PASCAL_B && g->gr.ctx_vars.force_preemption_gfxp)
144 graphics_preempt_mode = NVGPU_PREEMPTION_MODE_GRAPHICS_GFXP; 144 graphics_preempt_mode = NVGPU_PREEMPTION_MODE_GRAPHICS_GFXP;
145 145
146 if (class == PASCAL_COMPUTE_B && 146 if (class == PASCAL_COMPUTE_B &&
147 g->gr.t18x.ctx_vars.force_preemption_cilp) 147 g->gr.ctx_vars.force_preemption_cilp)
148 compute_preempt_mode = NVGPU_PREEMPTION_MODE_COMPUTE_CILP; 148 compute_preempt_mode = NVGPU_PREEMPTION_MODE_COMPUTE_CILP;
149 149
150 /* check for invalid combinations */ 150 /* check for invalid combinations */
@@ -178,8 +178,8 @@ int gr_gp106_set_ctxsw_preemption_mode(struct gk20a *g,
178 attrib_cb_size); 178 attrib_cb_size);
179 179
180 err = gr_gp10b_alloc_buffer(vm, 180 err = gr_gp10b_alloc_buffer(vm,
181 g->gr.t18x.ctx_vars.preempt_image_size, 181 g->gr.ctx_vars.preempt_image_size,
182 &gr_ctx->t18x.preempt_ctxsw_buffer); 182 &gr_ctx->preempt_ctxsw_buffer);
183 if (err) { 183 if (err) {
184 nvgpu_err(g, "cannot allocate preempt buffer"); 184 nvgpu_err(g, "cannot allocate preempt buffer");
185 goto fail; 185 goto fail;
@@ -187,7 +187,7 @@ int gr_gp106_set_ctxsw_preemption_mode(struct gk20a *g,
187 187
188 err = gr_gp10b_alloc_buffer(vm, 188 err = gr_gp10b_alloc_buffer(vm,
189 spill_size, 189 spill_size,
190 &gr_ctx->t18x.spill_ctxsw_buffer); 190 &gr_ctx->spill_ctxsw_buffer);
191 if (err) { 191 if (err) {
192 nvgpu_err(g, "cannot allocate spill buffer"); 192 nvgpu_err(g, "cannot allocate spill buffer");
193 goto fail_free_preempt; 193 goto fail_free_preempt;
@@ -195,7 +195,7 @@ int gr_gp106_set_ctxsw_preemption_mode(struct gk20a *g,
195 195
196 err = gr_gp10b_alloc_buffer(vm, 196 err = gr_gp10b_alloc_buffer(vm,
197 attrib_cb_size, 197 attrib_cb_size,
198 &gr_ctx->t18x.betacb_ctxsw_buffer); 198 &gr_ctx->betacb_ctxsw_buffer);
199 if (err) { 199 if (err) {
200 nvgpu_err(g, "cannot allocate beta buffer"); 200 nvgpu_err(g, "cannot allocate beta buffer");
201 goto fail_free_spill; 201 goto fail_free_spill;
@@ -203,7 +203,7 @@ int gr_gp106_set_ctxsw_preemption_mode(struct gk20a *g,
203 203
204 err = gr_gp10b_alloc_buffer(vm, 204 err = gr_gp10b_alloc_buffer(vm,
205 pagepool_size, 205 pagepool_size,
206 &gr_ctx->t18x.pagepool_ctxsw_buffer); 206 &gr_ctx->pagepool_ctxsw_buffer);
207 if (err) { 207 if (err) {
208 nvgpu_err(g, "cannot allocate page pool"); 208 nvgpu_err(g, "cannot allocate page pool");
209 goto fail_free_betacb; 209 goto fail_free_betacb;
@@ -236,11 +236,11 @@ int gr_gp106_set_ctxsw_preemption_mode(struct gk20a *g,
236 return 0; 236 return 0;
237 237
238fail_free_betacb: 238fail_free_betacb:
239 nvgpu_dma_unmap_free(vm, &gr_ctx->t18x.betacb_ctxsw_buffer); 239 nvgpu_dma_unmap_free(vm, &gr_ctx->betacb_ctxsw_buffer);
240fail_free_spill: 240fail_free_spill:
241 nvgpu_dma_unmap_free(vm, &gr_ctx->t18x.spill_ctxsw_buffer); 241 nvgpu_dma_unmap_free(vm, &gr_ctx->spill_ctxsw_buffer);
242fail_free_preempt: 242fail_free_preempt:
243 nvgpu_dma_unmap_free(vm, &gr_ctx->t18x.preempt_ctxsw_buffer); 243 nvgpu_dma_unmap_free(vm, &gr_ctx->preempt_ctxsw_buffer);
244fail: 244fail:
245 return err; 245 return err;
246} 246}