From 41f9e9747720f0658b84491fcf77010d71e1900d Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Thu, 24 Sep 2015 08:28:28 -0700 Subject: Revert "gpu: nvgpu: Add CDE bits in FECS header" This reverts commit 882975f7f1b4e050be79b0a047a2daa8b53a9187. Change-Id: I4940fc9f7a837840be1ea8e42d58d603235d88d5 Signed-off-by: Terje Bergstrom Reviewed-on: http://git-master/r/804616 --- drivers/gpu/nvgpu/gk20a/cde_gk20a.c | 3 --- drivers/gpu/nvgpu/gk20a/channel_gk20a.h | 1 - drivers/gpu/nvgpu/gk20a/gr_gk20a.c | 11 +---------- drivers/gpu/nvgpu/gm20b/hw_ctxsw_prog_gm20b.h | 12 ------------ 4 files changed, 1 insertion(+), 26 deletions(-) diff --git a/drivers/gpu/nvgpu/gk20a/cde_gk20a.c b/drivers/gpu/nvgpu/gk20a/cde_gk20a.c index f148c65a..84b39b2d 100644 --- a/drivers/gpu/nvgpu/gk20a/cde_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/cde_gk20a.c @@ -487,9 +487,6 @@ static int gk20a_init_cde_required_class(struct gk20a_cde_ctx *cde_ctx, alloc_obj_ctx.class_num = required_class; alloc_obj_ctx.flags = 0; - /* CDE enabled */ - cde_ctx->ch->cde = true; - err = gk20a_alloc_obj_ctx(cde_ctx->ch, &alloc_obj_ctx); if (err) { gk20a_warn(&cde_ctx->pdev->dev, "cde: failed to allocate ctx. err=%d", diff --git a/drivers/gpu/nvgpu/gk20a/channel_gk20a.h b/drivers/gpu/nvgpu/gk20a/channel_gk20a.h index 219a7786..2ea5b4be 100644 --- a/drivers/gpu/nvgpu/gk20a/channel_gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/channel_gk20a.h @@ -91,7 +91,6 @@ struct channel_gk20a { bool bound; bool first_init; bool vpr; - bool cde; pid_t pid; struct mutex ioctl_lock; diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c index 24ee8876..0ae44c6f 100644 --- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c @@ -1612,7 +1612,7 @@ int gr_gk20a_load_golden_ctx_image(struct gk20a *g, struct channel_ctx_gk20a *ch_ctx = &c->ch_ctx; u32 virt_addr_lo; u32 virt_addr_hi; - u32 i, v, data, cde_v; + u32 i, v, data; int ret = 0; void *ctx_ptr = NULL; @@ -1631,15 +1631,6 @@ int gr_gk20a_load_golden_ctx_image(struct gk20a *g, if (!ctx_ptr) return -ENOMEM; - /* Enable CDE in FECS header. Default cde = 0, is disabled, - * so no need to do anything in else {} - */ - if (c->cde) { - cde_v = gk20a_mem_rd32(ctx_ptr + ctxsw_prog_main_image_ctl_o(), 0); - cde_v |= ctxsw_prog_main_image_ctl_cde_enabled_f(); - gk20a_mem_wr32(ctx_ptr + ctxsw_prog_main_image_ctl_o(), 0, cde_v); - } - for (i = 0; i < gr->ctx_vars.golden_image_size / 4; i++) gk20a_mem_wr32(ctx_ptr, i, gr->ctx_vars.local_golden_image[i]); diff --git a/drivers/gpu/nvgpu/gm20b/hw_ctxsw_prog_gm20b.h b/drivers/gpu/nvgpu/gm20b/hw_ctxsw_prog_gm20b.h index 34f8a6a4..cefd91e1 100644 --- a/drivers/gpu/nvgpu/gm20b/hw_ctxsw_prog_gm20b.h +++ b/drivers/gpu/nvgpu/gm20b/hw_ctxsw_prog_gm20b.h @@ -58,18 +58,6 @@ static inline u32 ctxsw_prog_main_image_num_gpcs_o(void) { return 0x00000008; } -static inline u32 ctxsw_prog_main_image_ctl_o(void) -{ - return 0x0000000c; -} -static inline u32 ctxsw_prog_main_image_ctl_cde_enabled_f(void) -{ - return 0x400; -} -static inline u32 ctxsw_prog_main_image_ctl_cde_disabled_f(void) -{ - return 0x0; -} static inline u32 ctxsw_prog_main_image_patch_count_o(void) { return 0x00000010; -- cgit v1.2.2