Changeset 40756 in vbox for trunk/include
- Timestamp:
- Apr 3, 2012 2:47:33 PM (13 years ago)
- Location:
- trunk/include/VBox
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/err.h
r40713 r40756 1620 1620 #define VERR_SUPDRV_KERNEL_TOO_OLD_FOR_VTX (-3703) 1621 1621 /** Bad VTG magic value. */ 1622 #define VERR_SUPDRV_VTG_MAGIC (-3704)1622 #define VERR_SUPDRV_VTG_MAGIC (-3704) 1623 1623 /** Bad VTG bit count value. */ 1624 #define VERR_SUPDRV_VTG_BITS (-3705)1624 #define VERR_SUPDRV_VTG_BITS (-3705) 1625 1625 /** Bad VTG header. */ 1626 #define VERR_SUPDRV_VTG_BAD_HDR (-3706)1626 #define VERR_SUPDRV_VTG_BAD_HDR (-3706) 1627 1627 /** Bad VTG header - pointer. */ 1628 #define VERR_SUPDRV_VTG_BAD_HDR_PTR (-3707)1628 #define VERR_SUPDRV_VTG_BAD_HDR_PTR (-3707) 1629 1629 /** Bad VTG header - to low value. */ 1630 #define VERR_SUPDRV_VTG_BAD_HDR_TOO_FEW (-3708)1630 #define VERR_SUPDRV_VTG_BAD_HDR_TOO_FEW (-3708) 1631 1631 /** Bad VTG header - to high value. */ 1632 #define VERR_SUPDRV_VTG_BAD_HDR_TOO_MUCH (-3709)1632 #define VERR_SUPDRV_VTG_BAD_HDR_TOO_MUCH (-3709) 1633 1633 /** Bad VTG header - size value is not a multiple of the structure size. */ 1634 #define VERR_SUPDRV_VTG_BAD_HDR_NOT_MULTIPLE (-3710)1634 #define VERR_SUPDRV_VTG_BAD_HDR_NOT_MULTIPLE (-3710) 1635 1635 /** Bad VTG string table offset. */ 1636 #define VERR_SUPDRV_VTG_STRTAB_OFF (-3711)1636 #define VERR_SUPDRV_VTG_STRTAB_OFF (-3711) 1637 1637 /** Bad VTG string. */ 1638 #define VERR_SUPDRV_VTG_BAD_STRING (-3712)1638 #define VERR_SUPDRV_VTG_BAD_STRING (-3712) 1639 1639 /** VTG string is too long. */ 1640 #define VERR_SUPDRV_VTG_STRING_TOO_LONG (-3713)1640 #define VERR_SUPDRV_VTG_STRING_TOO_LONG (-3713) 1641 1641 /** Bad VTG attribute value. */ 1642 #define VERR_SUPDRV_VTG_BAD_ATTR (-3714)1642 #define VERR_SUPDRV_VTG_BAD_ATTR (-3714) 1643 1643 /** Bad VTG provider descriptor. */ 1644 #define VERR_SUPDRV_VTG_BAD_PROVIDER (-3715)1644 #define VERR_SUPDRV_VTG_BAD_PROVIDER (-3715) 1645 1645 /** Bad VTG probe descriptor. */ 1646 #define VERR_SUPDRV_VTG_BAD_PROBE (-3716)1646 #define VERR_SUPDRV_VTG_BAD_PROBE (-3716) 1647 1647 /** Bad VTG argument list descriptor. */ 1648 #define VERR_SUPDRV_VTG_BAD_ARGLIST (-3717)1648 #define VERR_SUPDRV_VTG_BAD_ARGLIST (-3717) 1649 1649 /** Bad VTG probe enabled data. */ 1650 #define VERR_SUPDRV_VTG_BAD_PROBE_ENABLED (-3718)1650 #define VERR_SUPDRV_VTG_BAD_PROBE_ENABLED (-3718) 1651 1651 /** Bad VTG probe location record. */ 1652 #define VERR_SUPDRV_VTG_BAD_PROBE_LOC (-3719)1652 #define VERR_SUPDRV_VTG_BAD_PROBE_LOC (-3719) 1653 1653 /** The VTG object for the session or image has already been registered. */ 1654 #define VERR_SUPDRV_VTG_ALREADY_REGISTERED (-3720)1654 #define VERR_SUPDRV_VTG_ALREADY_REGISTERED (-3720) 1655 1655 /** A driver may only register one VTG object per session. */ 1656 #define VERR_SUPDRV_VTG_ONLY_ONCE_PER_SESSION (-3721) 1656 #define VERR_SUPDRV_VTG_ONLY_ONCE_PER_SESSION (-3721) 1657 /** A tracer has already been registered. */ 1658 #define VERR_SUPDRV_TRACER_ALREADY_REGISTERED (-3722) 1659 /** The session has no tracer associated with it. */ 1660 #define VERR_SUPDRV_TRACER_NOT_REGISTERED (-3723) 1657 1661 /** @} */ 1658 1662 -
trunk/include/VBox/sup.h
r40742 r40756 1276 1276 1277 1277 1278 /** @name Tracing 1279 * @{ */ 1280 1278 1281 struct VTGOBJHDR; 1282 1283 /** 1284 * Tracer data associated with a provider. 1285 */ 1286 typedef union SUPDRVTRACERDATA 1287 { 1288 /** Generic */ 1289 uint64_t au64[2]; 1290 1291 /** DTrace data. */ 1292 struct 1293 { 1294 /** Provider ID. */ 1295 uintptr_t idProvider; 1296 /** The number of trace points. */ 1297 uint32_t volatile cTracepoints; 1298 } DTrace; 1299 } SUPDRVTRACERDATA; 1300 /** Pointer to the tracer data associated with a provider. */ 1301 typedef SUPDRVTRACERDATA *PSUPDRVTRACERDATA; 1302 1303 /** 1304 * Support driver tracepoint provider core. 1305 */ 1306 typedef struct SUPDRVVDTPROVIDERCORE 1307 { 1308 /** The tracer data member. */ 1309 SUPDRVTRACERDATA TracerData; 1310 /** The provider descriptor. */ 1311 struct VTGDESCPROVIDER *pDesc; 1312 /** The VTG header. */ 1313 struct VTGOBJHDR *pHdr; 1314 /** Pointer to the provider name (a copy that's always available). */ 1315 const char *pszName; 1316 } SUPDRVVDTPROVIDERCORE; 1317 /** Pointer to a tracepoint provider core structure. */ 1318 typedef SUPDRVVDTPROVIDERCORE *PSUPDRVVDTPROVIDERCORE; 1319 1320 1321 /** Pointer to a tracer registration record. */ 1322 typedef struct SUPDRVTRACERREG const *PCSUPDRVTRACERREG; 1323 /** 1324 * Support driver tracer registration record. 1325 */ 1326 typedef struct SUPDRVTRACERREG 1327 { 1328 /** Magic value (SUPDRVTRACERREG_MAGIC). */ 1329 uint32_t u32Magic; 1330 /** Version (SUPDRVTRACERREG_VERSION). */ 1331 uint32_t u32Version; 1332 1333 DECLR0CALLBACKMEMBER(int, pfnTodo1, (PCSUPDRVTRACERREG pThis)); 1334 DECLR0CALLBACKMEMBER(int, pfnTodo2, (PCSUPDRVTRACERREG pThis)); 1335 DECLR0CALLBACKMEMBER(int, pfnTodo3, (PCSUPDRVTRACERREG pThis)); 1336 DECLR0CALLBACKMEMBER(int, pfnTodo4, (PCSUPDRVTRACERREG pThis)); 1337 DECLR0CALLBACKMEMBER(int, pfnTodo5, (PCSUPDRVTRACERREG pThis)); 1338 1339 /** 1340 * Registers a provider. 1341 * 1342 * @returns VBox status code. 1343 * @param pThis Pointer to the registration record. 1344 * @param pCore The provider core data. 1345 */ 1346 DECLR0CALLBACKMEMBER(int, pfnRegisterProvider, (PCSUPDRVTRACERREG pThis, PSUPDRVVDTPROVIDERCORE pCore)); 1347 1348 /** 1349 * Attempts to deregisters a provider. 1350 * 1351 * @returns VINF_SUCCESS or VERR_TRY_AGAIN. If the latter, the provider 1352 * should be made as harmless as possible before returning as the 1353 * VTG object and associated code will be unloaded upon return. 1354 * 1355 * @param pThis Pointer to the registration record. 1356 * @param pCore The provider core data. 1357 */ 1358 DECLR0CALLBACKMEMBER(int, pfnDeregisterProvider, (PCSUPDRVTRACERREG pThis, PSUPDRVVDTPROVIDERCORE pCore)); 1359 1360 /** 1361 * Make another attempt at unregister a busy provider. 1362 * 1363 * @returns VINF_SUCCESS or VERR_TRY_AGAIN. 1364 * @param pThis Pointer to the registration record. 1365 * @param pCore The provider core data. 1366 */ 1367 DECLR0CALLBACKMEMBER(int, pfnDeregisterZombieProvider, (PCSUPDRVTRACERREG pThis, PSUPDRVVDTPROVIDERCORE pCore)); 1368 1369 /** End marker (SUPDRVTRACERREG_MAGIC). */ 1370 uintptr_t uEndMagic; 1371 } SUPDRVTRACERREG; 1372 1373 /** Tracer magic (Kenny Garrett). */ 1374 #define SUPDRVTRACERREG_MAGIC UINT32_C(0x19601009) 1375 /** Tracer registration structure version. */ 1376 #define SUPDRVTRACERREG_VERSION RT_MAKE_U32(0, 1) 1377 1378 /** Pointer to a trace helper structure. */ 1379 typedef struct SUPDRVTRACERHLP const *PCSUPDRVTRACERHLP; 1380 /** 1381 * Helper structure. 1382 */ 1383 typedef struct SUPDRVTRACERHLP 1384 { 1385 /** The structure version (SUPDRVTRACERHLP_VERSION). */ 1386 uintptr_t uVersion; 1387 1388 /** @todo ... */ 1389 1390 /** End marker (SUPDRVTRACERHLP_VERSION) */ 1391 uintptr_t uEndVersion; 1392 } SUPDRVTRACERHLP; 1393 /** Tracer helper structure version. */ 1394 #define SUPDRVTRACERHLP_VERSION RT_MAKE_U32(0, 1) 1395 1279 1396 SUPR0DECL(int) SUPR0VtgRegisterDrv(PSUPDRVSESSION pSession, struct VTGOBJHDR *pVtgHdr, const char *pszName); 1280 1397 SUPR0DECL(void) SUPR0VtgDeregisterDrv(PSUPDRVSESSION pSession); … … 1282 1399 uintptr_t uArg3, uintptr_t uArg4); 1283 1400 SUPR0DECL(int) SUPR0VtgRegisterModule(void *hMod, struct VTGOBJHDR *pVtgHdr); 1401 /** @} */ 1402 1284 1403 1285 1404 /**
Note:
See TracChangeset
for help on using the changeset viewer.