From 5e486b518292b1178eae49d58a1bc0894788a281 Mon Sep 17 00:00:00 2001 From: David Nieto Date: Tue, 23 Aug 2016 10:47:10 -0700 Subject: gpu: nvgpu: fix cbc base calculation for dGPU JIRA DNVGPU-9 Change-Id: I22667acfadfcabf79af841ca5389e41d2ac34860 Signed-off-by: David Nieto Reviewed-on: http://git-master/r/1206478 (cherry picked from commit 098b932f7633a903c915b1257beb9304735b4113) Reviewed-on: http://git-master/r/1210288 Reviewed-by: Terje Bergstrom Tested-by: Terje Bergstrom --- drivers/gpu/nvgpu/gp106/ltc_gp106.c | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 drivers/gpu/nvgpu/gp106/ltc_gp106.c (limited to 'drivers/gpu/nvgpu/gp106/ltc_gp106.c') diff --git a/drivers/gpu/nvgpu/gp106/ltc_gp106.c b/drivers/gpu/nvgpu/gp106/ltc_gp106.c new file mode 100644 index 00000000..8f630a41 --- /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; +} -- cgit v1.2.2 From e4fa9712acacfeced2758b91721d31274e6fe2e7 Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Wed, 24 Aug 2016 15:10:36 -0700 Subject: gpu: nvgpu: Do not initialize CBC on Pascal dGPU CBC_BASE register is protected on Pascal dGPUs. Skip initializing it. Bug 1799537 Change-Id: Ie4b0ac5a37c3c586d1b631ce38823d156b554e1e Signed-off-by: Terje Bergstrom Reviewed-on: http://git-master/r/1208016 (cherry picked from commit 5f9dbca140573798bd05b5b27a7b6abe1871e90f) Reviewed-on: http://git-master/r/1210289 Reviewed-by: Automatic_Commit_Validation_User --- drivers/gpu/nvgpu/gp106/ltc_gp106.c | 1 + 1 file changed, 1 insertion(+) (limited to 'drivers/gpu/nvgpu/gp106/ltc_gp106.c') diff --git a/drivers/gpu/nvgpu/gp106/ltc_gp106.c b/drivers/gpu/nvgpu/gp106/ltc_gp106.c index 8f630a41..ef0e351d 100644 --- a/drivers/gpu/nvgpu/gp106/ltc_gp106.c +++ b/drivers/gpu/nvgpu/gp106/ltc_gp106.c @@ -22,4 +22,5 @@ void gp106_init_ltc(struct gpu_ops *gops) /* dGPU does not need the LTC hack */ gops->ltc.cbc_fix_config = NULL; + gops->ltc.init_cbc = NULL; } -- cgit v1.2.2 From 5544272474d7b1e3103eed76fbaf91ba7a739345 Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Fri, 26 Aug 2016 10:09:24 -0700 Subject: gpu: nvgpu: gp106: Skip LTCA initialization Skip LTCA initialization on dGPU. Bug 1799537 Change-Id: Ieb4c72e2169dc6bee73306c9b1e6c80866167a1a Signed-off-by: Terje Bergstrom Reviewed-on: http://git-master/r/1208714 (cherry picked from commit 9a8dc5fe96b29b8a67f8203f17126b0093721312) Reviewed-on: http://git-master/r/1219164 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit --- drivers/gpu/nvgpu/gp106/ltc_gp106.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'drivers/gpu/nvgpu/gp106/ltc_gp106.c') diff --git a/drivers/gpu/nvgpu/gp106/ltc_gp106.c b/drivers/gpu/nvgpu/gp106/ltc_gp106.c index ef0e351d..dcd4fbad 100644 --- a/drivers/gpu/nvgpu/gp106/ltc_gp106.c +++ b/drivers/gpu/nvgpu/gp106/ltc_gp106.c @@ -14,6 +14,7 @@ #include #include "gk20a/gk20a.h" +#include "gm20b/ltc_gm20b.h" #include "gp10b/ltc_gp10b.h" void gp106_init_ltc(struct gpu_ops *gops) @@ -23,4 +24,5 @@ void gp106_init_ltc(struct gpu_ops *gops) /* dGPU does not need the LTC hack */ gops->ltc.cbc_fix_config = NULL; gops->ltc.init_cbc = NULL; + gops->ltc.init_fs_state = gm20b_ltc_init_fs_state; } -- cgit v1.2.2 From 7f7bf15564ad6a1198807e10bab156337f9dde9b Mon Sep 17 00:00:00 2001 From: David Nieto Date: Mon, 17 Oct 2016 13:39:56 -0700 Subject: gpu: nvgpu: fix sparse warning in LTC code bug 200088648 sparse warning reported that the function was not defined. This was due to a missing include Change-Id: Ia6153a2f3348a86e78add95bcfff998505b47cdd Signed-off-by: David Nieto Reviewed-on: http://git-master/r/1237845 Reviewed-by: Terje Bergstrom --- drivers/gpu/nvgpu/gp106/ltc_gp106.c | 1 + 1 file changed, 1 insertion(+) (limited to 'drivers/gpu/nvgpu/gp106/ltc_gp106.c') diff --git a/drivers/gpu/nvgpu/gp106/ltc_gp106.c b/drivers/gpu/nvgpu/gp106/ltc_gp106.c index dcd4fbad..b162ddb3 100644 --- a/drivers/gpu/nvgpu/gp106/ltc_gp106.c +++ b/drivers/gpu/nvgpu/gp106/ltc_gp106.c @@ -16,6 +16,7 @@ #include "gk20a/gk20a.h" #include "gm20b/ltc_gm20b.h" #include "gp10b/ltc_gp10b.h" +#include "gp106/ltc_gp106.h" void gp106_init_ltc(struct gpu_ops *gops) { -- cgit v1.2.2