diff --git a/drivers/gpu/nvgpu/Makefile.nvgpu-t18x b/drivers/gpu/nvgpu/Makefile.nvgpu-t18x index 548a9c0d2..e7d184927 100644 --- a/drivers/gpu/nvgpu/Makefile.nvgpu-t18x +++ b/drivers/gpu/nvgpu/Makefile.nvgpu-t18x @@ -26,7 +26,8 @@ nvgpu-y += \ $(nvgpu-t18x)/gp106/gr_ctx_gp106.o \ $(nvgpu-t18x)/gp106/acr_gp106.o \ $(nvgpu-t18x)/gp106/sec2_gp106.o \ - $(nvgpu-t18x)/gp106/fifo_gp106.o + $(nvgpu-t18x)/gp106/fifo_gp106.o \ + $(nvgpu-t18x)/gp106/ltc_gp106.o nvgpu-$(CONFIG_TEGRA_GK20A) += $(nvgpu-t18x)/gp10b/platform_gp10b_tegra.o diff --git a/drivers/gpu/nvgpu/gp106/hal_gp106.c b/drivers/gpu/nvgpu/gp106/hal_gp106.c index 5414eb4a0..a52fab7b0 100644 --- a/drivers/gpu/nvgpu/gp106/hal_gp106.c +++ b/drivers/gpu/nvgpu/gp106/hal_gp106.c @@ -22,7 +22,7 @@ #include "gp10b/gr_gp10b.h" #include "gp10b/mc_gp10b.h" -#include "gp10b/ltc_gp10b.h" +#include "gp106/ltc_gp106.h" #include "gp10b/mm_gp10b.h" #include "gp10b/ce_gp10b.h" #include "gp10b/fb_gp10b.h" @@ -147,7 +147,7 @@ int gp106_init_hal(struct gk20a *g) gp10b_init_mc(gops); gp106_init_gr(gops); - gp10b_init_ltc(gops); + gp106_init_ltc(gops); gp10b_init_fb(gops); gp106_init_fifo(gops); gp10b_init_ce(gops); diff --git a/drivers/gpu/nvgpu/gp106/ltc_gp106.c b/drivers/gpu/nvgpu/gp106/ltc_gp106.c new file mode 100644 index 000000000..8f630a416 --- /dev/null +++ b/drivers/gpu/nvgpu/gp106/ltc_gp106.c @@ -0,0 +1,25 @@ +/* + * Copyright (c) 2016, NVIDIA CORPORATION. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms and conditions of the GNU General Public License, + * version 2, as published by the Free Software Foundation. + * + * This program is distributed in the hope it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for + * more details. + */ + +#include + +#include "gk20a/gk20a.h" +#include "gp10b/ltc_gp10b.h" + +void gp106_init_ltc(struct gpu_ops *gops) +{ + gp10b_init_ltc(gops); + + /* dGPU does not need the LTC hack */ + gops->ltc.cbc_fix_config = NULL; +} diff --git a/drivers/gpu/nvgpu/gp106/ltc_gp106.h b/drivers/gpu/nvgpu/gp106/ltc_gp106.h new file mode 100644 index 000000000..4720d7a1f --- /dev/null +++ b/drivers/gpu/nvgpu/gp106/ltc_gp106.h @@ -0,0 +1,19 @@ +/* + * Copyright (c) 2016, NVIDIA CORPORATION. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms and conditions of the GNU General Public License, + * version 2, as published by the Free Software Foundation. + * + * This program is distributed in the hope it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for + * more details. + */ + +#ifndef LTC_GP106_H +#define LTC_GP106_H +struct gpu_ops; + +void gp106_init_ltc(struct gpu_ops *gops); +#endif