summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gp10b/ltc_gp10b.c
diff options
context:
space:
mode:
authorDavid Nieto <dmartineznie@nvidia.com>2017-12-18 20:10:19 -0500
committermobile promotions <svcmobile_promotions@nvidia.com>2017-12-28 13:01:36 -0500
commit8fb6a8562ec033d2d1319f91377cd1782f593979 (patch)
tree07b7fe61cd9763ddf5cee2934994841fa330b90a /drivers/gpu/nvgpu/gp10b/ltc_gp10b.c
parentf19f22fcc8ef21b363b873c499cbd2e690af29f8 (diff)
gpu: nvgpu: gv11b: Report LTC errors per slice
Add support to report ltc ecc errors per slice (1) use new logic to detect subunits (2) store size of array and check before comparison to prevent out of bounds derefencing (3) use new hashing to prevent collisions or entries with permuted names bug 2037425 Change-Id: I63b9f0df43b9dceddc1bae17924c4723072f569e Signed-off-by: David Nieto <dmartineznie@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1620854 GVS: Gerrit_Virtual_Submit Reviewed-by: Chris Dragan <kdragan@nvidia.com> Tested-by: Chris Dragan <kdragan@nvidia.com> Reviewed-by: Nirav Patel <nipatel@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gp10b/ltc_gp10b.c')
-rw-r--r--drivers/gpu/nvgpu/gp10b/ltc_gp10b.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/gp10b/ltc_gp10b.c b/drivers/gpu/nvgpu/gp10b/ltc_gp10b.c
index 6e8a53c5..bf95f1fd 100644
--- a/drivers/gpu/nvgpu/gp10b/ltc_gp10b.c
+++ b/drivers/gpu/nvgpu/gp10b/ltc_gp10b.c
@@ -155,7 +155,7 @@ void gp10b_ltc_isr(struct gk20a *g)
155 ecc_stats_reg_val = 155 ecc_stats_reg_val =
156 gk20a_readl(g, 156 gk20a_readl(g,
157 ltc_ltc0_lts0_dstg_ecc_report_r() + offset); 157 ltc_ltc0_lts0_dstg_ecc_report_r() + offset);
158 g->ecc.ltc.l2_sec_count.counters[ltc] += 158 g->ecc.ltc.l2_sec_count.counters[ltc*g->ltc_count + slice] +=
159 ltc_ltc0_lts0_dstg_ecc_report_sec_count_v(ecc_stats_reg_val); 159 ltc_ltc0_lts0_dstg_ecc_report_sec_count_v(ecc_stats_reg_val);
160 ecc_stats_reg_val &= 160 ecc_stats_reg_val &=
161 ~(ltc_ltc0_lts0_dstg_ecc_report_sec_count_m()); 161 ~(ltc_ltc0_lts0_dstg_ecc_report_sec_count_m());
@@ -175,7 +175,7 @@ void gp10b_ltc_isr(struct gk20a *g)
175 ecc_stats_reg_val = 175 ecc_stats_reg_val =
176 gk20a_readl(g, 176 gk20a_readl(g,
177 ltc_ltc0_lts0_dstg_ecc_report_r() + offset); 177 ltc_ltc0_lts0_dstg_ecc_report_r() + offset);
178 g->ecc.ltc.l2_ded_count.counters[ltc] += 178 g->ecc.ltc.l2_ded_count.counters[ltc*g->ltc_count + slice] +=
179 ltc_ltc0_lts0_dstg_ecc_report_ded_count_v(ecc_stats_reg_val); 179 ltc_ltc0_lts0_dstg_ecc_report_ded_count_v(ecc_stats_reg_val);
180 ecc_stats_reg_val &= 180 ecc_stats_reg_val &=
181 ~(ltc_ltc0_lts0_dstg_ecc_report_ded_count_m()); 181 ~(ltc_ltc0_lts0_dstg_ecc_report_ded_count_m());