VirtualBox

Ignore:
Timestamp:
Oct 30, 2019 2:14:10 PM (5 years ago)
Author:
vboxsync
Message:

Devices: Use PDMDEVINS_2_DATA and PDMDEVINS_2_DATA. bugref:9218

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/PC/DevACPI.cpp

    r81514 r81591  
    10761076static DECLCALLBACK(void) acpiR3PmTimer(PPDMDEVINS pDevIns, PTMTIMER pTimer, void *pvUser)
    10771077{
    1078     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     1078    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    10791079    Assert(TMTimerIsLockOwner(pTimer));
    10801080    RT_NOREF(pvUser);
     
    17301730        return VERR_IOM_IOPORT_UNUSED;
    17311731
    1732     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     1732    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    17331733
    17341734    /*
     
    17831783{
    17841784    RT_NOREF(pszArgs);
    1785     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     1785    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    17861786    pHlp->pfnPrintf(pHlp,
    17871787                    "timer: old=%08RX32, current=%08RX32\n", pThis->uPmTimeA, pThis->uPmTimeB);
     
    24962496static DECLCALLBACK(int) acpiR3SaveState(PPDMDEVINS pDevIns, PSSMHANDLE pSSM)
    24972497{
    2498     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     2498    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    24992499    return SSMR3PutStruct(pSSM, pThis, &g_AcpiSavedStateFields8[0]);
    25002500}
     
    25052505static DECLCALLBACK(int) acpiR3LoadState(PPDMDEVINS pDevIns, PSSMHANDLE pSSM, uint32_t uVersion, uint32_t uPass)
    25062506{
    2507     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     2507    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    25082508    Assert(uPass == SSM_PASS_FINAL); NOREF(uPass);
    25092509
     
    33693369                                                       uint32_t uAddress, unsigned cb, uint32_t u32Value)
    33703370{
    3371     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     3371    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    33723372
    33733373    Log2(("acpi: PCI config write: 0x%x -> 0x%x (%d)\n", u32Value, uAddress, cb));
     
    34303430static DECLCALLBACK(int) acpiR3Attach(PPDMDEVINS pDevIns, unsigned iLUN, uint32_t fFlags)
    34313431{
    3432     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     3432    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    34333433    LogFlow(("acpiAttach: pDevIns=%p iLUN=%u fFlags=%#x\n", pDevIns, iLUN, fFlags));
    34343434
     
    34753475static DECLCALLBACK(void) acpiR3Detach(PPDMDEVINS pDevIns, unsigned iLUN, uint32_t fFlags)
    34763476{
    3477     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     3477    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    34783478
    34793479    LogFlow(("acpiDetach: pDevIns=%p iLUN=%u fFlags=%#x\n", pDevIns, iLUN, fFlags));
     
    35073507static DECLCALLBACK(void) acpiR3Resume(PPDMDEVINS pDevIns)
    35083508{
    3509     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     3509    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    35103510    if (pThis->fSetWakeupOnResume)
    35113511    {
     
    35223522{
    35233523    RT_NOREF1(enmCtx);
    3524     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     3524    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    35253525    acpiR3PlantTables(pThis);
    35263526}
     
    35313531static DECLCALLBACK(void) acpiR3Reset(PPDMDEVINS pDevIns)
    35323532{
    3533     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     3533    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    35343534
    35353535    /* Play safe: make sure that the IRQ isn't stuck after a reset. */
     
    35693569static DECLCALLBACK(void) acpiR3Relocate(PPDMDEVINS pDevIns, RTGCINTPTR offDelta)
    35703570{
    3571     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     3571    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    35723572    pThis->pDevInsRC = PDMDEVINS_2_RCPTR(pDevIns);
    35733573    pThis->pPmTimerRC = TMTimerRCPtr(pThis->pPmTimerR3);
     
    35813581{
    35823582    PDMDEV_CHECK_VERSIONS_RETURN(pDevIns);
    3583     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     3583    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    35843584    for (uint8_t i = 0; i < pThis->cCustTbls; i++)
    35853585    {
     
    35993599{
    36003600    PDMDEV_CHECK_VERSIONS_RETURN(pDevIns);
    3601     ACPIState *pThis = PDMINS_2_DATA(pDevIns, ACPIState *);
     3601    ACPIState *pThis = PDMDEVINS_2_DATA(pDevIns, ACPIState *);
    36023602
    36033603    /*
Note: See TracChangeset for help on using the changeset viewer.

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