gpu: nvgpu: Linux specific sm_error_state_record

Create an nvgpu internal nvgpu_gr_sm_error_state to store and
propagate SM error state within driver. Use
nvgpu_dbg_gpu_sm_error_state_record only in Linux code.

JIRA NVGPU-259

Change-Id: I7365cdf5a1a42cbcdb418dfcef3e0020e02a960f
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1585645
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Terje Bergstrom
2017-10-25 14:17:30 -07:00
committed by mobile promotions
parent 34ce21a588
commit 9eebb7831f
7 changed files with 48 additions and 27 deletions

View File

@@ -1543,7 +1543,7 @@ restore_fe_go_idle:
* we initialize gr->no_of_sm in this function
*/
gr->sm_error_states = nvgpu_kzalloc(g,
sizeof(struct nvgpu_dbg_gpu_sm_error_state_record)
sizeof(struct nvgpu_gr_sm_error_state)
* gr->no_of_sm);
if (!gr->sm_error_states) {
err = -ENOMEM;
@@ -4566,7 +4566,7 @@ restore_fe_go_idle:
* we initialize gr->no_of_sm in this function
*/
gr->sm_error_states = nvgpu_kzalloc(g,
sizeof(struct nvgpu_dbg_gpu_sm_error_state_record) *
sizeof(struct nvgpu_gr_sm_error_state) *
gr->no_of_sm);
if (!gr->sm_error_states) {
err = -ENOMEM;