gpu: nvgpu: Enable CE always

All GPUs have a copy engine. So delete the flag has_ce, because
it's always true.

JIRA NVGPU-16

Change-Id: I89db74c7cf66b24db84301b79832862ef28100b9
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/1325355
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
(cherry picked from commit 81660ab58c)
Reviewed-on: http://git-master/r/1328222
Reviewed-by: David Martinez Nieto <dmartineznie@nvidia.com>
Tested-by: David Martinez Nieto <dmartineznie@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Sumeet Gupta <sumeetg@nvidia.com>
This commit is contained in:
Terje Bergstrom
2016-09-07 14:21:16 -07:00
committed by mobile promotions
parent 83721dfab9
commit ccccde66e7
7 changed files with 7 additions and 34 deletions

View File

@@ -709,9 +709,6 @@ void gk20a_ce_debugfs_init(struct device *dev)
struct gk20a_platform *platform = dev_get_drvdata(dev);
struct gk20a *g = get_gk20a(dev);
if (!platform->has_ce)
return;
debugfs_create_u32("ce_app_ctx_count", S_IWUSR | S_IRUGO,
platform->debugfs, &g->ce_app.ctx_count);
debugfs_create_u32("ce_app_state", S_IWUSR | S_IRUGO,

View File

@@ -806,8 +806,7 @@ static int gk20a_pm_prepare_poweroff(struct device *dev)
/* cancel any pending cde work */
gk20a_cde_suspend(g);
if (platform->has_ce)
gk20a_ce_suspend(g);
gk20a_ce_suspend(g);
ret = gk20a_channel_suspend(g);
if (ret)
@@ -1095,8 +1094,7 @@ int gk20a_pm_finalize_poweron(struct device *dev)
if (platform->has_cde)
gk20a_init_cde_support(g);
if (platform->has_ce)
gk20a_init_ce_support(g);
gk20a_init_ce_support(g);
gk20a_init_mm_ce_context(g);
@@ -1687,8 +1685,7 @@ static int __exit gk20a_remove(struct platform_device *pdev)
if (g->remove_support)
g->remove_support(dev);
if (platform->has_ce)
gk20a_ce_destroy(g);
gk20a_ce_destroy(g);
#ifdef CONFIG_ARCH_TEGRA_18x_SOC
nvgpu_clk_arb_cleanup_arbiter(g);

View File

@@ -806,15 +806,13 @@ static void gk20a_vidmem_destroy(struct gk20a *g)
static void gk20a_remove_mm_ce_support(struct mm_gk20a *mm)
{
struct gk20a *g = gk20a_from_mm(mm);
struct gk20a_platform *platform = gk20a_get_platform(g->dev);
if (mm->vidmem.ce_ctx_id != (u32)~0)
gk20a_ce_delete_context(g->dev, mm->vidmem.ce_ctx_id);
mm->vidmem.ce_ctx_id = (u32)~0;
if (platform->has_ce)
gk20a_vm_remove_support_nofree(&mm->ce.vm);
gk20a_vm_remove_support_nofree(&mm->ce.vm);
}
@@ -989,7 +987,6 @@ int gk20a_init_mm_setup_sw(struct gk20a *g)
{
struct mm_gk20a *mm = &g->mm;
int err;
struct gk20a_platform *platform = gk20a_get_platform(g->dev);
gk20a_dbg_fn("");
@@ -1054,11 +1051,9 @@ int gk20a_init_mm_setup_sw(struct gk20a *g)
if (err)
return err;
if (platform->has_ce) {
err = gk20a_init_ce_vm(mm);
if (err)
return err;
}
err = gk20a_init_ce_vm(mm);
if (err)
return err;
/* set vm_alloc_share op here as gk20a_as_alloc_share needs it */
g->ops.mm.vm_alloc_share = gk20a_vm_alloc_share;

View File

@@ -244,8 +244,6 @@ struct gk20a_platform {
bool has_cde;
bool has_ce;
/* soc name for finding firmware files */
const char *soc_name;

View File

@@ -1072,8 +1072,6 @@ struct gk20a_platform gk20a_tegra_platform = {
.secure_page_alloc = gk20a_tegra_secure_page_alloc,
.dump_platform_dependencies = gk20a_tegra_debug_dump,
.has_ce = true,
.soc_name = "tegra12x",
.vidmem_is_vidmem = false,
@@ -1150,8 +1148,6 @@ struct gk20a_platform gm20b_tegra_platform = {
.has_cde = true,
.has_ce = true,
.soc_name = "tegra21x",
.vidmem_is_vidmem = false,

View File

@@ -440,8 +440,6 @@ struct gk20a_platform gp10b_tegra_platform = {
.has_cde = true,
.has_ce = true,
.clk_get_rate = gp10b_get_clk_rate,
.clk_round_rate = gp10b_round_clk_rate,
.clk_set_rate = gp10b_set_clk_rate,

View File

@@ -83,8 +83,6 @@ static struct gk20a_platform nvgpu_pci_device[] = {
.ch_wdt_timeout_ms = 7000,
.has_ce = true,
.vidmem_is_vidmem = true,
.vbios_min_version = 0x86063000,
.hardcode_sw_threshold = true,
@@ -117,8 +115,6 @@ static struct gk20a_platform nvgpu_pci_device[] = {
.ch_wdt_timeout_ms = 7000,
.has_ce = true,
.vidmem_is_vidmem = true,
.vbios_min_version = 0x86062d00,
.hardcode_sw_threshold = true,
@@ -151,8 +147,6 @@ static struct gk20a_platform nvgpu_pci_device[] = {
.ch_wdt_timeout_ms = 7000,
.has_ce = true,
.vidmem_is_vidmem = true,
.vbios_min_version = 0x86063000,
.hardcode_sw_threshold = true,
@@ -185,8 +179,6 @@ static struct gk20a_platform nvgpu_pci_device[] = {
.ch_wdt_timeout_ms = 7000,
.has_ce = true,
.vidmem_is_vidmem = true,
.vbios_min_version = 0x86064700,
.hardcode_sw_threshold = false,