diff options
author | Arto Merilainen <amerilainen@nvidia.com> | 2014-07-31 06:35:48 -0400 |
---|---|---|
committer | Dan Willemsen <dwillemsen@nvidia.com> | 2015-03-18 15:10:41 -0400 |
commit | 4df9290536dc02250eac2abbf0d4dc5d27f0edcc (patch) | |
tree | bc42b05039c5c2e680459f8f241a75f3e8d9a63c /drivers/gpu | |
parent | e51f76f1c0f8fa4affb5fac538df12a83095721d (diff) |
gpu: nvgpu: Fix compbit base calculation
Compression bit base was calculated incorrectly in cases where
number of LTCs was not 1. This patch fixes the code.
Change-Id: I25e3fa7446b238202d93ce8a72ed919d11fb6e30
Signed-off-by: Arto Merilainen <amerilainen@nvidia.com>
Reviewed-on: http://git-master/r/449281
Reviewed-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
Tested-by: Jussi Rasanen <jrasanen@nvidia.com>
GVS: Gerrit_Virtual_Submit
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/ltc_common.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/ltc_common.c b/drivers/gpu/nvgpu/gk20a/ltc_common.c index 7d160efb..55e822f6 100644 --- a/drivers/gpu/nvgpu/gk20a/ltc_common.c +++ b/drivers/gpu/nvgpu/gk20a/ltc_common.c | |||
@@ -242,7 +242,7 @@ static void gk20a_ltc_init_cbc(struct gk20a *g, struct gr_gk20a *gr) | |||
242 | compbit_base_post_divide = u64_lo32(compbit_base_post_divide64); | 242 | compbit_base_post_divide = u64_lo32(compbit_base_post_divide64); |
243 | 243 | ||
244 | compbit_base_post_multiply64 = ((u64)compbit_base_post_divide * | 244 | compbit_base_post_multiply64 = ((u64)compbit_base_post_divide * |
245 | gr->num_fbps) << ltc_ltcs_ltss_cbc_base_alignment_shift_v(); | 245 | g->ltc_count) << ltc_ltcs_ltss_cbc_base_alignment_shift_v(); |
246 | 246 | ||
247 | if (compbit_base_post_multiply64 < compbit_store_base_iova) | 247 | if (compbit_base_post_multiply64 < compbit_store_base_iova) |
248 | compbit_base_post_divide++; | 248 | compbit_base_post_divide++; |