1 #define NVOC_KERNEL_CRASHCAT_ENGINE_H_PRIVATE_ACCESS_ALLOWED
2 #include "nvoc/runtime.h"
3 #include "nvoc/rtti.h"
4 #include "nvtypes.h"
5 #include "nvport/nvport.h"
6 #include "nvport/inline/util_valist.h"
7 #include "utils/nvassert.h"
8 #include "g_kernel_crashcat_engine_nvoc.h"
9
10 #ifdef DEBUG
11 char __nvoc_class_id_uniqueness_check_0xc37aef = 1;
12 #endif
13
14 extern const struct NVOC_CLASS_DEF __nvoc_class_def_KernelCrashCatEngine;
15
16 extern const struct NVOC_CLASS_DEF __nvoc_class_def_CrashCatEngine;
17
18 void __nvoc_init_KernelCrashCatEngine(KernelCrashCatEngine*, RmHalspecOwner* );
19 void __nvoc_init_funcTable_KernelCrashCatEngine(KernelCrashCatEngine*, RmHalspecOwner* );
20 NV_STATUS __nvoc_ctor_KernelCrashCatEngine(KernelCrashCatEngine*, RmHalspecOwner* );
21 void __nvoc_init_dataField_KernelCrashCatEngine(KernelCrashCatEngine*, RmHalspecOwner* );
22 void __nvoc_dtor_KernelCrashCatEngine(KernelCrashCatEngine*);
23 extern const struct NVOC_EXPORT_INFO __nvoc_export_info_KernelCrashCatEngine;
24
25 static const struct NVOC_RTTI __nvoc_rtti_KernelCrashCatEngine_KernelCrashCatEngine = {
26 /*pClassDef=*/ &__nvoc_class_def_KernelCrashCatEngine,
27 /*dtor=*/ (NVOC_DYNAMIC_DTOR) &__nvoc_dtor_KernelCrashCatEngine,
28 /*offset=*/ 0,
29 };
30
31 static const struct NVOC_RTTI __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine = {
32 /*pClassDef=*/ &__nvoc_class_def_CrashCatEngine,
33 /*dtor=*/ &__nvoc_destructFromBase,
34 /*offset=*/ NV_OFFSETOF(KernelCrashCatEngine, __nvoc_base_CrashCatEngine),
35 };
36
37 static const struct NVOC_CASTINFO __nvoc_castinfo_KernelCrashCatEngine = {
38 /*numRelatives=*/ 2,
39 /*relatives=*/ {
40 &__nvoc_rtti_KernelCrashCatEngine_KernelCrashCatEngine,
41 &__nvoc_rtti_KernelCrashCatEngine_CrashCatEngine,
42 },
43 };
44
45 // Not instantiable because it's not derived from class "Object"
46 // Not instantiable because it's an abstract class with following pure virtual functions:
47 // kcrashcatEngineRegRead
48 // kcrashcatEngineRegWrite
49 // kcrashcatEngineMaskDmemAddr
50 const struct NVOC_CLASS_DEF __nvoc_class_def_KernelCrashCatEngine =
51 {
52 /*classInfo=*/ {
53 /*size=*/ sizeof(KernelCrashCatEngine),
54 /*classId=*/ classId(KernelCrashCatEngine),
55 /*providerId=*/ &__nvoc_rtti_provider,
56 #if NV_PRINTF_STRINGS_ALLOWED
57 /*name=*/ "KernelCrashCatEngine",
58 #endif
59 },
60 /*objCreatefn=*/ (NVOC_DYNAMIC_OBJ_CREATE) NULL,
61 /*pCastInfo=*/ &__nvoc_castinfo_KernelCrashCatEngine,
62 /*pExportInfo=*/ &__nvoc_export_info_KernelCrashCatEngine
63 };
64
__nvoc_thunk_KernelCrashCatEngine_crashcatEngineConfigured(struct CrashCatEngine * arg0)65 static NvBool __nvoc_thunk_KernelCrashCatEngine_crashcatEngineConfigured(struct CrashCatEngine *arg0) {
66 return kcrashcatEngineConfigured((struct KernelCrashCatEngine *)(((unsigned char *)arg0) - __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine.offset));
67 }
68
__nvoc_thunk_KernelCrashCatEngine_crashcatEngineUnload(struct CrashCatEngine * arg0)69 static void __nvoc_thunk_KernelCrashCatEngine_crashcatEngineUnload(struct CrashCatEngine *arg0) {
70 kcrashcatEngineUnload((struct KernelCrashCatEngine *)(((unsigned char *)arg0) - __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine.offset));
71 }
72
__nvoc_thunk_KernelCrashCatEngine_crashcatEngineVprintf(struct CrashCatEngine * arg0,NvBool bReportStart,const char * fmt,va_list args)73 static void __nvoc_thunk_KernelCrashCatEngine_crashcatEngineVprintf(struct CrashCatEngine *arg0, NvBool bReportStart, const char *fmt, va_list args) {
74 kcrashcatEngineVprintf((struct KernelCrashCatEngine *)(((unsigned char *)arg0) - __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine.offset), bReportStart, fmt, args);
75 }
76
__nvoc_thunk_KernelCrashCatEngine_crashcatEnginePriRead(struct CrashCatEngine * arg0,NvU32 offset)77 static NvU32 __nvoc_thunk_KernelCrashCatEngine_crashcatEnginePriRead(struct CrashCatEngine *arg0, NvU32 offset) {
78 return kcrashcatEnginePriRead((struct KernelCrashCatEngine *)(((unsigned char *)arg0) - __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine.offset), offset);
79 }
80
__nvoc_thunk_KernelCrashCatEngine_crashcatEnginePriWrite(struct CrashCatEngine * arg0,NvU32 offset,NvU32 data)81 static void __nvoc_thunk_KernelCrashCatEngine_crashcatEnginePriWrite(struct CrashCatEngine *arg0, NvU32 offset, NvU32 data) {
82 kcrashcatEnginePriWrite((struct KernelCrashCatEngine *)(((unsigned char *)arg0) - __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine.offset), offset, data);
83 }
84
__nvoc_thunk_KernelCrashCatEngine_crashcatEngineMapBufferDescriptor(struct CrashCatEngine * arg0,CrashCatBufferDescriptor * pBufDesc)85 static void *__nvoc_thunk_KernelCrashCatEngine_crashcatEngineMapBufferDescriptor(struct CrashCatEngine *arg0, CrashCatBufferDescriptor *pBufDesc) {
86 return kcrashcatEngineMapBufferDescriptor((struct KernelCrashCatEngine *)(((unsigned char *)arg0) - __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine.offset), pBufDesc);
87 }
88
__nvoc_thunk_KernelCrashCatEngine_crashcatEngineUnmapBufferDescriptor(struct CrashCatEngine * arg0,CrashCatBufferDescriptor * pBufDesc)89 static void __nvoc_thunk_KernelCrashCatEngine_crashcatEngineUnmapBufferDescriptor(struct CrashCatEngine *arg0, CrashCatBufferDescriptor *pBufDesc) {
90 kcrashcatEngineUnmapBufferDescriptor((struct KernelCrashCatEngine *)(((unsigned char *)arg0) - __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine.offset), pBufDesc);
91 }
92
__nvoc_thunk_KernelCrashCatEngine_crashcatEngineSyncBufferDescriptor(struct CrashCatEngine * arg0,CrashCatBufferDescriptor * pBufDesc,NvU32 offset,NvU32 size)93 static void __nvoc_thunk_KernelCrashCatEngine_crashcatEngineSyncBufferDescriptor(struct CrashCatEngine *arg0, CrashCatBufferDescriptor *pBufDesc, NvU32 offset, NvU32 size) {
94 kcrashcatEngineSyncBufferDescriptor((struct KernelCrashCatEngine *)(((unsigned char *)arg0) - __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine.offset), pBufDesc, offset, size);
95 }
96
__nvoc_thunk_KernelCrashCatEngine_crashcatEngineGetScratchOffsets(struct CrashCatEngine * arg0,NV_CRASHCAT_SCRATCH_GROUP_ID scratchGroupId)97 static const NvU32 *__nvoc_thunk_KernelCrashCatEngine_crashcatEngineGetScratchOffsets(struct CrashCatEngine *arg0, NV_CRASHCAT_SCRATCH_GROUP_ID scratchGroupId) {
98 return kcrashcatEngineGetScratchOffsets((struct KernelCrashCatEngine *)(((unsigned char *)arg0) - __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine.offset), scratchGroupId);
99 }
100
__nvoc_thunk_KernelCrashCatEngine_crashcatEngineGetWFL0Offset(struct CrashCatEngine * arg0)101 static NvU32 __nvoc_thunk_KernelCrashCatEngine_crashcatEngineGetWFL0Offset(struct CrashCatEngine *arg0) {
102 return kcrashcatEngineGetWFL0Offset((struct KernelCrashCatEngine *)(((unsigned char *)arg0) - __nvoc_rtti_KernelCrashCatEngine_CrashCatEngine.offset));
103 }
104
105 const struct NVOC_EXPORT_INFO __nvoc_export_info_KernelCrashCatEngine =
106 {
107 /*numEntries=*/ 0,
108 /*pExportEntries=*/ 0
109 };
110
111 void __nvoc_dtor_CrashCatEngine(CrashCatEngine*);
__nvoc_dtor_KernelCrashCatEngine(KernelCrashCatEngine * pThis)112 void __nvoc_dtor_KernelCrashCatEngine(KernelCrashCatEngine *pThis) {
113 __nvoc_dtor_CrashCatEngine(&pThis->__nvoc_base_CrashCatEngine);
114 PORT_UNREFERENCED_VARIABLE(pThis);
115 }
116
__nvoc_init_dataField_KernelCrashCatEngine(KernelCrashCatEngine * pThis,RmHalspecOwner * pRmhalspecowner)117 void __nvoc_init_dataField_KernelCrashCatEngine(KernelCrashCatEngine *pThis, RmHalspecOwner *pRmhalspecowner) {
118 ChipHal *chipHal = &pRmhalspecowner->chipHal;
119 const unsigned long chipHal_HalVarIdx = (unsigned long)chipHal->__nvoc_HalVarIdx;
120 PORT_UNREFERENCED_VARIABLE(pThis);
121 PORT_UNREFERENCED_VARIABLE(pRmhalspecowner);
122 PORT_UNREFERENCED_VARIABLE(chipHal);
123 PORT_UNREFERENCED_VARIABLE(chipHal_HalVarIdx);
124 }
125
126 NV_STATUS __nvoc_ctor_CrashCatEngine(CrashCatEngine* );
__nvoc_ctor_KernelCrashCatEngine(KernelCrashCatEngine * pThis,RmHalspecOwner * pRmhalspecowner)127 NV_STATUS __nvoc_ctor_KernelCrashCatEngine(KernelCrashCatEngine *pThis, RmHalspecOwner *pRmhalspecowner) {
128 NV_STATUS status = NV_OK;
129 status = __nvoc_ctor_CrashCatEngine(&pThis->__nvoc_base_CrashCatEngine);
130 if (status != NV_OK) goto __nvoc_ctor_KernelCrashCatEngine_fail_CrashCatEngine;
131 __nvoc_init_dataField_KernelCrashCatEngine(pThis, pRmhalspecowner);
132 goto __nvoc_ctor_KernelCrashCatEngine_exit; // Success
133
134 __nvoc_ctor_KernelCrashCatEngine_fail_CrashCatEngine:
135 __nvoc_ctor_KernelCrashCatEngine_exit:
136
137 return status;
138 }
139
__nvoc_init_funcTable_KernelCrashCatEngine_1(KernelCrashCatEngine * pThis,RmHalspecOwner * pRmhalspecowner)140 static void __nvoc_init_funcTable_KernelCrashCatEngine_1(KernelCrashCatEngine *pThis, RmHalspecOwner *pRmhalspecowner) {
141 ChipHal *chipHal = &pRmhalspecowner->chipHal;
142 const unsigned long chipHal_HalVarIdx = (unsigned long)chipHal->__nvoc_HalVarIdx;
143 PORT_UNREFERENCED_VARIABLE(pThis);
144 PORT_UNREFERENCED_VARIABLE(pRmhalspecowner);
145 PORT_UNREFERENCED_VARIABLE(chipHal);
146 PORT_UNREFERENCED_VARIABLE(chipHal_HalVarIdx);
147
148 pThis->__kcrashcatEngineConfigured__ = &kcrashcatEngineConfigured_IMPL;
149
150 pThis->__kcrashcatEngineUnload__ = &kcrashcatEngineUnload_IMPL;
151
152 pThis->__kcrashcatEngineVprintf__ = &kcrashcatEngineVprintf_IMPL;
153
154 pThis->__kcrashcatEngineRegRead__ = NULL;
155
156 pThis->__kcrashcatEngineRegWrite__ = NULL;
157
158 pThis->__kcrashcatEngineMaskDmemAddr__ = NULL;
159
160 pThis->__kcrashcatEnginePriRead__ = &kcrashcatEnginePriRead_IMPL;
161
162 pThis->__kcrashcatEnginePriWrite__ = &kcrashcatEnginePriWrite_IMPL;
163
164 pThis->__kcrashcatEngineMapBufferDescriptor__ = &kcrashcatEngineMapBufferDescriptor_IMPL;
165
166 pThis->__kcrashcatEngineUnmapBufferDescriptor__ = &kcrashcatEngineUnmapBufferDescriptor_IMPL;
167
168 pThis->__kcrashcatEngineSyncBufferDescriptor__ = &kcrashcatEngineSyncBufferDescriptor_IMPL;
169
170 // Hal function -- kcrashcatEngineReadDmem
171 pThis->__kcrashcatEngineReadDmem__ = &kcrashcatEngineReadDmem_TU102;
172
173 pThis->__kcrashcatEngineReadEmem__ = &kcrashcatEngineReadEmem_2fced3;
174
175 // Hal function -- kcrashcatEngineGetScratchOffsets
176 pThis->__kcrashcatEngineGetScratchOffsets__ = &kcrashcatEngineGetScratchOffsets_TU102;
177
178 // Hal function -- kcrashcatEngineGetWFL0Offset
179 pThis->__kcrashcatEngineGetWFL0Offset__ = &kcrashcatEngineGetWFL0Offset_TU102;
180
181 pThis->__nvoc_base_CrashCatEngine.__crashcatEngineConfigured__ = &__nvoc_thunk_KernelCrashCatEngine_crashcatEngineConfigured;
182
183 pThis->__nvoc_base_CrashCatEngine.__crashcatEngineUnload__ = &__nvoc_thunk_KernelCrashCatEngine_crashcatEngineUnload;
184
185 pThis->__nvoc_base_CrashCatEngine.__crashcatEngineVprintf__ = &__nvoc_thunk_KernelCrashCatEngine_crashcatEngineVprintf;
186
187 pThis->__nvoc_base_CrashCatEngine.__crashcatEnginePriRead__ = &__nvoc_thunk_KernelCrashCatEngine_crashcatEnginePriRead;
188
189 pThis->__nvoc_base_CrashCatEngine.__crashcatEnginePriWrite__ = &__nvoc_thunk_KernelCrashCatEngine_crashcatEnginePriWrite;
190
191 pThis->__nvoc_base_CrashCatEngine.__crashcatEngineMapBufferDescriptor__ = &__nvoc_thunk_KernelCrashCatEngine_crashcatEngineMapBufferDescriptor;
192
193 pThis->__nvoc_base_CrashCatEngine.__crashcatEngineUnmapBufferDescriptor__ = &__nvoc_thunk_KernelCrashCatEngine_crashcatEngineUnmapBufferDescriptor;
194
195 pThis->__nvoc_base_CrashCatEngine.__crashcatEngineSyncBufferDescriptor__ = &__nvoc_thunk_KernelCrashCatEngine_crashcatEngineSyncBufferDescriptor;
196
197 pThis->__nvoc_base_CrashCatEngine.__crashcatEngineGetScratchOffsets__ = &__nvoc_thunk_KernelCrashCatEngine_crashcatEngineGetScratchOffsets;
198
199 pThis->__nvoc_base_CrashCatEngine.__crashcatEngineGetWFL0Offset__ = &__nvoc_thunk_KernelCrashCatEngine_crashcatEngineGetWFL0Offset;
200 }
201
__nvoc_init_funcTable_KernelCrashCatEngine(KernelCrashCatEngine * pThis,RmHalspecOwner * pRmhalspecowner)202 void __nvoc_init_funcTable_KernelCrashCatEngine(KernelCrashCatEngine *pThis, RmHalspecOwner *pRmhalspecowner) {
203 __nvoc_init_funcTable_KernelCrashCatEngine_1(pThis, pRmhalspecowner);
204 }
205
206 void __nvoc_init_CrashCatEngine(CrashCatEngine*);
__nvoc_init_KernelCrashCatEngine(KernelCrashCatEngine * pThis,RmHalspecOwner * pRmhalspecowner)207 void __nvoc_init_KernelCrashCatEngine(KernelCrashCatEngine *pThis, RmHalspecOwner *pRmhalspecowner) {
208 pThis->__nvoc_pbase_KernelCrashCatEngine = pThis;
209 pThis->__nvoc_pbase_CrashCatEngine = &pThis->__nvoc_base_CrashCatEngine;
210 __nvoc_init_CrashCatEngine(&pThis->__nvoc_base_CrashCatEngine);
211 __nvoc_init_funcTable_KernelCrashCatEngine(pThis, pRmhalspecowner);
212 }
213
214