summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLakshmanan M <lm@nvidia.com>2017-05-10 04:52:15 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2017-05-18 12:04:34 -0400
commitb1d303685b384d58064d8b18ec97e1302bcbba88 (patch)
treefebc0226b712513b025afd78f5c898f41b4846d3
parent4d7711b076acf077b93b8cbac40ab0429b33fce6 (diff)
gpu: nvgpu: Add gr_t19x support for gv11b ECC
This CL covers the following modification, 1) Added gr_t19x support for gv11b ECC 2) Modified the gp10b platform config for gv11b sysfs support JIRA GPUT19X-85 JIRA GPUT19X-104 JIRA GPUT19X-100 JIRA GPUT19X-103 Bug 1825948 Bug 1825962 Bug 1775457 Change-Id: I0bf13f80a73cc2184147230d098e89a517554c01 Signed-off-by: Lakshmanan M <lm@nvidia.com> Reviewed-on: http://git-master/r/1478952 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
-rw-r--r--drivers/gpu/nvgpu/gk20a/gr_gk20a.h4
-rw-r--r--drivers/gpu/nvgpu/gp10b/gr_gp10b.h48
-rw-r--r--drivers/gpu/nvgpu/tegra/linux/platform_gp10b_tegra.c73
-rw-r--r--drivers/gpu/nvgpu/tegra/linux/platform_gp10b_tegra.h35
4 files changed, 100 insertions, 60 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.h b/drivers/gpu/nvgpu/gk20a/gr_gk20a.h
index ee528c31..5e49edb8 100644
--- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.h
+++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.h
@@ -374,6 +374,10 @@ struct gr_gk20a {
374#ifdef CONFIG_ARCH_TEGRA_18x_SOC 374#ifdef CONFIG_ARCH_TEGRA_18x_SOC
375 struct gr_t18x t18x; 375 struct gr_t18x t18x;
376#endif 376#endif
377#ifdef CONFIG_TEGRA_19x_GPU
378 struct gr_t19x t19x;
379#endif
380
377 u32 fbp_en_mask; 381 u32 fbp_en_mask;
378 u32 *fbp_rop_l2_en_mask; 382 u32 *fbp_rop_l2_en_mask;
379 u32 no_of_sm; 383 u32 no_of_sm;
diff --git a/drivers/gpu/nvgpu/gp10b/gr_gp10b.h b/drivers/gpu/nvgpu/gp10b/gr_gp10b.h
index c4c206c3..588a7d8f 100644
--- a/drivers/gpu/nvgpu/gp10b/gr_gp10b.h
+++ b/drivers/gpu/nvgpu/gp10b/gr_gp10b.h
@@ -22,6 +22,12 @@
22 22
23struct gpu_ops; 23struct gpu_ops;
24 24
25struct gr_gp10b_ecc_stat {
26 char **names;
27 u32 *counters;
28 struct hlist_node hash_node;
29};
30
25enum { 31enum {
26 PASCAL_CHANNEL_GPFIFO_A = 0xC06F, 32 PASCAL_CHANNEL_GPFIFO_A = 0xC06F,
27 PASCAL_A = 0xC097, 33 PASCAL_A = 0xC097,
@@ -45,12 +51,6 @@ int gr_gp10b_alloc_buffer(struct vm_gk20a *vm, size_t size,
45 struct nvgpu_mem *mem); 51 struct nvgpu_mem *mem);
46void gr_gp10b_create_sysfs(struct device *dev); 52void gr_gp10b_create_sysfs(struct device *dev);
47 53
48struct ecc_stat {
49 char **names;
50 u32 *counters;
51 struct hlist_node hash_node;
52};
53
54struct gr_t18x { 54struct gr_t18x {
55 struct { 55 struct {
56 u32 preempt_image_size; 56 u32 preempt_image_size;
@@ -69,24 +69,24 @@ struct gr_t18x {
69 } ctx_vars; 69 } ctx_vars;
70 70
71 struct { 71 struct {
72 struct ecc_stat sm_lrf_single_err_count; 72 struct gr_gp10b_ecc_stat sm_lrf_single_err_count;
73 struct ecc_stat sm_lrf_double_err_count; 73 struct gr_gp10b_ecc_stat sm_lrf_double_err_count;
74 74
75 struct ecc_stat sm_shm_sec_count; 75 struct gr_gp10b_ecc_stat sm_shm_sec_count;
76 struct ecc_stat sm_shm_sed_count; 76 struct gr_gp10b_ecc_stat sm_shm_sed_count;
77 struct ecc_stat sm_shm_ded_count; 77 struct gr_gp10b_ecc_stat sm_shm_ded_count;
78 78
79 struct ecc_stat tex_total_sec_pipe0_count; 79 struct gr_gp10b_ecc_stat tex_total_sec_pipe0_count;
80 struct ecc_stat tex_total_ded_pipe0_count; 80 struct gr_gp10b_ecc_stat tex_total_ded_pipe0_count;
81 struct ecc_stat tex_unique_sec_pipe0_count; 81 struct gr_gp10b_ecc_stat tex_unique_sec_pipe0_count;
82 struct ecc_stat tex_unique_ded_pipe0_count; 82 struct gr_gp10b_ecc_stat tex_unique_ded_pipe0_count;
83 struct ecc_stat tex_total_sec_pipe1_count; 83 struct gr_gp10b_ecc_stat tex_total_sec_pipe1_count;
84 struct ecc_stat tex_total_ded_pipe1_count; 84 struct gr_gp10b_ecc_stat tex_total_ded_pipe1_count;
85 struct ecc_stat tex_unique_sec_pipe1_count; 85 struct gr_gp10b_ecc_stat tex_unique_sec_pipe1_count;
86 struct ecc_stat tex_unique_ded_pipe1_count; 86 struct gr_gp10b_ecc_stat tex_unique_ded_pipe1_count;
87 87
88 struct ecc_stat l2_sec_count; 88 struct gr_gp10b_ecc_stat l2_sec_count;
89 struct ecc_stat l2_ded_count; 89 struct gr_gp10b_ecc_stat l2_ded_count;
90 } ecc_stats; 90 } ecc_stats;
91 91
92 u32 fecs_feature_override_ecc_val; 92 u32 fecs_feature_override_ecc_val;
diff --git a/drivers/gpu/nvgpu/tegra/linux/platform_gp10b_tegra.c b/drivers/gpu/nvgpu/tegra/linux/platform_gp10b_tegra.c
index 32cc80d9..1dedd593 100644
--- a/drivers/gpu/nvgpu/tegra/linux/platform_gp10b_tegra.c
+++ b/drivers/gpu/nvgpu/tegra/linux/platform_gp10b_tegra.c
@@ -39,6 +39,7 @@
39#include "platform_gk20a_tegra.h" 39#include "platform_gk20a_tegra.h"
40#include "gp10b/gp10b_sysfs.h" 40#include "gp10b/gp10b_sysfs.h"
41#include "gp10b/platform_gp10b.h" 41#include "gp10b/platform_gp10b.h"
42#include "platform_gp10b_tegra.h"
42 43
43#include <nvgpu/hw/gp10b/hw_gr_gp10b.h> 44#include <nvgpu/hw/gp10b/hw_gr_gp10b.h>
44#include <nvgpu/hw/gp10b/hw_ltc_gp10b.h> 45#include <nvgpu/hw/gp10b/hw_ltc_gp10b.h>
@@ -181,7 +182,7 @@ static int gp10b_tegra_late_probe(struct device *dev)
181 return 0; 182 return 0;
182} 183}
183 184
184static int gp10b_tegra_remove(struct device *dev) 185int gp10b_tegra_remove(struct device *dev)
185{ 186{
186 gr_gp10b_remove_sysfs(dev); 187 gr_gp10b_remove_sysfs(dev);
187 /*Remove GP10B specific sysfs*/ 188 /*Remove GP10B specific sysfs*/
@@ -483,7 +484,7 @@ static ssize_t ecc_stat_show(struct device *dev,
483 const char *ecc_stat_full_name = attr->attr.name; 484 const char *ecc_stat_full_name = attr->attr.name;
484 const char *ecc_stat_base_name; 485 const char *ecc_stat_base_name;
485 unsigned int hw_unit; 486 unsigned int hw_unit;
486 struct ecc_stat *ecc_stat; 487 struct gr_gp10b_ecc_stat *ecc_stat;
487 u32 hash_key; 488 u32 hash_key;
488 489
489 if (sscanf(ecc_stat_full_name, "ltc%u", &hw_unit) == 1) { 490 if (sscanf(ecc_stat_full_name, "ltc%u", &hw_unit) == 1) {
@@ -508,10 +509,10 @@ static ssize_t ecc_stat_show(struct device *dev,
508 return snprintf(buf, PAGE_SIZE, "Error: No ECC stat found!\n"); 509 return snprintf(buf, PAGE_SIZE, "Error: No ECC stat found!\n");
509} 510}
510 511
511static int ecc_stat_create(struct device *dev, 512int gr_gp10b_ecc_stat_create(struct device *dev,
512 int is_l2, 513 int is_l2,
513 char *ecc_stat_name, 514 char *ecc_stat_name,
514 struct ecc_stat *ecc_stat, 515 struct gr_gp10b_ecc_stat *ecc_stat,
515 struct device_attribute *dev_attr_array) 516 struct device_attribute *dev_attr_array)
516{ 517{
517 int error = 0; 518 int error = 0;
@@ -569,9 +570,9 @@ static int ecc_stat_create(struct device *dev,
569 return error; 570 return error;
570} 571}
571 572
572static void ecc_stat_remove(struct device *dev, 573void gr_gp10b_ecc_stat_remove(struct device *dev,
573 int is_l2, 574 int is_l2,
574 struct ecc_stat *ecc_stat, 575 struct gr_gp10b_ecc_stat *ecc_stat,
575 struct device_attribute *dev_attr_array) 576 struct device_attribute *dev_attr_array)
576{ 577{
577 struct gk20a *g = get_gk20a(dev); 578 struct gk20a *g = get_gk20a(dev);
@@ -612,80 +613,80 @@ void gr_gp10b_create_sysfs(struct device *dev)
612 if (g->gr.t18x.ecc_stats.sm_lrf_single_err_count.counters != NULL) 613 if (g->gr.t18x.ecc_stats.sm_lrf_single_err_count.counters != NULL)
613 return; 614 return;
614 615
615 error |= ecc_stat_create(dev, 616 error |= gr_gp10b_ecc_stat_create(dev,
616 0, 617 0,
617 "sm_lrf_ecc_single_err_count", 618 "sm_lrf_ecc_single_err_count",
618 &g->gr.t18x.ecc_stats.sm_lrf_single_err_count, 619 &g->gr.t18x.ecc_stats.sm_lrf_single_err_count,
619 dev_attr_sm_lrf_ecc_single_err_count_array); 620 dev_attr_sm_lrf_ecc_single_err_count_array);
620 error |= ecc_stat_create(dev, 621 error |= gr_gp10b_ecc_stat_create(dev,
621 0, 622 0,
622 "sm_lrf_ecc_double_err_count", 623 "sm_lrf_ecc_double_err_count",
623 &g->gr.t18x.ecc_stats.sm_lrf_double_err_count, 624 &g->gr.t18x.ecc_stats.sm_lrf_double_err_count,
624 dev_attr_sm_lrf_ecc_double_err_count_array); 625 dev_attr_sm_lrf_ecc_double_err_count_array);
625 626
626 error |= ecc_stat_create(dev, 627 error |= gr_gp10b_ecc_stat_create(dev,
627 0, 628 0,
628 "sm_shm_ecc_sec_count", 629 "sm_shm_ecc_sec_count",
629 &g->gr.t18x.ecc_stats.sm_shm_sec_count, 630 &g->gr.t18x.ecc_stats.sm_shm_sec_count,
630 dev_attr_sm_shm_ecc_sec_count_array); 631 dev_attr_sm_shm_ecc_sec_count_array);
631 error |= ecc_stat_create(dev, 632 error |= gr_gp10b_ecc_stat_create(dev,
632 0, 633 0,
633 "sm_shm_ecc_sed_count", 634 "sm_shm_ecc_sed_count",
634 &g->gr.t18x.ecc_stats.sm_shm_sed_count, 635 &g->gr.t18x.ecc_stats.sm_shm_sed_count,
635 dev_attr_sm_shm_ecc_sed_count_array); 636 dev_attr_sm_shm_ecc_sed_count_array);
636 error |= ecc_stat_create(dev, 637 error |= gr_gp10b_ecc_stat_create(dev,
637 0, 638 0,
638 "sm_shm_ecc_ded_count", 639 "sm_shm_ecc_ded_count",
639 &g->gr.t18x.ecc_stats.sm_shm_ded_count, 640 &g->gr.t18x.ecc_stats.sm_shm_ded_count,
640 dev_attr_sm_shm_ecc_ded_count_array); 641 dev_attr_sm_shm_ecc_ded_count_array);
641 642
642 error |= ecc_stat_create(dev, 643 error |= gr_gp10b_ecc_stat_create(dev,
643 0, 644 0,
644 "tex_ecc_total_sec_pipe0_count", 645 "tex_ecc_total_sec_pipe0_count",
645 &g->gr.t18x.ecc_stats.tex_total_sec_pipe0_count, 646 &g->gr.t18x.ecc_stats.tex_total_sec_pipe0_count,
646 dev_attr_tex_ecc_total_sec_pipe0_count_array); 647 dev_attr_tex_ecc_total_sec_pipe0_count_array);
647 error |= ecc_stat_create(dev, 648 error |= gr_gp10b_ecc_stat_create(dev,
648 0, 649 0,
649 "tex_ecc_total_ded_pipe0_count", 650 "tex_ecc_total_ded_pipe0_count",
650 &g->gr.t18x.ecc_stats.tex_total_ded_pipe0_count, 651 &g->gr.t18x.ecc_stats.tex_total_ded_pipe0_count,
651 dev_attr_tex_ecc_total_ded_pipe0_count_array); 652 dev_attr_tex_ecc_total_ded_pipe0_count_array);
652 error |= ecc_stat_create(dev, 653 error |= gr_gp10b_ecc_stat_create(dev,
653 0, 654 0,
654 "tex_ecc_unique_sec_pipe0_count", 655 "tex_ecc_unique_sec_pipe0_count",
655 &g->gr.t18x.ecc_stats.tex_unique_sec_pipe0_count, 656 &g->gr.t18x.ecc_stats.tex_unique_sec_pipe0_count,
656 dev_attr_tex_ecc_unique_sec_pipe0_count_array); 657 dev_attr_tex_ecc_unique_sec_pipe0_count_array);
657 error |= ecc_stat_create(dev, 658 error |= gr_gp10b_ecc_stat_create(dev,
658 0, 659 0,
659 "tex_ecc_unique_ded_pipe0_count", 660 "tex_ecc_unique_ded_pipe0_count",
660 &g->gr.t18x.ecc_stats.tex_unique_ded_pipe0_count, 661 &g->gr.t18x.ecc_stats.tex_unique_ded_pipe0_count,
661 dev_attr_tex_ecc_unique_ded_pipe0_count_array); 662 dev_attr_tex_ecc_unique_ded_pipe0_count_array);
662 error |= ecc_stat_create(dev, 663 error |= gr_gp10b_ecc_stat_create(dev,
663 0, 664 0,
664 "tex_ecc_total_sec_pipe1_count", 665 "tex_ecc_total_sec_pipe1_count",
665 &g->gr.t18x.ecc_stats.tex_total_sec_pipe1_count, 666 &g->gr.t18x.ecc_stats.tex_total_sec_pipe1_count,
666 dev_attr_tex_ecc_total_sec_pipe1_count_array); 667 dev_attr_tex_ecc_total_sec_pipe1_count_array);
667 error |= ecc_stat_create(dev, 668 error |= gr_gp10b_ecc_stat_create(dev,
668 0, 669 0,
669 "tex_ecc_total_ded_pipe1_count", 670 "tex_ecc_total_ded_pipe1_count",
670 &g->gr.t18x.ecc_stats.tex_total_ded_pipe1_count, 671 &g->gr.t18x.ecc_stats.tex_total_ded_pipe1_count,
671 dev_attr_tex_ecc_total_ded_pipe1_count_array); 672 dev_attr_tex_ecc_total_ded_pipe1_count_array);
672 error |= ecc_stat_create(dev, 673 error |= gr_gp10b_ecc_stat_create(dev,
673 0, 674 0,
674 "tex_ecc_unique_sec_pipe1_count", 675 "tex_ecc_unique_sec_pipe1_count",
675 &g->gr.t18x.ecc_stats.tex_unique_sec_pipe1_count, 676 &g->gr.t18x.ecc_stats.tex_unique_sec_pipe1_count,
676 dev_attr_tex_ecc_unique_sec_pipe1_count_array); 677 dev_attr_tex_ecc_unique_sec_pipe1_count_array);
677 error |= ecc_stat_create(dev, 678 error |= gr_gp10b_ecc_stat_create(dev,
678 0, 679 0,
679 "tex_ecc_unique_ded_pipe1_count", 680 "tex_ecc_unique_ded_pipe1_count",
680 &g->gr.t18x.ecc_stats.tex_unique_ded_pipe1_count, 681 &g->gr.t18x.ecc_stats.tex_unique_ded_pipe1_count,
681 dev_attr_tex_ecc_unique_ded_pipe1_count_array); 682 dev_attr_tex_ecc_unique_ded_pipe1_count_array);
682 683
683 error |= ecc_stat_create(dev, 684 error |= gr_gp10b_ecc_stat_create(dev,
684 1, 685 1,
685 "lts0_ecc_sec_count", 686 "lts0_ecc_sec_count",
686 &g->gr.t18x.ecc_stats.l2_sec_count, 687 &g->gr.t18x.ecc_stats.l2_sec_count,
687 dev_attr_l2_ecc_sec_count_array); 688 dev_attr_l2_ecc_sec_count_array);
688 error |= ecc_stat_create(dev, 689 error |= gr_gp10b_ecc_stat_create(dev,
689 1, 690 1,
690 "lts0_ecc_ded_count", 691 "lts0_ecc_ded_count",
691 &g->gr.t18x.ecc_stats.l2_ded_count, 692 &g->gr.t18x.ecc_stats.l2_ded_count,
@@ -699,66 +700,66 @@ static void gr_gp10b_remove_sysfs(struct device *dev)
699{ 700{
700 struct gk20a *g = get_gk20a(dev); 701 struct gk20a *g = get_gk20a(dev);
701 702
702 ecc_stat_remove(dev, 703 gr_gp10b_ecc_stat_remove(dev,
703 0, 704 0,
704 &g->gr.t18x.ecc_stats.sm_lrf_single_err_count, 705 &g->gr.t18x.ecc_stats.sm_lrf_single_err_count,
705 dev_attr_sm_lrf_ecc_single_err_count_array); 706 dev_attr_sm_lrf_ecc_single_err_count_array);
706 ecc_stat_remove(dev, 707 gr_gp10b_ecc_stat_remove(dev,
707 0, 708 0,
708 &g->gr.t18x.ecc_stats.sm_lrf_double_err_count, 709 &g->gr.t18x.ecc_stats.sm_lrf_double_err_count,
709 dev_attr_sm_lrf_ecc_double_err_count_array); 710 dev_attr_sm_lrf_ecc_double_err_count_array);
710 711
711 ecc_stat_remove(dev, 712 gr_gp10b_ecc_stat_remove(dev,
712 0, 713 0,
713 &g->gr.t18x.ecc_stats.sm_shm_sec_count, 714 &g->gr.t18x.ecc_stats.sm_shm_sec_count,
714 dev_attr_sm_shm_ecc_sec_count_array); 715 dev_attr_sm_shm_ecc_sec_count_array);
715 ecc_stat_remove(dev, 716 gr_gp10b_ecc_stat_remove(dev,
716 0, 717 0,
717 &g->gr.t18x.ecc_stats.sm_shm_sed_count, 718 &g->gr.t18x.ecc_stats.sm_shm_sed_count,
718 dev_attr_sm_shm_ecc_sed_count_array); 719 dev_attr_sm_shm_ecc_sed_count_array);
719 ecc_stat_remove(dev, 720 gr_gp10b_ecc_stat_remove(dev,
720 0, 721 0,
721 &g->gr.t18x.ecc_stats.sm_shm_ded_count, 722 &g->gr.t18x.ecc_stats.sm_shm_ded_count,
722 dev_attr_sm_shm_ecc_ded_count_array); 723 dev_attr_sm_shm_ecc_ded_count_array);
723 724
724 ecc_stat_remove(dev, 725 gr_gp10b_ecc_stat_remove(dev,
725 0, 726 0,
726 &g->gr.t18x.ecc_stats.tex_total_sec_pipe0_count, 727 &g->gr.t18x.ecc_stats.tex_total_sec_pipe0_count,
727 dev_attr_tex_ecc_total_sec_pipe0_count_array); 728 dev_attr_tex_ecc_total_sec_pipe0_count_array);
728 ecc_stat_remove(dev, 729 gr_gp10b_ecc_stat_remove(dev,
729 0, 730 0,
730 &g->gr.t18x.ecc_stats.tex_total_ded_pipe0_count, 731 &g->gr.t18x.ecc_stats.tex_total_ded_pipe0_count,
731 dev_attr_tex_ecc_total_ded_pipe0_count_array); 732 dev_attr_tex_ecc_total_ded_pipe0_count_array);
732 ecc_stat_remove(dev, 733 gr_gp10b_ecc_stat_remove(dev,
733 0, 734 0,
734 &g->gr.t18x.ecc_stats.tex_unique_sec_pipe0_count, 735 &g->gr.t18x.ecc_stats.tex_unique_sec_pipe0_count,
735 dev_attr_tex_ecc_unique_sec_pipe0_count_array); 736 dev_attr_tex_ecc_unique_sec_pipe0_count_array);
736 ecc_stat_remove(dev, 737 gr_gp10b_ecc_stat_remove(dev,
737 0, 738 0,
738 &g->gr.t18x.ecc_stats.tex_unique_ded_pipe0_count, 739 &g->gr.t18x.ecc_stats.tex_unique_ded_pipe0_count,
739 dev_attr_tex_ecc_unique_ded_pipe0_count_array); 740 dev_attr_tex_ecc_unique_ded_pipe0_count_array);
740 ecc_stat_remove(dev, 741 gr_gp10b_ecc_stat_remove(dev,
741 0, 742 0,
742 &g->gr.t18x.ecc_stats.tex_total_sec_pipe1_count, 743 &g->gr.t18x.ecc_stats.tex_total_sec_pipe1_count,
743 dev_attr_tex_ecc_total_sec_pipe1_count_array); 744 dev_attr_tex_ecc_total_sec_pipe1_count_array);
744 ecc_stat_remove(dev, 745 gr_gp10b_ecc_stat_remove(dev,
745 0, 746 0,
746 &g->gr.t18x.ecc_stats.tex_total_ded_pipe1_count, 747 &g->gr.t18x.ecc_stats.tex_total_ded_pipe1_count,
747 dev_attr_tex_ecc_total_ded_pipe1_count_array); 748 dev_attr_tex_ecc_total_ded_pipe1_count_array);
748 ecc_stat_remove(dev, 749 gr_gp10b_ecc_stat_remove(dev,
749 0, 750 0,
750 &g->gr.t18x.ecc_stats.tex_unique_sec_pipe1_count, 751 &g->gr.t18x.ecc_stats.tex_unique_sec_pipe1_count,
751 dev_attr_tex_ecc_unique_sec_pipe1_count_array); 752 dev_attr_tex_ecc_unique_sec_pipe1_count_array);
752 ecc_stat_remove(dev, 753 gr_gp10b_ecc_stat_remove(dev,
753 0, 754 0,
754 &g->gr.t18x.ecc_stats.tex_unique_ded_pipe1_count, 755 &g->gr.t18x.ecc_stats.tex_unique_ded_pipe1_count,
755 dev_attr_tex_ecc_unique_ded_pipe1_count_array); 756 dev_attr_tex_ecc_unique_ded_pipe1_count_array);
756 757
757 ecc_stat_remove(dev, 758 gr_gp10b_ecc_stat_remove(dev,
758 1, 759 1,
759 &g->gr.t18x.ecc_stats.l2_sec_count, 760 &g->gr.t18x.ecc_stats.l2_sec_count,
760 dev_attr_l2_ecc_sec_count_array); 761 dev_attr_l2_ecc_sec_count_array);
761 ecc_stat_remove(dev, 762 gr_gp10b_ecc_stat_remove(dev,
762 1, 763 1,
763 &g->gr.t18x.ecc_stats.l2_ded_count, 764 &g->gr.t18x.ecc_stats.l2_ded_count,
764 dev_attr_l2_ecc_ded_count_array); 765 dev_attr_l2_ecc_ded_count_array);
diff --git a/drivers/gpu/nvgpu/tegra/linux/platform_gp10b_tegra.h b/drivers/gpu/nvgpu/tegra/linux/platform_gp10b_tegra.h
new file mode 100644
index 00000000..0fcb9f39
--- /dev/null
+++ b/drivers/gpu/nvgpu/tegra/linux/platform_gp10b_tegra.h
@@ -0,0 +1,35 @@
1/*
2 * Copyright (c) 2017, NVIDIA CORPORATION. All rights reserved.
3 *
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms and conditions of the GNU General Public License,
6 * version 2, as published by the Free Software Foundation.
7 *
8 * This program is distributed in the hope it will be useful, but WITHOUT
9 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
10 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
11 * more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16
17#ifndef _PLATFORM_GP10B_TEGRA_H_
18#define _PLATFORM_GP10B_TEGRA_H_
19
20#include "gp10b/gr_gp10b.h"
21
22int gr_gp10b_ecc_stat_create(struct device *dev,
23 int is_l2,
24 char *ecc_stat_name,
25 struct gr_gp10b_ecc_stat *ecc_stat,
26 struct device_attribute *dev_attr_array);
27
28void gr_gp10b_ecc_stat_remove(struct device *dev,
29 int is_l2,
30 struct gr_gp10b_ecc_stat *ecc_stat,
31 struct device_attribute *dev_attr_array);
32
33int gp10b_tegra_remove(struct device *dev);
34
35#endif