Changeset 45994 in vbox for trunk/src/VBox/Runtime/include
- Timestamp:
- May 12, 2013 7:16:16 PM (12 years ago)
- svn:sync-xref-src-repo-rev:
- 85655
- Location:
- trunk/src/VBox/Runtime/include/internal
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/include/internal/dbgmod.h
r44528 r45994 444 444 445 445 /** 446 * Deferred loading callback. 447 * 448 * @returns IPRT status code. On success the necessary method tables should be 449 * installed in @a pMod. 450 * @param pMod Pointer to the debug module structure. 451 * @param pDeferred The deferred load data. 452 */ 453 typedef DECLCALLBACK(int) FNRTDBGMODDEFERRED(PRTDBGMODINT pMod, struct RTDBGMODDEFERRED *pDeferred); 454 /** Pointer to a deferred loading callback. */ 455 typedef FNRTDBGMODDEFERRED *PFNRTDBGMODDEFERRED; 456 457 458 /** 459 * Structure pointed to by pvDbgPriv and/or pvImgPriv when 460 * g_rtDbgModVtDbgDeferred and/or g_rtDbgModVtImgDeferred are being used. 461 */ 462 typedef struct RTDBGMODDEFERRED 463 { 464 /** The image size. 465 * Deferred loading is almost pointless without knowing the module size, as 466 * it cannot be mapped (correctly) without it. */ 467 RTUINTPTR cbImage; 468 /** Reference counter. */ 469 uint32_t volatile cRefs; 470 /** The configuration instance (referenced), can be NIL. */ 471 RTDBGCFG hDbgCfg; 472 /** Performs deferred loading of the module. */ 473 PFNRTDBGMODDEFERRED pfnDeferred; 474 /** Callback specific data. */ 475 union 476 { 477 struct 478 { 479 /** The time/date stamp of the executable image and codeview file. */ 480 uint32_t uTimestamp; 481 } PeImage, 482 OldCodeView; 483 484 struct 485 { 486 /** The PDB uuid. */ 487 RTUUID Uuid; 488 /** The PDB age. */ 489 uint32_t uAge; 490 } NewCodeview; 491 492 struct 493 { 494 /** The CRC-32 value found in the .gnu_debuglink section. */ 495 uint32_t uCrc32; 496 } GnuDebugLink; 497 } u; 498 } RTDBGMODDEFERRED; 499 /** Pointer to the deferred loading data. */ 500 typedef RTDBGMODDEFERRED *PRTDBGMODDEFERRED; 501 502 503 /** 446 504 * Debug module structure. 447 505 */ … … 455 513 /** The module tag. */ 456 514 uint64_t uTag; 515 516 /** When set, the loading of the image and debug info (including locating any 517 * external files), will not have taken place yet. */ 518 uint32_t fDeferred : 1; 519 /** Set if deferred loading failed. */ 520 uint32_t fDeferredFailed : 1; 521 /** Set if the debug info is based on image exports and segments. */ 522 uint32_t fExports : 1; 523 /** Alignment padding. */ 524 uint32_t fPadding1 : 29; 525 #if ARCH_BITS == 64 526 uint32_t u32Padding2; 527 #endif 528 457 529 /** The module name (short). */ 458 530 char const *pszName; … … 462 534 char const *pszDbgFile; 463 535 464 /** Critical section serializing access to the module. */465 RTCRITSECT CritSect;466 467 536 /** The method table for the executable image interpreter. */ 468 537 PCRTDBGMODVTIMG pImgVt; … … 475 544 void *pvDbgPriv; 476 545 546 /** Critical section serializing access to the module. */ 547 RTCRITSECT CritSect; 477 548 } RTDBGMODINT; 478 549 /** Pointer to an debug module structure. */ … … 483 554 extern DECLHIDDEN(RTDBGMODVTDBG const) g_rtDbgModVtDbgDwarf; 484 555 extern DECLHIDDEN(RTDBGMODVTDBG const) g_rtDbgModVtDbgNm; 556 extern DECLHIDDEN(RTDBGMODVTDBG const) g_rtDbgModVtDbgDeferred; 485 557 extern DECLHIDDEN(RTDBGMODVTIMG const) g_rtDbgModVtImgLdr; 486 487 int rtDbgModContainerCreate(PRTDBGMODINT pMod, RTUINTPTR cbSeg); 558 extern DECLHIDDEN(RTDBGMODVTIMG const) g_rtDbgModVtImgDeferred; 559 560 DECLHIDDEN(int) rtDbgModContainerCreate(PRTDBGMODINT pMod, RTUINTPTR cbSeg); 561 DECLHIDDEN(int) rtDbgModCreateForExports(PRTDBGMODINT pDbgMod); 562 DECLHIDDEN(int) rtDbgModDeferredCreate(PRTDBGMODINT pDbgMod, PFNRTDBGMODDEFERRED pfnDeferred, RTUINTPTR cbImage, 563 RTDBGCFG hDbgCfg, PRTDBGMODDEFERRED *ppDeferred); 488 564 489 565 /** @} */ -
trunk/src/VBox/Runtime/include/internal/ldrPE.h
r44528 r45994 181 181 182 182 /* debug dir */ 183 #define IMAGE_DEBUG_TYPE_UNKNOWN 0x0 184 #define IMAGE_DEBUG_TYPE_COFF 0x1 185 #define IMAGE_DEBUG_TYPE_CODEVIEW 0x2 186 #define IMAGE_DEBUG_TYPE_FPO 0x3 187 #define IMAGE_DEBUG_TYPE_MISC 0x4 188 #define IMAGE_DEBUG_TYPE_EXCEPTION 0x5 189 #define IMAGE_DEBUG_TYPE_FIXUP 0x6 190 #define IMAGE_DEBUG_TYPE_OMAP_TO_SRC 0x7 191 #define IMAGE_DEBUG_TYPE_OMAP_FROM_SRC 0x8 192 #define IMAGE_DEBUG_TYPE_BORLAND 0x9 193 #define IMAGE_DEBUG_TYPE_RESERVED10 0x10 183 #define IMAGE_DEBUG_TYPE_UNKNOWN UINT32_C(0x0) 184 #define IMAGE_DEBUG_TYPE_COFF UINT32_C(0x1) 185 #define IMAGE_DEBUG_TYPE_CODEVIEW UINT32_C(0x2) 186 #define IMAGE_DEBUG_TYPE_FPO UINT32_C(0x3) 187 #define IMAGE_DEBUG_TYPE_MISC UINT32_C(0x4) 188 #define IMAGE_DEBUG_TYPE_EXCEPTION UINT32_C(0x5) 189 #define IMAGE_DEBUG_TYPE_FIXUP UINT32_C(0x6) 190 #define IMAGE_DEBUG_TYPE_OMAP_TO_SRC UINT32_C(0x7) 191 #define IMAGE_DEBUG_TYPE_OMAP_FROM_SRC UINT32_C(0x8) 192 #define IMAGE_DEBUG_TYPE_BORLAND UINT32_C(0x9) 193 #define IMAGE_DEBUG_TYPE_RESERVED10 UINT32_C(0x10) 194 195 #define IMAGE_DEBUG_MISC_EXENAME UINT32_C(1) 194 196 195 197 /* security directory */ 196 #define WIN_CERT_REVISION_1_0 UINT16_C(0x0100) 197 #define WIN_CERT_REVISION_2_0 UINT16_C(0x0200) 198 199 #define WIN_CERT_TYPE_X509 UINT16_C(1) 200 #define WIN_CERT_TYPE_PKCS_SIGNED_DATA UINT16_C(2) 201 #define WIN_CERT_TYPE_RESERVED_1 UINT16_C(3) 202 #define WIN_CERT_TYPE_TS_STACK_SIGNED UINT16_C(4) 203 #define WIN_CERT_TYPE_EFI_PKCS115 UINT16_C(0x0ef0) 204 #define WIN_CERT_TYPE_EFI_GUID UINT16_C(0x0ef1) 198 #define WIN_CERT_REVISION_1_0 UINT16_C(0x0100) 199 #define WIN_CERT_REVISION_2_0 UINT16_C(0x0200) 200 201 #define WIN_CERT_TYPE_X509 UINT16_C(1) 202 #define WIN_CERT_TYPE_PKCS_SIGNED_DATA UINT16_C(2) 203 #define WIN_CERT_TYPE_RESERVED_1 UINT16_C(3) 204 #define WIN_CERT_TYPE_TS_STACK_SIGNED UINT16_C(4) 205 #define WIN_CERT_TYPE_EFI_PKCS115 UINT16_C(0x0ef0) 206 #define WIN_CERT_TYPE_EFI_GUID UINT16_C(0x0ef1) 207 205 208 206 209 … … 219 222 } IMAGE_FILE_HEADER; 220 223 typedef IMAGE_FILE_HEADER *PIMAGE_FILE_HEADER; 224 typedef IMAGE_FILE_HEADER const *PCIMAGE_FILE_HEADER; 221 225 222 226 … … 227 231 } IMAGE_DATA_DIRECTORY; 228 232 typedef IMAGE_DATA_DIRECTORY *PIMAGE_DATA_DIRECTORY; 233 typedef IMAGE_DATA_DIRECTORY const *PCIMAGE_DATA_DIRECTORY; 229 234 230 235 … … 232 237 { 233 238 uint16_t Magic; 234 uint8_t MajorLinkerVersion;235 uint8_t MinorLinkerVersion;239 uint8_t MajorLinkerVersion; 240 uint8_t MinorLinkerVersion; 236 241 uint32_t SizeOfCode; 237 242 uint32_t SizeOfInitializedData; … … 264 269 } IMAGE_OPTIONAL_HEADER32; 265 270 typedef IMAGE_OPTIONAL_HEADER32 *PIMAGE_OPTIONAL_HEADER32; 271 typedef IMAGE_OPTIONAL_HEADER32 const *PCIMAGE_OPTIONAL_HEADER32; 266 272 267 273 typedef struct _IMAGE_OPTIONAL_HEADER64 268 274 { 269 275 uint16_t Magic; 270 uint8_t MajorLinkerVersion;271 uint8_t MinorLinkerVersion;276 uint8_t MajorLinkerVersion; 277 uint8_t MinorLinkerVersion; 272 278 uint32_t SizeOfCode; 273 279 uint32_t SizeOfInitializedData; … … 299 305 } IMAGE_OPTIONAL_HEADER64; 300 306 typedef IMAGE_OPTIONAL_HEADER64 *PIMAGE_OPTIONAL_HEADER64; 307 typedef IMAGE_OPTIONAL_HEADER64 const *PCIMAGE_OPTIONAL_HEADER64; 301 308 302 309 … … 308 315 } IMAGE_NT_HEADERS32; 309 316 typedef IMAGE_NT_HEADERS32 *PIMAGE_NT_HEADERS32; 317 typedef IMAGE_NT_HEADERS32 const *PCIMAGE_NT_HEADERS32; 310 318 311 319 typedef struct _IMAGE_NT_HEADERS64 … … 316 324 } IMAGE_NT_HEADERS64; 317 325 typedef IMAGE_NT_HEADERS64 *PIMAGE_NT_HEADERS64; 326 typedef IMAGE_NT_HEADERS64 const *PCIMAGE_NT_HEADERS64; 318 327 319 328 … … 336 345 } IMAGE_SECTION_HEADER; 337 346 typedef IMAGE_SECTION_HEADER *PIMAGE_SECTION_HEADER; 347 typedef IMAGE_SECTION_HEADER const *PCIMAGE_SECTION_HEADER; 338 348 339 349 … … 344 354 } IMAGE_BASE_RELOCATION; 345 355 typedef IMAGE_BASE_RELOCATION *PIMAGE_BASE_RELOCATION; 356 typedef IMAGE_BASE_RELOCATION const *PCIMAGE_BASE_RELOCATION; 346 357 347 358 … … 375 386 } IMAGE_IMPORT_DESCRIPTOR; 376 387 typedef IMAGE_IMPORT_DESCRIPTOR *PIMAGE_IMPORT_DESCRIPTOR; 388 typedef IMAGE_IMPORT_DESCRIPTOR const *PCIMAGE_IMPORT_DESCRIPTOR; 377 389 378 390 … … 380 392 { 381 393 uint16_t Hint; 382 uint8_t Name[1];394 uint8_t Name[1]; 383 395 } IMAGE_IMPORT_BY_NAME; 384 396 typedef IMAGE_IMPORT_BY_NAME *PIMAGE_IMPORT_BY_NAME; 397 typedef IMAGE_IMPORT_BY_NAME const *PCIMAGE_IMPORT_BY_NAME; 385 398 386 399 … … 397 410 } IMAGE_THUNK_DATA64; 398 411 typedef IMAGE_THUNK_DATA64 *PIMAGE_THUNK_DATA64; 412 typedef IMAGE_THUNK_DATA64 const *PCIMAGE_THUNK_DATA64; 399 413 400 414 typedef struct _IMAGE_THUNK_DATA32 … … 409 423 } IMAGE_THUNK_DATA32; 410 424 typedef IMAGE_THUNK_DATA32 *PIMAGE_THUNK_DATA32; 425 typedef IMAGE_THUNK_DATA32 const *PCIMAGE_THUNK_DATA32; 411 426 412 427 … … 434 449 uint32_t SEHandlerCount; 435 450 } IMAGE_LOAD_CONFIG_DIRECTORY32; 436 typedef IMAGE_LOAD_CONFIG_DIRECTORY32 PIMAGE_LOAD_CONFIG_DIRECTORY32; 451 typedef IMAGE_LOAD_CONFIG_DIRECTORY32 *PIMAGE_LOAD_CONFIG_DIRECTORY32; 452 typedef IMAGE_LOAD_CONFIG_DIRECTORY32 const *PCIMAGE_LOAD_CONFIG_DIRECTORY32; 437 453 438 454 typedef struct _IMAGE_LOAD_CONFIG_DIRECTORY64 … … 460 476 } IMAGE_LOAD_CONFIG_DIRECTORY64; 461 477 typedef IMAGE_LOAD_CONFIG_DIRECTORY64 *PIMAGE_LOAD_CONFIG_DIRECTORY64; 478 typedef IMAGE_LOAD_CONFIG_DIRECTORY64 const *PCIMAGE_LOAD_CONFIG_DIRECTORY64; 462 479 463 480 … … 474 491 } IMAGE_DEBUG_DIRECTORY; 475 492 typedef IMAGE_DEBUG_DIRECTORY *PIMAGE_DEBUG_DIRECTORY; 493 typedef IMAGE_DEBUG_DIRECTORY const *PCIMAGE_DEBUG_DIRECTORY; 494 495 typedef struct _IMAGE_DEBUG_MISC 496 { 497 uint32_t DataType; 498 uint32_t Length; 499 uint8_t Unicode; 500 uint8_t Reserved[3]; 501 uint8_t Data[1]; 502 } IMAGE_DEBUG_MISC; 503 typedef IMAGE_DEBUG_MISC *PIMAGE_DEBUG_MISC; 504 typedef IMAGE_DEBUG_MISC const *PCIMAGE_DEBUG_MISC; 476 505 477 506 … … 484 513 } WIN_CERTIFICATE; 485 514 typedef WIN_CERTIFICATE *PWIN_CERTIFICATE; 515 typedef WIN_CERTIFICATE const *PCWIN_CERTIFICATE; 486 516 487 517 #pragma pack()
Note:
See TracChangeset
for help on using the changeset viewer.