From 258ae4471296bcee03987778e3b7c79d3a027e53 Mon Sep 17 00:00:00 2001 From: David Nieto Date: Tue, 5 Dec 2017 15:20:18 -0800 Subject: gpu: nvgpu: gv11b: PMU parity HWW ECC support Adding support for ISR handling of ECC parity errors for PMU unit and setting the initial IRQDST mask to deliver ECC interrupts to host in the non-stall PMU irq path JIRA: GPUT19X-83 Change-Id: I8efae6777811893ecce79d0e32ba81b62c27b1ef Signed-off-by: David Nieto Signed-off-by: Richard Zhao Reviewed-on: https://git-master.nvidia.com/r/1611625 Reviewed-by: mobile promotions Tested-by: mobile promotions --- .../gpu/nvgpu/common/linux/platform_gv11b_tegra.c | 28 ++++++++++++++++++++++ 1 file changed, 28 insertions(+) (limited to 'drivers/gpu/nvgpu/common/linux/platform_gv11b_tegra.c') diff --git a/drivers/gpu/nvgpu/common/linux/platform_gv11b_tegra.c b/drivers/gpu/nvgpu/common/linux/platform_gv11b_tegra.c index 3c6eac77..a2a60aaa 100644 --- a/drivers/gpu/nvgpu/common/linux/platform_gv11b_tegra.c +++ b/drivers/gpu/nvgpu/common/linux/platform_gv11b_tegra.c @@ -243,6 +243,9 @@ static struct device_attribute *dev_attr_mmu_hubtlb_ecc_uncorrected_err_count_ar static struct device_attribute *dev_attr_mmu_fillunit_ecc_corrected_err_count_array; static struct device_attribute *dev_attr_mmu_fillunit_ecc_uncorrected_err_count_array; +static struct device_attribute *dev_attr_pmu_ecc_corrected_err_count_array; +static struct device_attribute *dev_attr_pmu_ecc_uncorrected_err_count_array; + void gr_gv11b_create_sysfs(struct gk20a *g) { struct device *dev = dev_from_gk20a(g); @@ -414,6 +417,21 @@ void gr_gv11b_create_sysfs(struct gk20a *g) &g->ecc.eng.t19x.mmu_fillunit_corrected_err_count, &dev_attr_mmu_fillunit_ecc_corrected_err_count_array); + error |= gp10b_ecc_stat_create(dev, + 1, + "eng", + "pmu_ecc_uncorrected_err_count", + &g->ecc.eng.t19x.pmu_uncorrected_err_count, + &dev_attr_pmu_ecc_uncorrected_err_count_array); + + error |= gp10b_ecc_stat_create(dev, + 1, + "eng", + "pmu_ecc_corrected_err_count", + &g->ecc.eng.t19x.pmu_corrected_err_count, + &dev_attr_pmu_ecc_corrected_err_count_array); + + if (error) dev_err(dev, "Failed to create gv11b sysfs attributes!\n"); } @@ -541,4 +559,14 @@ static void gr_gv11b_remove_sysfs(struct device *dev) 1, &g->ecc.eng.t19x.mmu_fillunit_corrected_err_count, dev_attr_mmu_fillunit_ecc_corrected_err_count_array); + + gp10b_ecc_stat_remove(dev, + 1, + &g->ecc.eng.t19x.pmu_uncorrected_err_count, + dev_attr_pmu_ecc_uncorrected_err_count_array); + + gp10b_ecc_stat_remove(dev, + 1, + &g->ecc.eng.t19x.pmu_corrected_err_count, + dev_attr_pmu_ecc_corrected_err_count_array); } -- cgit v1.2.2