VirtualBox

Changeset 12982 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Oct 4, 2008 9:46:15 PM (16 years ago)
Author:
vboxsync
Message:

PDMDev* adjustments.

Location:
trunk/src/VBox/VMM
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/PDMDevHlp.cpp

    r12981 r12982  
    4747*   Defined Constants And Macros                                               *
    4848*******************************************************************************/
    49 /*
    50  * Allow physical read and writes from any thread
     49/** Allow physical read and writes from any thread.
     50 * (pdmR3DevHlp_PhysRead and pdmR3DevHlp_PhysWrite.)
    5151 */
    5252#define PDM_PHYS_READWRITE_FROM_ANY_THREAD
  • trunk/src/VBox/VMM/PDMDevMiscHlp.cpp

    r12980 r12982  
    5050    LogFlow(("pdmR3PicHlp_SetInterruptFF: caller='%s'/%d: VM_FF_INTERRUPT_PIC %d -> 1\n",
    5151             pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, VMCPU_FF_ISSET(pVM, 0, VM_FF_INTERRUPT_PIC)));
     52
    5253    /* for PIC we always deliver to CPU 0, MP use APIC */
    5354    VMCPU_FF_SET(pVM, 0, VM_FF_INTERRUPT_PIC);
    5455    REMR3NotifyInterruptSet(pVM);
    55     VMR3NotifyFF(pVM, true);
     56    VMR3NotifyFF(pVM, true); /** @todo SMP: notify the right cpu. */
    5657}
    5758
     
    6364    LogFlow(("pdmR3PicHlp_ClearInterruptFF: caller='%s'/%d: VM_FF_INTERRUPT_PIC %d -> 0\n",
    6465             pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, VMCPU_FF_ISSET(pDevIns->Internal.s.pVMR3, 0, VM_FF_INTERRUPT_PIC)));
     66
    6567    /* for PIC we always deliver to CPU 0, MP use APIC */
    6668    VMCPU_FF_CLEAR(pDevIns->Internal.s.pVMR3, 0, VM_FF_INTERRUPT_PIC);
     
    144146    PDMDEV_ASSERT_DEVINS(pDevIns);
    145147    PVM pVM = pDevIns->Internal.s.pVMR3;
    146     LogFlow(("pdmR3ApicHlp_SetInterruptFF: caller='%s'/%d: VM_FF_INTERRUPT %d -> 1\n",
    147              pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, VMCPU_FF_ISSET(pVM, idCpu, VM_FF_INTERRUPT_APIC)));
     148    LogFlow(("pdmR3ApicHlp_SetInterruptFF: caller='%s'/%d: VM_FF_INTERRUPT(%d) %d -> 1\n",
     149             pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, idCpu, VMCPU_FF_ISSET(pVM, idCpu, VM_FF_INTERRUPT_APIC)));
     150
    148151    VMCPU_FF_SET(pVM, idCpu, VM_FF_INTERRUPT_APIC);
    149152    REMR3NotifyInterruptSet(pVM);
    150     VMR3NotifyFF(pVM, true);
     153    VMR3NotifyFF(pVM, true);  /** @todo SMP: notify the right cpu. */
    151154}
    152155
     
    156159{
    157160    PDMDEV_ASSERT_DEVINS(pDevIns);
    158     LogFlow(("pdmR3ApicHlp_ClearInterruptFF: caller='%s'/%d: VM_FF_INTERRUPT %d -> 0\n",
    159              pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, VMCPU_FF_ISSET(pDevIns->Internal.s.pVMR3, idCpu, VM_FF_INTERRUPT_APIC)));
     161    LogFlow(("pdmR3ApicHlp_ClearInterruptFF: caller='%s'/%d: VM_FF_INTERRUPT(%d) %d -> 0\n",
     162             pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, idCpu, VMCPU_FF_ISSET(pDevIns->Internal.s.pVMR3, idCpu, VM_FF_INTERRUPT_APIC)));
     163
    160164    VMCPU_FF_CLEAR(pDevIns->Internal.s.pVMR3, idCpu, VM_FF_INTERRUPT_APIC);
    161165    REMR3NotifyInterruptClear(pDevIns->Internal.s.pVMR3);
     
    192196{
    193197    PDMDEV_ASSERT_DEVINS(pDevIns);
     198    LogFlow(("pdmR3ApicHlp_Lock: caller='%s'/%d: rc=%Rrc\n", pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, rc));
    194199    return pdmLockEx(pDevIns->Internal.s.pVMR3, rc);
    195200}
     
    200205{
    201206    PDMDEV_ASSERT_DEVINS(pDevIns);
     207    LogFlow(("pdmR3ApicHlp_Unlock: caller='%s'/%d:\n", pDevIns->pDevReg->szDeviceName, pDevIns->iInstance));
    202208    pdmUnlock(pDevIns->Internal.s.pVMR3);
    203209}
     
    285291{
    286292    PDMDEV_ASSERT_DEVINS(pDevIns);
     293    LogFlow(("pdmR3IoApicHlp_Lock: caller='%s'/%d: rc=%Rrc\n", pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, rc));
    287294    return pdmLockEx(pDevIns->Internal.s.pVMR3, rc);
    288295}
     
    293300{
    294301    PDMDEV_ASSERT_DEVINS(pDevIns);
     302    LogFlow(("pdmR3IoApicHlp_Unlock: caller='%s'/%d:\n", pDevIns->pDevReg->szDeviceName, pDevIns->iInstance));
    295303    pdmUnlock(pDevIns->Internal.s.pVMR3);
    296304}
     
    383391{
    384392    PDMDEV_ASSERT_DEVINS(pDevIns);
     393    LogFlow(("pdmR3PciHlp_Lock: caller='%s'/%d: rc=%Rrc\n", pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, rc));
    385394    return pdmLockEx(pDevIns->Internal.s.pVMR3, rc);
    386395}
     
    391400{
    392401    PDMDEV_ASSERT_DEVINS(pDevIns);
     402    LogFlow(("pdmR3PciHlp_Unlock: caller='%s'/%d:\n", pDevIns->pDevReg->szDeviceName, pDevIns->iInstance));
    393403    pdmUnlock(pDevIns->Internal.s.pVMR3);
    394404}
  • trunk/src/VBox/VMM/PDMDevice.cpp

    r12980 r12982  
    6565    /** VM Handle. */
    6666    PVM             pVM;
    67 } PDMDEVREGCBINT, *PPDMDEVREGCBINT;
     67} PDMDEVREGCBINT;
     68/** Pointer to a PDMDEVREGCBINT structure. */
     69typedef PDMDEVREGCBINT *PPDMDEVREGCBINT;
     70/** Pointer to a const PDMDEVREGCBINT structure. */
    6871typedef const PDMDEVREGCBINT *PCPDMDEVREGCBINT;
    6972
     
    7275*   Internal Functions                                                         *
    7376*******************************************************************************/
    74 __BEGIN_DECLS
    7577static DECLCALLBACK(int)    pdmR3DevReg_Register(PPDMDEVREGCB pCallbacks, PCPDMDEVREG pDevReg);
    7678static DECLCALLBACK(void *) pdmR3DevReg_MMHeapAlloc(PPDMDEVREGCB pCallbacks, size_t cb);
    77 
    78 static int pdmR3DevLoadModules(PVM pVM);
    79 static int pdmR3DevLoad(PVM pVM, PPDMDEVREGCBINT pRegCB, const char *pszFilename, const char *pszName);
    80 
    81 
    82 /*
    83  * Allow physical read and writes from any thread
    84  */
    85 #define PDM_PHYS_READWRITE_FROM_ANY_THREAD
    86 
    87 __END_DECLS
     79static int                  pdmR3DevLoadModules(PVM pVM);
     80static int                  pdmR3DevLoad(PVM pVM, PPDMDEVREGCBINT pRegCB, const char *pszFilename, const char *pszName);
     81
    8882
    8983
     
    594588
    595589
    596 
    597590/**
    598591 * Registers a device with the current VM instance.
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