VirtualBox

Changeset 2596 in vbox


Ignore:
Timestamp:
May 11, 2007 5:13:13 PM (17 years ago)
Author:
vboxsync
Message:

Moved PFNPCICONFIGREAD and PFNPCICONFIGWRITE out in the open.

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/VBox/pci.h

    r480 r2596  
    7777typedef FNPCIIOREGIONMAP *PFNPCIIOREGIONMAP;
    7878
     79/**
     80 * Callback function for reading from the PCI configuration space.
     81 *
     82 * @returns The register value.
     83 * @param   pPciDev         Pointer to PCI device. Use pPciDev->pDevIns to get the device instance.
     84 * @param   Address         The configuration space register address. [0..255]
     85 * @param   cb              The register size. [1,2,4]
     86 */
     87typedef DECLCALLBACK(uint32_t) FNPCICONFIGREAD(PPCIDEVICE pPciDev, uint32_t Address, unsigned cb);
     88/** Pointer to a FNPCICONFIGREAD() function. */
     89typedef FNPCICONFIGREAD *PFNPCICONFIGREAD;
     90/** Pointer to a PFNPCICONFIGREAD. */
     91typedef PFNPCICONFIGREAD *PPFNPCICONFIGREAD;
     92
     93/**
     94 * Callback function for writing to the PCI configuration space.
     95 *
     96 * @param   pPciDev         Pointer to PCI device. Use pPciDev->pDevIns to get the device instance.
     97 * @param   Address         The configuration space register address. [0..255]
     98 * @param   u32Value        The value that's being written. The number of bits actually used from
     99 *                          this value is determined by the cb parameter.
     100 * @param   cb              The register size. [1,2,4]
     101 */
     102typedef DECLCALLBACK(void) FNPCICONFIGWRITE(PPCIDEVICE pPciDev, uint32_t Address, uint32_t u32Value, unsigned cb);
     103/** Pointer to a FNPCICONFIGWRITE() function. */
     104typedef FNPCICONFIGWRITE *PFNPCICONFIGWRITE;
     105/** Pointer to a PFNPCICONFIGWRITE. */
     106typedef PFNPCICONFIGWRITE *PPFNPCICONFIGWRITE;
     107
    79108/** Fixed I/O region number for ROM. */
    80109#define PCI_ROM_SLOT 6
  • trunk/src/VBox/Devices/Bus/DevPCI.cpp

    r2538 r2596  
    309309}
    310310
    311 static uint32_t pci_default_read_config(PCIDevice *d,
    312                                         uint32_t address, int len)
     311
     312static DECLCALLBACK(uint32_t) pci_default_read_config(PCIDevice *d, uint32_t address, unsigned len)
    313313{
    314314    uint32_t val;
     
    328328}
    329329
    330 static void pci_default_write_config(PCIDevice *d,
    331                                      uint32_t address, uint32_t val, int len)
    332 {
    333     int can_write, i;
     330static DECLCALLBACK(void) pci_default_write_config(PCIDevice *d, uint32_t address, uint32_t val, unsigned len)
     331{
     332    int can_write;
     333    unsigned i;
    334334    uint32_t end, addr;
    335335
  • trunk/src/VBox/Devices/Bus/PCIInternal.h

    r486 r2596  
    4040typedef PCIIOREGION *PPCIIOREGION;
    4141
    42 /** Pointer to pci_default_read_config. */
    43 typedef uint32_t    (*PFNPCICONFIGREAD)(PPCIDEVICE pPciDev, uint32_t u32CfgAddress, int cb);
    44 /** Pointer to pci_default_write_config. */
    45 typedef void        (*PFNPCICONFIGWRITE)(PPCIDEVICE pPciDev, uint32_t u32CfgAddress, uint32_t u32Data, int cb);
    46 
    4742/**
    4843 * PCI Device - Internal data.
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