diff options
author | Thomas Fleury <tfleury@nvidia.com> | 2016-03-23 19:49:36 -0400 |
---|---|---|
committer | Terje Bergstrom <tbergstrom@nvidia.com> | 2016-04-07 16:17:30 -0400 |
commit | 11f11a6c0d3ba9acdab21dcb4ea3f6b4c6518693 (patch) | |
tree | d1e38361153973522db21bd340e10432e1e92324 /drivers/gpu | |
parent | cefc747ba2cdf6ccb98ecf18e63b6911db3be019 (diff) |
gpu: nvgpu: fix zcb_count
gr_gk20a_init_gr_config may be invoked several times
if gr->sw_ready is reset. Need to clear zcb_count before
summing gpc_zcb_count[gpc] to avoid ever incrementing count
Change-Id: If3bfa47ed807a3e9a5dc31f7f7f96f0c6e1fed08
Signed-off-by: Thomas Fleury <tfleury@nvidia.com>
Reviewed-on: http://git-master/r/1120772
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gr_gk20a.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c index a8addc7b..cc3a6813 100644 --- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c | |||
@@ -3242,6 +3242,7 @@ static int gr_gk20a_init_gr_config(struct gk20a *g, struct gr_gk20a *gr) | |||
3242 | 3242 | ||
3243 | gr->ppc_count = 0; | 3243 | gr->ppc_count = 0; |
3244 | gr->tpc_count = 0; | 3244 | gr->tpc_count = 0; |
3245 | gr->zcb_count = 0; | ||
3245 | for (gpc_index = 0; gpc_index < gr->gpc_count; gpc_index++) { | 3246 | for (gpc_index = 0; gpc_index < gr->gpc_count; gpc_index++) { |
3246 | tmp = gk20a_readl(g, gr_gpc0_fs_gpc_r()); | 3247 | tmp = gk20a_readl(g, gr_gpc0_fs_gpc_r()); |
3247 | 3248 | ||