mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-24 02:22:34 +03:00
gpu: nvgpu: Create CIC-mon and CIC-rm subunits
common.cic unit is divided into common.cic.mon and common.cic.rm based on rm and mon process split. CIC-mon subunit includes the code which is utilized in critical interrupt handling path like initialization, error detection and error reporting path. CIC-rm subunit includes the code corresponding to rest of interrupt handling(like collecting error debug data from registers) and ISR status management (status of deferred interrupts). Split the CIC APIs and data-members into above two subunits. JIRA NVGPU-6899 Change-Id: I151b59105ff570607c4a62e974785e9c1323ef69 Signed-off-by: Tejal Kudav <tkudav@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2551897 Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
8ccf9820ba
commit
0526e7eaa9
@@ -26,9 +26,9 @@
|
||||
|
||||
#include <nvgpu/gk20a.h>
|
||||
#include <nvgpu/ptimer.h>
|
||||
#include <nvgpu/cic.h>
|
||||
#include <nvgpu/cic_mon.h>
|
||||
#include <hal/ptimer/ptimer_gk20a.h>
|
||||
#include <hal/cic/cic_gv11b.h>
|
||||
#include <hal/cic/mon/cic_gv11b.h>
|
||||
#include <nvgpu/hw/gk20a/hw_timer_gk20a.h>
|
||||
|
||||
#include "nvgpu-ptimer.h"
|
||||
@@ -90,8 +90,8 @@ int test_setup_env(struct unit_module *m,
|
||||
g->ops.ptimer.read_ptimer = gk20a_read_ptimer;
|
||||
g->ops.ptimer.isr = gk20a_ptimer_isr;
|
||||
|
||||
g->ops.cic.init = gv11b_cic_init;
|
||||
g->ops.cic.report_err = nvgpu_cic_report_err_safety_services;
|
||||
g->ops.cic_mon.init = gv11b_cic_mon_init;
|
||||
g->ops.cic_mon.report_err = nvgpu_cic_mon_report_err_safety_services;
|
||||
|
||||
/* Create ptimer register space */
|
||||
if (nvgpu_posix_io_add_reg_space(g, PTIMER_REG_SPACE_START,
|
||||
@@ -102,12 +102,18 @@ int test_setup_env(struct unit_module *m,
|
||||
}
|
||||
(void)nvgpu_posix_register_io(g, &test_reg_callbacks);
|
||||
|
||||
if (nvgpu_cic_init_common(g) != 0) {
|
||||
if (nvgpu_cic_mon_setup(g) != 0) {
|
||||
unit_err(m, "%s: failed to initialize CIC\n",
|
||||
__func__);
|
||||
return UNIT_FAIL;
|
||||
}
|
||||
|
||||
if (nvgpu_cic_mon_init_lut(g) != 0) {
|
||||
unit_err(m, "%s: failed to initialize CIC LUT\n",
|
||||
__func__);
|
||||
return UNIT_FAIL;
|
||||
}
|
||||
|
||||
return UNIT_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user