VirtualBox

source: vbox/trunk/src/VBox/Debugger/DBGPlugInLinuxModuleCodeTmpl.cpp.h@ 91482

Last change on this file since 91482 was 90473, checked in by vboxsync, 3 years ago

Debugger/DBGPlugInLinuxModuleCodeTmpl.cpp.h: Make scm happy

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 19.2 KB
Line 
1/* $Id: DBGPlugInLinuxModuleCodeTmpl.cpp.h 90473 2021-08-02 12:16:16Z vboxsync $ */
2/** @file
3 * DBGPlugInLinux - Code template for struct module processing.
4 */
5
6/*
7 * Copyright (C) 2019-2020 Oracle Corporation
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 */
17
18
19/*********************************************************************************************************************************
20* Defined Constants And Macros *
21*********************************************************************************************************************************/
22#ifndef LNX_MK_VER
23# define LNX_MK_VER(major, minor, build) (((major) << 22) | ((minor) << 12) | (build))
24#endif
25#if LNX_64BIT
26# define LNX_ULONG_T uint64_t
27#else
28# define LNX_ULONG_T uint32_t
29#endif
30#if LNX_64BIT
31# define PAD32ON64(seq) uint32_t RT_CONCAT(u32Padding,seq);
32#else
33# define PAD32ON64(seq)
34#endif
35
36
37/*********************************************************************************************************************************
38* Structures and Typedefs *
39*********************************************************************************************************************************/
40/**
41 * Kernel module symbol (hasn't changed in ages).
42 */
43typedef struct RT_CONCAT(LNXMODKSYM,LNX_SUFFIX)
44{
45 LNX_ULONG_T uValue;
46 LNX_PTR_T uPtrSymName;
47} RT_CONCAT(LNXMODKSYM,LNX_SUFFIX);
48
49
50#if LNX_VER >= LNX_MK_VER(2,6,11)
51typedef struct RT_CONCAT(LNXMODKOBJECT,LNX_SUFFIX)
52{
53 LNX_PTR_T uPtrKName;
54# if LNX_VER < LNX_MK_VER(2,6,24)
55 char name[20];
56# endif
57# if LNX_VER < LNX_MK_VER(2,6,27)
58 int32_t cRefs;
59# if LNX_VER >= LNX_MK_VER(2,6,24)
60 PAD32ON64(0)
61# endif
62# endif
63 LNX_PTR_T uPtrNext;
64 LNX_PTR_T uPtrPrev;
65 LNX_PTR_T uPtrParent; /**< struct kobject pointer */
66 LNX_PTR_T uPtrKset; /**< struct kset pointer */
67 LNX_PTR_T uPtrKtype; /**< struct kobj_type pointer */
68 LNX_PTR_T uPtrDirEntry; /**< struct dentry pointer; 2.6.23+ sysfs_dirent. */
69# if LNX_VER >= LNX_MK_VER(2,6,17) && LNX_VER < LNX_MK_VER(2,6,24)
70 LNX_PTR_T aPtrWaitQueueHead[3];
71# endif
72# if LNX_VER >= LNX_MK_VER(2,6,27)
73 int32_t cRefs;
74 uint32_t uStateStuff;
75# elif LNX_VER >= LNX_MK_VER(2,6,25)
76 LNX_ULONG_T uStateStuff;
77# endif
78 /* non-kobject: */
79 LNX_PTR_T uPtrModule; /**< struct module pointer. */
80# if LNX_VER >= LNX_MK_VER(2,6,21)
81 LNX_PTR_T uPtrDriverDir; /**< Points to struct kobject. */
82# endif
83# if LNX_VER >= LNX_MK_VER(4,5,0)
84 LNX_PTR_T uPtrMp;
85 LNX_PTR_T uPtrCompletion; /**< Points to struct completion. */
86# endif
87} RT_CONCAT(LNXMODKOBJECT,LNX_SUFFIX);
88#endif
89#if LNX_VER == LNX_MK_VER(2,6,24) && LNX_64BIT
90AssertCompileMemberOffset(RT_CONCAT(LNXMODKOBJECT,LNX_SUFFIX), uPtrParent, 32);
91AssertCompileMemberOffset(RT_CONCAT(LNXMODKOBJECT,LNX_SUFFIX), uPtrParent, 32);
92AssertCompileSize(RT_CONCAT(LNXMODKOBJECT,LNX_SUFFIX), 80);
93#endif
94
95
96#if LNX_VER >= LNX_MK_VER(4,5,0)
97/**
98 * Red black tree node.
99 */
100typedef struct RT_CONCAT(LNXRBNODE,LNX_SUFFIX)
101{
102 LNX_ULONG_T uRbParentColor;
103 LNX_PTR_T uPtrRbRight;
104 LNX_PTR_T uPtrRbLeft;
105} RT_CONCAT(LNXRBNODE,LNX_SUFFIX);
106
107
108/**
109 * Latch tree node.
110 */
111typedef struct RT_CONCAT(LNXLATCHTREENODE,LNX_SUFFIX)
112{
113 RT_CONCAT(LNXRBNODE,LNX_SUFFIX) aNode[2];
114} RT_CONCAT(LNXLATCHTREENODE,LNX_SUFFIX);
115
116
117/**
118 * Module tree node.
119 */
120typedef struct RT_CONCAT(LNXMODTREENODE,LNX_SUFFIX)
121{
122 LNX_PTR_T uPtrKMod;
123 RT_CONCAT(LNXLATCHTREENODE,LNX_SUFFIX) Node;
124} RT_CONCAT(LNXMODTREENODE,LNX_SUFFIX);
125
126
127/**
128 * Module layout.
129 */
130typedef struct RT_CONCAT(LNXKMODLAYOUT,LNX_SUFFIX)
131{
132 LNX_PTR_T uPtrBase; /**< Base pointer to text and data. */
133 uint32_t cb; /**< Size of the module. */
134 uint32_t cbText; /**< Size of the text section. */
135 uint32_t cbRo; /**< Size of the readonly portion (text + ro data). */
136 RT_CONCAT(LNXMODTREENODE,LNX_SUFFIX) ModTreeNd; /**< Only available when CONFIG_MODULES_TREE_LOOKUP is set (default). */
137} RT_CONCAT(LNXKMODLAYOUT,LNX_SUFFIX);
138
139
140/**
141 * Mutex.
142 */
143typedef struct RT_CONCAT(LNXMUTEX,LNX_SUFFIX)
144{
145 LNX_ULONG_T uOwner;
146 uint32_t wait_lock; /**< Actually spinlock_t */
147 PAD32ON64(0)
148 LNX_PTR_T uWaitLstPtrNext;
149 LNX_PTR_T uWaitLstPtrPrev;
150} RT_CONCAT(LNXMUTEX,LNX_SUFFIX);
151#endif
152
153
154/**
155 * Maps to the start of struct module in include/linux/module.h.
156 */
157typedef struct RT_CONCAT(LNXKMODULE,LNX_SUFFIX)
158{
159#if LNX_VER >= LNX_MK_VER(4,5,0)
160 /* Completely new layout to not feed the spaghetti dragons further. */
161 int32_t state;
162 PAD32ON64(0)
163 LNX_PTR_T uPtrNext;
164 LNX_PTR_T uPtrPrev;
165 char name[64 - sizeof(LNX_PTR_T)];
166
167 RT_CONCAT(LNXMODKOBJECT,LNX_SUFFIX) mkobj;
168 LNX_PTR_T uPtrModInfoAttrs; /**< Points to struct module_attribute. */
169 LNX_PTR_T uPtrVersion; /**< String pointers. */
170 LNX_PTR_T uPtrSrcVersion; /**< String pointers. */
171 LNX_PTR_T uPtrHolderDir; /**< Points to struct kobject. */
172
173 /** @name Exported Symbols
174 * @{ */
175 LNX_PTR_T uPtrSyms; /**< Array of struct kernel_symbol. */
176 LNX_PTR_T uPtrCrcs; /**< unsigned long array */
177 uint32_t num_syms;
178 /** @} */
179
180 /** @name Kernel parameters
181 * @{ */
182 RT_CONCAT(LNXMUTEX,LNX_SUFFIX) Mtx; /**< Mutex. */
183 LNX_PTR_T uPtrKp; /**< Points to struct kernel_param */
184 uint32_t num_kp;
185 /** @} */
186
187 /** @name GPL Symbols
188 * @{ */
189 uint32_t num_gpl_syms;
190 LNX_PTR_T uPtrGplSyms; /**< Array of struct kernel_symbol. */
191 LNX_PTR_T uPtrGplCrcs; /**< unsigned long array */
192 /** @} */
193
194 /** @name Unused symbols
195 * @{ */
196 LNX_PTR_T uPtrUnusedSyms; /**< Array of struct kernel_symbol. */
197 LNX_PTR_T uPtrUnusedCrcs; /**< unsigned long array */
198 uint32_t num_unused_syms;
199 uint32_t num_unused_gpl_syms;
200 LNX_PTR_T uPtrUnusedGplSyms; /**< Array of struct kernel_symbol. */
201 LNX_PTR_T uPtrUnusedGplCrcs; /**< unsigned long array */
202 /** @} */
203
204 uint8_t sig_ok;
205 uint8_t async_probe_requested;
206
207 /** @name Future GPL Symbols
208 * @{ */
209 LNX_PTR_T uPtrGplFutureSyms; /**< Array of struct kernel_symbol. */
210 LNX_PTR_T uPtrGplFutureCrcs; /**< unsigned long array */
211 uint32_t num_gpl_future_syms;
212 /** @} */
213
214 /** @name Exception table.
215 * @{ */
216 uint32_t num_exentries;
217 LNX_PTR_T uPtrEntries; /**< struct exception_table_entry array. */
218 /** @} */
219
220 LNX_PTR_T pfnInit;
221 RT_CONCAT(LNXKMODLAYOUT,LNX_SUFFIX) CoreLayout; /**< Should be aligned on a cache line. */
222 RT_CONCAT(LNXKMODLAYOUT,LNX_SUFFIX) InitLayout;
223
224#elif LNX_VER >= LNX_MK_VER(2,5,48)
225 /*
226 * This first part is mostly always the same.
227 */
228 int32_t state;
229 PAD32ON64(0)
230 LNX_PTR_T uPtrNext;
231 LNX_PTR_T uPtrPrev;
232 char name[64 - sizeof(LNX_PTR_T)];
233
234 /*
235 * Here be spaghetti dragons.
236 */
237# if LNX_VER >= LNX_MK_VER(2,6,11)
238 RT_CONCAT(LNXMODKOBJECT,LNX_SUFFIX) mkobj; /**< Was just kobj for a while. */
239 LNX_PTR_T uPtrParamAttrs; /**< Points to struct module_param_attrs. */
240# if LNX_VER >= LNX_MK_VER(2,6,17)
241 LNX_PTR_T uPtrModInfoAttrs; /**< Points to struct module_attribute. */
242# endif
243# if LNX_VER == LNX_MK_VER(2,6,20)
244 LNX_PTR_T uPtrDriverDir; /**< Points to struct kobject. */
245# elif LNX_VER >= LNX_MK_VER(2,6,21)
246 LNX_PTR_T uPtrHolderDir; /**< Points to struct kobject. */
247# endif
248# if LNX_VER >= LNX_MK_VER(2,6,13)
249 LNX_PTR_T uPtrVersion; /**< String pointers. */
250 LNX_PTR_T uPtrSrcVersion; /**< String pointers. */
251# endif
252# else
253# if LNX_VER >= LNX_MK_VER(2,6,7)
254 LNX_PTR_T uPtrMkObj;
255# endif
256# if LNX_VER >= LNX_MK_VER(2,6,10)
257 LNX_PTR_T uPtrParamsKobject;
258# endif
259# endif
260
261 /** @name Exported Symbols
262 * @{ */
263# if LNX_VER < LNX_MK_VER(2,5,67)
264 LNX_PTR_T uPtrSymsNext, uPtrSymsPrev, uPtrSymsOwner;
265# if LNX_VER >= LNX_MK_VER(2,5,55)
266 int32_t syms_gplonly;
267 uint32_t num_syms;
268# else
269 uint32_t num_syms;
270 PAD32ON64(1)
271# endif
272# endif
273 LNX_PTR_T uPtrSyms; /**< Array of struct kernel_symbol. */
274# if LNX_VER >= LNX_MK_VER(2,5,67)
275 uint32_t num_syms;
276 PAD32ON64(1)
277# endif
278# if LNX_VER >= LNX_MK_VER(2,5,60)
279 LNX_PTR_T uPtrCrcs; /**< unsigned long array */
280# endif
281 /** @} */
282
283 /** @name GPL Symbols
284 * @since 2.5.55
285 * @{ */
286# if LNX_VER >= LNX_MK_VER(2,5,55)
287# if LNX_VER < LNX_MK_VER(2,5,67)
288 LNX_PTR_T uPtrGplSymsNext, uPtrGplSymsPrev, uPtrGplSymsOwner;
289# if LNX_VER >= LNX_MK_VER(2,5,55)
290 int32_t gpl_syms_gplonly;
291 uint32_t num_gpl_syms;
292# else
293 uint32_t num_gpl_syms;
294 PAD32ON64(2)
295# endif
296# endif
297 LNX_PTR_T uPtrGplSyms; /**< Array of struct kernel_symbol. */
298# if LNX_VER >= LNX_MK_VER(2,5,67)
299 uint32_t num_gpl_syms;
300 PAD32ON64(2)
301# endif
302# if LNX_VER >= LNX_MK_VER(2,5,60)
303 LNX_PTR_T uPtrGplCrcs; /**< unsigned long array */
304# endif
305# endif /* > 2.5.55 */
306 /** @} */
307
308 /** @name Unused Exported Symbols
309 * @since 2.6.18
310 * @{ */
311# if LNX_VER >= LNX_MK_VER(2,6,18)
312 LNX_PTR_T uPtrUnusedSyms; /**< Array of struct kernel_symbol. */
313 uint32_t num_unused_syms;
314 PAD32ON64(4)
315 LNX_PTR_T uPtrUnusedCrcs; /**< unsigned long array */
316# endif
317 /** @} */
318
319 /** @name Unused GPL Symbols
320 * @since 2.6.18
321 * @{ */
322# if LNX_VER >= LNX_MK_VER(2,6,18)
323 LNX_PTR_T uPtrUnusedGplSyms; /**< Array of struct kernel_symbol. */
324 uint32_t num_unused_gpl_syms;
325 PAD32ON64(5)
326 LNX_PTR_T uPtrUnusedGplCrcs; /**< unsigned long array */
327# endif
328 /** @} */
329
330 /** @name Future GPL Symbols
331 * @since 2.6.17
332 * @{ */
333# if LNX_VER >= LNX_MK_VER(2,6,17)
334 LNX_PTR_T uPtrGplFutureSyms; /**< Array of struct kernel_symbol. */
335 uint32_t num_gpl_future_syms;
336 PAD32ON64(3)
337 LNX_PTR_T uPtrGplFutureCrcs; /**< unsigned long array */
338# endif
339 /** @} */
340
341 /** @name Exception table.
342 * @{ */
343# if LNX_VER < LNX_MK_VER(2,5,67)
344 LNX_PTR_T uPtrXcptTabNext, uPtrXcptTabPrev;
345# endif
346 uint32_t num_exentries;
347 PAD32ON64(6)
348 LNX_PTR_T uPtrEntries; /**< struct exception_table_entry array. */
349 /** @} */
350
351 /*
352 * Hopefully less spaghetti from here on...
353 */
354 LNX_PTR_T pfnInit;
355 LNX_PTR_T uPtrModuleInit;
356 LNX_PTR_T uPtrModuleCore;
357 LNX_ULONG_T cbInit;
358 LNX_ULONG_T cbCore;
359# if LNX_VER >= LNX_MK_VER(2,5,74)
360 LNX_ULONG_T cbInitText;
361 LNX_ULONG_T cbCoreText;
362# endif
363
364# if LNX_VER >= LNX_MK_VER(2,6,18)
365 LNX_PTR_T uPtrUnwindInfo;
366# endif
367#else
368 uint32_t structure_size;
369
370#endif
371} RT_CONCAT(LNXKMODULE,LNX_SUFFIX);
372
373# if LNX_VER == LNX_MK_VER(2,6,24) && LNX_64BIT
374AssertCompileMemberOffset(RT_CONCAT(LNXKMODULE,LNX_SUFFIX), uPtrParamAttrs, 160);
375AssertCompileMemberOffset(RT_CONCAT(LNXKMODULE,LNX_SUFFIX), num_syms, 208);
376AssertCompileMemberOffset(RT_CONCAT(LNXKMODULE,LNX_SUFFIX), num_gpl_syms, 232);
377AssertCompileMemberOffset(RT_CONCAT(LNXKMODULE,LNX_SUFFIX), num_unused_syms, 256);
378AssertCompileMemberOffset(RT_CONCAT(LNXKMODULE,LNX_SUFFIX), num_unused_gpl_syms, 280);
379AssertCompileMemberOffset(RT_CONCAT(LNXKMODULE,LNX_SUFFIX), num_gpl_future_syms, 304);
380AssertCompileMemberOffset(RT_CONCAT(LNXKMODULE,LNX_SUFFIX), num_exentries, 320);
381AssertCompileMemberOffset(RT_CONCAT(LNXKMODULE,LNX_SUFFIX), uPtrModuleCore, 352);
382AssertCompileMemberOffset(RT_CONCAT(LNXKMODULE,LNX_SUFFIX), uPtrUnwindInfo, 392);
383#endif
384
385
386
387/**
388 * Loads the kernel symbols at the given start address.
389 *
390 * @returns VBox status code.
391 * @param pUVM Pointer to the user-mode VM instance.
392 * @param hDbgMod The module handle to add the loaded symbols to.
393 * @param uPtrModuleStart The virtual address where the kernel module starts we want to extract symbols from.
394 * @param uPtrSymStart The start address of the array of symbols.
395 * @param cSyms Number of symbols in the array.
396 */
397static int RT_CONCAT(dbgDiggerLinuxLoadModuleSymbols,LNX_SUFFIX)(PUVM pUVM, RTDBGMOD hDbgMod, LNX_PTR_T uPtrModuleStart, LNX_PTR_T uPtrSymStart, uint32_t cSyms)
398{
399 int rc = VINF_SUCCESS;
400 DBGFADDRESS AddrSym;
401 DBGFR3AddrFromFlat(pUVM, &AddrSym, uPtrSymStart);
402
403 while ( cSyms
404 && RT_SUCCESS(rc))
405 {
406 RT_CONCAT(LNXMODKSYM,LNX_SUFFIX) aSyms[64];
407 uint32_t cThisLoad = RT_MIN(cSyms, RT_ELEMENTS(aSyms));
408
409 rc = DBGFR3MemRead(pUVM, 0, &AddrSym, &aSyms[0], cThisLoad * sizeof(aSyms[0]));
410 if (RT_SUCCESS(rc))
411 {
412 cSyms -= cThisLoad;
413 DBGFR3AddrAdd(&AddrSym, cThisLoad * sizeof(aSyms[0]));
414
415 for (uint32_t i = 0; i < cThisLoad; i++)
416 {
417 char szSymName[128];
418 DBGFADDRESS AddrSymName;
419 rc = DBGFR3MemRead(pUVM, 0, DBGFR3AddrFromFlat(pUVM, &AddrSymName, aSyms[i].uPtrSymName),
420 &szSymName[0], sizeof(szSymName));
421 if (RT_FAILURE(rc))
422 break;
423
424 /* Verify string encoding - ignore the symbol if it fails. */
425 rc = RTStrValidateEncodingEx(&szSymName[0], sizeof(szSymName), RTSTR_VALIDATE_ENCODING_ZERO_TERMINATED);
426 if (RT_FAILURE(rc))
427 continue;
428
429 Assert(aSyms[i].uValue >= uPtrModuleStart);
430 rc = RTDbgModSymbolAdd(hDbgMod, szSymName, RTDBGSEGIDX_RVA, aSyms[i].uValue - uPtrModuleStart, 0 /*cb*/, 0 /*fFlags*/, NULL);
431 if (RT_SUCCESS(rc))
432 LogFlowFunc(("Added symbol '%s' successfully\n", szSymName));
433 else
434 {
435 LogFlowFunc(("Adding symbol '%s' failed with: %Rrc\n", szSymName, rc));
436 rc = VINF_SUCCESS;
437 }
438 }
439 }
440 }
441
442 return rc;
443}
444
445
446/**
447 * Version specific module processing code.
448 */
449static uint64_t RT_CONCAT(dbgDiggerLinuxLoadModule,LNX_SUFFIX)(PDBGDIGGERLINUX pThis, PUVM pUVM, PDBGFADDRESS pAddrModule)
450{
451 RT_CONCAT(LNXKMODULE,LNX_SUFFIX) Module;
452
453 int rc = DBGFR3MemRead(pUVM, 0, DBGFR3AddrSub(pAddrModule, RT_UOFFSETOF(RT_CONCAT(LNXKMODULE,LNX_SUFFIX), uPtrNext)),
454 &Module, sizeof(Module));
455 if (RT_FAILURE(rc))
456 {
457 LogRelFunc(("Failed to read module structure at %#RX64: %Rrc\n", pAddrModule->FlatPtr, rc));
458 return 0;
459 }
460
461 /*
462 * Check the module name.
463 */
464#if LNX_VER >= LNX_MK_VER(2,5,48)
465 const char *pszName = Module.name;
466 size_t const cbName = sizeof(Module.name);
467#else
468
469#endif
470 if ( RTStrNLen(pszName, cbName) >= cbName
471 || RT_FAILURE(RTStrValidateEncoding(pszName))
472 || *pszName == '\0')
473 {
474 LogRelFunc(("%#RX64: Bad name: %.*Rhxs\n", pAddrModule->FlatPtr, (int)cbName, pszName));
475 return 0;
476 }
477
478 /*
479 * Create a simple module for it.
480 */
481#if LNX_VER >= LNX_MK_VER(4,5,0)
482 LNX_PTR_T uPtrModuleCore = Module.CoreLayout.uPtrBase;
483 uint32_t cbCore = Module.CoreLayout.cb;
484#else
485 LNX_PTR_T uPtrModuleCore = Module.uPtrModuleCore;
486 uint32_t cbCore = (uint32_t)Module.cbCore;
487#endif
488 LogRelFunc((" %#RX64: %#RX64 LB %#RX32 %s\n", pAddrModule->FlatPtr, uPtrModuleCore, cbCore, pszName));
489
490 RTDBGMOD hDbgMod;
491 rc = RTDbgModCreate(&hDbgMod, pszName, cbCore, 0 /*fFlags*/);
492 if (RT_SUCCESS(rc))
493 {
494 rc = RTDbgModSetTag(hDbgMod, DIG_LNX_MOD_TAG);
495 if (RT_SUCCESS(rc))
496 {
497 RTDBGAS hAs = DBGFR3AsResolveAndRetain(pUVM, DBGF_AS_KERNEL);
498 rc = RTDbgAsModuleLink(hAs, hDbgMod, uPtrModuleCore, RTDBGASLINK_FLAGS_REPLACE /*fFlags*/);
499 RTDbgAsRelease(hAs);
500 if (RT_SUCCESS(rc))
501 {
502 rc = RT_CONCAT(dbgDiggerLinuxLoadModuleSymbols,LNX_SUFFIX)(pUVM, hDbgMod, uPtrModuleCore,
503 Module.uPtrSyms, Module.num_syms);
504 if (RT_FAILURE(rc))
505 LogRelFunc((" Faild to load symbols: %Rrc\n", rc));
506
507#if LNX_VER >= LNX_MK_VER(2,5,55)
508 rc = RT_CONCAT(dbgDiggerLinuxLoadModuleSymbols,LNX_SUFFIX)(pUVM, hDbgMod, uPtrModuleCore,
509 Module.uPtrGplSyms, Module.num_gpl_syms);
510 if (RT_FAILURE(rc))
511 LogRelFunc((" Faild to load GPL symbols: %Rrc\n", rc));
512#endif
513
514#if LNX_VER >= LNX_MK_VER(2,6,17)
515 rc = RT_CONCAT(dbgDiggerLinuxLoadModuleSymbols,LNX_SUFFIX)(pUVM, hDbgMod, uPtrModuleCore,
516 Module.uPtrGplFutureSyms, Module.num_gpl_future_syms);
517 if (RT_FAILURE(rc))
518 LogRelFunc((" Faild to load future GPL symbols: %Rrc\n", rc));
519#endif
520
521#if LNX_VER >= LNX_MK_VER(2,6,18)
522 rc = RT_CONCAT(dbgDiggerLinuxLoadModuleSymbols,LNX_SUFFIX)(pUVM, hDbgMod, uPtrModuleCore,
523 Module.uPtrUnusedSyms, Module.num_unused_syms);
524 if (RT_FAILURE(rc))
525 LogRelFunc((" Faild to load unused symbols: %Rrc\n", rc));
526
527 rc = RT_CONCAT(dbgDiggerLinuxLoadModuleSymbols,LNX_SUFFIX)(pUVM, hDbgMod, uPtrModuleCore,
528 Module.uPtrUnusedGplSyms, Module.num_unused_gpl_syms);
529 if (RT_FAILURE(rc))
530 LogRelFunc((" Faild to load unused GPL symbols: %Rrc\n", rc));
531#endif
532 }
533 }
534 else
535 LogRel(("DbgDiggerOs2: RTDbgModSetTag failed: %Rrc\n", rc));
536 RTDbgModRelease(hDbgMod);
537 }
538
539 RT_NOREF(pThis);
540 return Module.uPtrNext;
541}
542
543#undef LNX_VER
544#undef LNX_SUFFIX
545#undef LNX_ULONG_T
546#undef PAD32ON64
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette