VBoxPciInternal.h revision 89fcb45a9b123043e94c06d32799c2a7fcc2af7d
c285785ffc9f35513e0c6e7e2a05df3090dc919cvboxsync * VBoxPci - PCI driver (Host), Internal Header.
c285785ffc9f35513e0c6e7e2a05df3090dc919cvboxsync * Copyright (C) 2011 Oracle Corporation
c285785ffc9f35513e0c6e7e2a05df3090dc919cvboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
c285785ffc9f35513e0c6e7e2a05df3090dc919cvboxsync * available from http://www.virtualbox.org. This file is free software;
c285785ffc9f35513e0c6e7e2a05df3090dc919cvboxsync * you can redistribute it and/or modify it under the terms of the GNU
c285785ffc9f35513e0c6e7e2a05df3090dc919cvboxsync * General Public License (GPL) as published by the Free Software
c285785ffc9f35513e0c6e7e2a05df3090dc919cvboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
c285785ffc9f35513e0c6e7e2a05df3090dc919cvboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
c285785ffc9f35513e0c6e7e2a05df3090dc919cvboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync/* Forward declaration. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsynctypedef struct VBOXRAWPCIGLOBALS *PVBOXRAWPCIGLOBALS;
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync * The per-instance data of the VBox raw PCI interface.
89fcb45a9b123043e94c06d32799c2a7fcc2af7dvboxsync * This is data associated with a host PCI card attached to the VM.
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** Pointer to the globals. */
80559ecb51cb45f6869d8450a1317ead0dd5129dvboxsync /** Mutex protecting device access. */
80559ecb51cb45f6869d8450a1317ead0dd5129dvboxsync /** The spinlock protecting the state variables and device access. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** Pointer to the next device in the list. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** Reference count. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /* Host PCI address of this device. */
89fcb45a9b123043e94c06d32799c2a7fcc2af7dvboxsync /** Temporary: host IRQ we were given. Assumes single IRQ devices. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** Port, given to the outside world. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync * The global data of the VBox PCI driver.
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync * This contains the bit required for communicating with support driver, VBoxDrv
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync * (start out as SupDrv).
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** Mutex protecting the list of instances and state changes. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** Pointer to a list of instance data. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** The raw PCI interface factory. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** The SUPDRV component factory registration. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** The number of current factory references. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** Whether the IDC connection is open or not.
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync * This is only for cleaning up correctly after the separate IDC init on Windows. */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsync /** The SUPDRV IDC handle (opaque struct). */
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsyncDECLHIDDEN(int) vboxPciInit(PVBOXRAWPCIGLOBALS pGlobals);
f73c68fe41a3db55167b7266efd6955e5dbd0b47vboxsyncDECLHIDDEN(void) vboxPciShutdown(PVBOXRAWPCIGLOBALS pGlobals);
bcf9fab594306cd97251f7f03b8319a158c29ea5vboxsyncDECLHIDDEN(int) vboxPciOsDevInit (PVBOXRAWPCIINS pIns, uint32_t fFlags);
bcf9fab594306cd97251f7f03b8319a158c29ea5vboxsyncDECLHIDDEN(int) vboxPciOsDevDeinit(PVBOXRAWPCIINS pIns, uint32_t fFlags);
89fcb45a9b123043e94c06d32799c2a7fcc2af7dvboxsyncDECLHIDDEN(int) vboxPciOsDevDestroy(PVBOXRAWPCIINS pIns);
2c709acd5e2f434e71614aa89020bf8d0776a1e9vboxsyncDECLHIDDEN(int) vboxPciOsDevGetRegionInfo(PVBOXRAWPCIINS pIns,
c97d00f4828608e3ac87e48fee3dfa8bc4437bf1vboxsyncDECLHIDDEN(int) vboxPciOsDevMapRegion(PVBOXRAWPCIINS pIns,
c97d00f4828608e3ac87e48fee3dfa8bc4437bf1vboxsyncDECLHIDDEN(int) vboxPciOsDevUnmapRegion(PVBOXRAWPCIINS pIns,
2c709acd5e2f434e71614aa89020bf8d0776a1e9vboxsyncDECLHIDDEN(int) vboxPciOsDevPciCfgWrite(PVBOXRAWPCIINS pIns, uint32_t Register, PCIRAWMEMLOC *pValue);
2c709acd5e2f434e71614aa89020bf8d0776a1e9vboxsyncDECLHIDDEN(int) vboxPciOsDevPciCfgRead (PVBOXRAWPCIINS pIns, uint32_t Register, PCIRAWMEMLOC *pValue);
1fff175c9a0fea173ee52a209224dc6ecbd39572vboxsyncDECLHIDDEN(int) vboxPciOsDevRegisterIrqHandler (PVBOXRAWPCIINS pIns, PFNRAWPCIISR pfnHandler, void* pIrqContext, int32_t *piHostIrq);