VirtualBox

Changeset 2269 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Apr 20, 2007 12:58:05 PM (18 years ago)
Author:
vboxsync
Message:

Stricter pointer typechecking. (R0 vs R3)

Location:
trunk/src/VBox/Devices
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Graphics/DevVGA.cpp

    r2113 r2269  
    40794079                                                      GCPhysAddress, GCPhysAddress + (pData->vram_size - 1),
    40804080                                                      vgaR3LFBAccessHandler, pData,
    4081                                                       g_DeviceVga.szR0Mod, "vgaR0LFBAccessHandler", pData->pDevInsHC->pvInstanceDataHC,
     4081                                                      g_DeviceVga.szR0Mod, "vgaR0LFBAccessHandler", pData->pDevInsHC->pvInstanceDataR0,
    40824082                                                      g_DeviceVga.szGCMod, "vgaGCLFBAccessHandler", pData->pDevInsHC->pvInstanceDataGC,
    40834083                                                      "VGA LFB");
  • trunk/src/VBox/Devices/PC/DevPIC.cpp

    r490 r2269  
    992992        pData->pPicHlpR0 = pData->pPicHlpR3->pfnGetR0Helpers(pDevIns);
    993993
    994         rc = PDMDevHlpIOPortRegisterR0(pDevIns,  0x20, 2, (void *)0, "picIOPortWrite", "picIOPortRead", NULL, NULL, "i8259 PIC #0");
     994        rc = PDMDevHlpIOPortRegisterR0(pDevIns,  0x20, 2, 0, "picIOPortWrite", "picIOPortRead", NULL, NULL, "i8259 PIC #0");
    995995        if (VBOX_FAILURE(rc))
    996996            return rc;
    997         rc = PDMDevHlpIOPortRegisterR0(pDevIns,  0xa0, 2, (void *)1, "picIOPortWrite", "picIOPortRead", NULL, NULL, "i8259 PIC #1");
     997        rc = PDMDevHlpIOPortRegisterR0(pDevIns,  0xa0, 2, 1, "picIOPortWrite", "picIOPortRead", NULL, NULL, "i8259 PIC #1");
    998998        if (VBOX_FAILURE(rc))
    999999            return rc;
     
    10221022    if (fR0Enabled)
    10231023    {
    1024         rc = PDMDevHlpIOPortRegisterR0(pDevIns, 0x4d0, 1, &pData->aPics[0],
     1024        RTR0PTR pDataR0 = PDMINS2DATA_R0PTR(pDevIns);
     1025        rc = PDMDevHlpIOPortRegisterR0(pDevIns, 0x4d0, 1, pDataR0 + RT_OFFSETOF(DEVPIC, aPics[0]),
    10251026                                       "picIOPortElcrWrite", "picIOPortElcrRead", NULL, NULL, "i8259 PIC #0 - elcr");
    10261027        if (VBOX_FAILURE(rc))
    10271028            return rc;
    1028         rc = PDMDevHlpIOPortRegisterR0(pDevIns, 0x4d1, 1, &pData->aPics[1],
     1029        rc = PDMDevHlpIOPortRegisterR0(pDevIns, 0x4d1, 1, pDataR0 + RT_OFFSETOF(DEVPIC, aPics[1]),
    10291030                                       "picIOPortElcrWrite", "picIOPortElcrRead", NULL, NULL, "i8259 PIC #1 - elcr");
    10301031        if (VBOX_FAILURE(rc))
  • trunk/src/VBox/Devices/Storage/DevATA.cpp

    r2216 r2269  
    45894589        {
    45904590            rc2 = PDMDevHlpIOPortRegisterR0(pPciDev->pDevIns, (RTIOPORT)GCPhysAddress + i * 8, 8,
    4591                                             (RTHCPTR)i, "ataBMDMAIOPortWrite", "ataBMDMAIOPortRead", NULL, NULL, "ATA Bus Master DMA");
     4591                                            (RTR0PTR)i, "ataBMDMAIOPortWrite", "ataBMDMAIOPortRead", NULL, NULL, "ATA Bus Master DMA");
    45924592            AssertRC(rc2);
    45934593            if (rc2 < rc)
     
    57845784        {
    57855785#if 1
    5786             rc = PDMDevHlpIOPortRegisterR0(pDevIns, pData->aCts[i].IOPortBase1, 8, (RTHCPTR)i,
     5786            rc = PDMDevHlpIOPortRegisterR0(pDevIns, pData->aCts[i].IOPortBase1, 8, (RTR0PTR)i,
    57875787                                           "ataIOPortWrite1", "ataIOPortRead1", NULL, NULL, "ATA I/O Base 1");
    57885788#else
    5789             rc = PDMDevHlpIOPortRegisterR0(pDevIns, pData->aCts[i].IOPortBase1, 8, (RTHCPTR)i,
     5789            rc = PDMDevHlpIOPortRegisterR0(pDevIns, pData->aCts[i].IOPortBase1, 8, (RTR0PTR)i,
    57905790                                           "ataIOPortWrite1", "ataIOPortRead1", "ataIOPortWriteStr1", "ataIOPortReadStr1", "ATA I/O Base 1");
    57915791#endif
     
    58085808        if (fR0Enabled)
    58095809        {
    5810             rc = PDMDevHlpIOPortRegisterR0(pDevIns, pData->aCts[i].IOPortBase2, 1, (RTHCPTR)i,
     5810            rc = PDMDevHlpIOPortRegisterR0(pDevIns, pData->aCts[i].IOPortBase2, 1, (RTR0PTR)i,
    58115811                                           "ataIOPortWrite2", "ataIOPortRead2", NULL, NULL, "ATA I/O Base 2");
    58125812            if (VBOX_FAILURE(rc))
  • trunk/src/VBox/Devices/testcase/tstDeviceStructSizeGC.cpp

    r2246 r2269  
    8989    GEN_CHECK_OFF(PDMDEVINS, pCfgHandle);
    9090    GEN_CHECK_OFF(PDMDEVINS, iInstance);
    91     GEN_CHECK_OFF(PDMDEVINS, pvInstanceDataHC);
     91    GEN_CHECK_OFF(PDMDEVINS, pvInstanceDataR3);
    9292    GEN_CHECK_OFF(PDMDEVINS, pvInstanceDataGC);
     93    GEN_CHECK_OFF(PDMDEVINS, pvInstanceDataR0);
    9394    GEN_CHECK_OFF(PDMDEVINS, IBase);
    9495    GEN_CHECK_OFF(PDMDEVINS, achInstanceData);
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