diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/nvgpu/gp10b/ltc_gp10b.c | 29 |
1 files changed, 28 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/gp10b/ltc_gp10b.c b/drivers/gpu/nvgpu/gp10b/ltc_gp10b.c index beda3038..b32e2979 100644 --- a/drivers/gpu/nvgpu/gp10b/ltc_gp10b.c +++ b/drivers/gpu/nvgpu/gp10b/ltc_gp10b.c | |||
@@ -17,6 +17,8 @@ | |||
17 | 17 | ||
18 | #include "gk20a/gk20a.h" | 18 | #include "gk20a/gk20a.h" |
19 | #include "gm20b/ltc_gm20b.h" | 19 | #include "gm20b/ltc_gm20b.h" |
20 | #include "hw_proj_gp10b.h" | ||
21 | #include "hw_mc_gp10b.h" | ||
20 | #include "hw_ltc_gp10b.h" | 22 | #include "hw_ltc_gp10b.h" |
21 | 23 | ||
22 | #include "gk20a/ltc_common.c" | 24 | #include "gk20a/ltc_common.c" |
@@ -123,6 +125,31 @@ static int gp10b_ltc_init_comptags(struct gk20a *g, struct gr_gk20a *gr) | |||
123 | return 0; | 125 | return 0; |
124 | } | 126 | } |
125 | 127 | ||
128 | void gp10b_ltc_isr(struct gk20a *g) | ||
129 | { | ||
130 | u32 mc_intr, ltc_intr; | ||
131 | int ltc, slice; | ||
132 | |||
133 | mc_intr = gk20a_readl(g, mc_intr_ltc_r()); | ||
134 | gk20a_err(dev_from_gk20a(g), "mc_ltc_intr: %08x", | ||
135 | mc_intr); | ||
136 | for (ltc = 0; ltc < g->ltc_count; ltc++) { | ||
137 | if ((mc_intr & 1 << ltc) == 0) | ||
138 | continue; | ||
139 | for (slice = 0; slice < g->gr.slices_per_ltc; slice++) { | ||
140 | ltc_intr = gk20a_readl(g, ltc_ltc0_lts0_intr_r() + | ||
141 | proj_ltc_stride_v() * ltc + | ||
142 | proj_lts_stride_v() * slice); | ||
143 | gk20a_err(dev_from_gk20a(g), "ltc%d, slice %d: %08x", | ||
144 | ltc, slice, ltc_intr); | ||
145 | gk20a_writel(g, ltc_ltc0_lts0_intr_r() + | ||
146 | proj_ltc_stride_v() * ltc + | ||
147 | proj_lts_stride_v() * slice, | ||
148 | ltc_intr); | ||
149 | } | ||
150 | } | ||
151 | } | ||
152 | |||
126 | void gp10b_init_ltc(struct gpu_ops *gops) | 153 | void gp10b_init_ltc(struct gpu_ops *gops) |
127 | { | 154 | { |
128 | gops->ltc.determine_L2_size_bytes = gp10b_determine_L2_size_bytes; | 155 | gops->ltc.determine_L2_size_bytes = gp10b_determine_L2_size_bytes; |
@@ -136,7 +163,7 @@ void gp10b_init_ltc(struct gpu_ops *gops) | |||
136 | gops->ltc.init_comptags = gp10b_ltc_init_comptags; | 163 | gops->ltc.init_comptags = gp10b_ltc_init_comptags; |
137 | gops->ltc.cbc_ctrl = gm20b_ltc_cbc_ctrl; | 164 | gops->ltc.cbc_ctrl = gm20b_ltc_cbc_ctrl; |
138 | gops->ltc.elpg_flush = gm20b_ltc_g_elpg_flush_locked; | 165 | gops->ltc.elpg_flush = gm20b_ltc_g_elpg_flush_locked; |
139 | gops->ltc.isr = gm20b_ltc_isr; | 166 | gops->ltc.isr = gp10b_ltc_isr; |
140 | gops->ltc.cbc_fix_config = gm20b_ltc_cbc_fix_config; | 167 | gops->ltc.cbc_fix_config = gm20b_ltc_cbc_fix_config; |
141 | gops->ltc.flush = gm20b_flush_ltc; | 168 | gops->ltc.flush = gm20b_flush_ltc; |
142 | #ifdef CONFIG_DEBUG_FS | 169 | #ifdef CONFIG_DEBUG_FS |