VirtualBox

Changeset 83281 in vbox for trunk/include/VBox/vmm


Ignore:
Timestamp:
Mar 13, 2020 1:02:08 PM (5 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
136437
Message:

PDMDevHlp,tstDevice: Create two more wrappers used by the graphics device to eliminate direct imports from the VMM library

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/VBox/vmm/pdmdev.h

    r83263 r83281  
    4444#include <VBox/vmm/ssm.h>
    4545#include <VBox/vmm/cfgm.h>
     46#include <VBox/vmm/cpum.h>
    4647#include <VBox/vmm/dbgf.h>
     48#include <VBox/vmm/pgm.h> /* PGMR3HandlerPhysicalTypeRegister() argument types. */
    4749#include <VBox/err.h>  /* VINF_EM_DBG_STOP, also 120+ source files expecting this. */
    4850#include <iprt/stdarg.h>
     
    20862088
    20872089/** Current PDMDEVHLPR3 version number. */
    2088 #define PDM_DEVHLPR3_VERSION                    PDM_VERSION_MAKE_PP(0xffe7, 42, 0)
     2090#define PDM_DEVHLPR3_VERSION                    PDM_VERSION_MAKE_PP(0xffe7, 43, 0)
    20892091
    20902092/**
     
    39053907    DECLR3CALLBACKMEMBER(void, pfnPhysBulkReleasePageMappingLocks,(PPDMDEVINS pDevIns, uint32_t cPages, PPGMPAGEMAPLOCK paLocks));
    39063908
     3909    /**
     3910     * Returns the micro architecture used for the guest.
     3911     *
     3912     * @returns CPU micro architecture enum.
     3913     * @param   pDevIns             The device instance.
     3914     */
     3915    DECLR3CALLBACKMEMBER(CPUMMICROARCH, pfnCpuGetGuestMicroarch,(PPDMDEVINS pDevIns));
     3916
    39073917    /** Space reserved for future members.
    39083918     * @{ */
     
    41154125     */
    41164126    DECLR3CALLBACKMEMBER(void *, pfnQueryGenericUserObject,(PPDMDEVINS pDevIns, PCRTUUID pUuid));
     4127
     4128    /**
     4129     * Register a physical page access handler type.
     4130     *
     4131     * @returns VBox status code.
     4132     * @param   pDevIns             The device instance.
     4133     * @param   enmKind             The kind of access handler.
     4134     * @param   pfnHandlerR3        Pointer to the ring-3 handler callback.
     4135     * @param   pszModR0            The name of the ring-0 module, NULL is an alias for
     4136     *                              the main ring-0 module.
     4137     * @param   pszHandlerR0        The name of the ring-0 handler, NULL if the ring-3
     4138     *                              handler should be called.
     4139     * @param   pszPfHandlerR0      The name of the ring-0 \#PF handler, NULL if the
     4140     *                              ring-3 handler should be called.
     4141     * @param   pszModRC            The name of the raw-mode context module, NULL is an
     4142     *                              alias for the main RC module.
     4143     * @param   pszHandlerRC        The name of the raw-mode context handler, NULL if
     4144     *                              the ring-3 handler should be called.
     4145     * @param   pszPfHandlerRC      The name of the raw-mode context \#PF handler, NULL
     4146     *                              if the ring-3 handler should be called.
     4147     * @param   pszDesc             The type description.
     4148     * @param   phType              Where to return the type handle (cross context
     4149     *                              safe).
     4150     */
     4151    DECLR3CALLBACKMEMBER(int, pfnPGMHandlerPhysicalTypeRegister, (PPDMDEVINS pDevIns, PGMPHYSHANDLERKIND enmKind,
     4152                                                                  R3PTRTYPE(PFNPGMPHYSHANDLER) pfnHandlerR3,
     4153                                                                  const char *pszHandlerR0, const char *pszPfHandlerR0,
     4154                                                                  const char *pszHandlerRC, const char *pszPfHandlerRC,
     4155                                                                  const char *pszDesc, PPGMPHYSHANDLERTYPE phType));
    41174156
    41184157    /** @} */
     
    61976236{
    61986237    pDevIns->CTX_SUFF(pHlp)->pfnPhysBulkReleasePageMappingLocks(pDevIns, cPages, paLocks);
     6238}
     6239
     6240/**
     6241 * @copydoc PDMDEVHLPR3::pfnCpuGetGuestMicroarch
     6242 */
     6243DECLINLINE(CPUMMICROARCH) PDMDevHlpCpuGetGuestMicroarch(PPDMDEVINS pDevIns)
     6244{
     6245    return pDevIns->CTX_SUFF(pHlp)->pfnCpuGetGuestMicroarch(pDevIns);
    61996246}
    62006247
     
    76847731}
    76857732
     7733/**
     7734 * @copydoc PDMDEVHLPR3::pfnPGMHandlerPhysicalTypeRegister
     7735 */
     7736DECLINLINE(int) PDMDevHlpPGMHandlerPhysicalTypeRegister(PPDMDEVINS pDevIns, PGMPHYSHANDLERKIND enmKind,
     7737                                                        R3PTRTYPE(PFNPGMPHYSHANDLER) pfnHandlerR3,
     7738                                                        const char *pszHandlerR0, const char *pszPfHandlerR0,
     7739                                                        const char *pszHandlerRC, const char *pszPfHandlerRC,
     7740                                                        const char *pszDesc, PPGMPHYSHANDLERTYPE phType)
     7741{
     7742    return pDevIns->pHlpR3->pfnPGMHandlerPhysicalTypeRegister(pDevIns, enmKind, pfnHandlerR3,
     7743                                                              pszHandlerR0, pszPfHandlerR0,
     7744                                                              pszHandlerRC, pszPfHandlerRC,
     7745                                                              pszDesc, phType);
     7746}
     7747
    76867748/** Wrapper around SSMR3GetU32 for simplifying getting enum values saved as uint32_t. */
    76877749# define PDMDEVHLP_SSM_GET_ENUM32_RET(a_pHlp, a_pSSM, a_enmDst, a_EnumType) \
Note: See TracChangeset for help on using the changeset viewer.

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