1
/* $Id: BusAssignmentManager.h 34876 2010-12-09 11:16:00Z vboxsync $ */
5
* VirtualBox bus slots assignment manager
9
* Copyright (C) 2010 Oracle Corporation
11
* This file is part of VirtualBox Open Source Edition (OSE), as
12
* available from http://www.virtualbox.org. This file is free software;
13
* you can redistribute it and/or modify it under the terms of the GNU
14
* General Public License (GPL) as published by the Free Software
15
* Foundation, in version 2 as it comes in the "COPYING" file of the
16
* VirtualBox OSE distribution. VirtualBox OSE is distributed in the
17
* hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
19
#ifndef __BusAssignmentManager_h
20
#define __BusAssignmentManager_h
22
#include "VBox/types.h"
24
#include "VirtualBoxBase.h"
26
class BusAssignmentManager
32
BusAssignmentManager();
33
virtual ~BusAssignmentManager();
36
static BusAssignmentManager* createInstance(ChipsetType_T chipsetType);
37
virtual void AddRef();
38
virtual void Release();
40
virtual HRESULT assignPciDevice(const char* pszDevName, PCFGMNODE pCfg, PciBusAddress& Address, bool fAddressRequired = false);
41
virtual HRESULT assignPciDevice(const char* pszDevName, PCFGMNODE pCfg)
43
PciBusAddress Address;
44
return assignPciDevice(pszDevName, pCfg, Address, false);
46
virtual bool findPciAddress(const char* pszDevName, int iInstance, PciBusAddress& Address);
47
virtual bool hasPciDevice(const char* pszDevName, int iInstance)
49
PciBusAddress Address;
50
return findPciAddress(pszDevName, iInstance, Address);
52
virtual void listAttachedPciDevices(ComSafeArrayOut(IPciDeviceAttachment*, aAttached));
55
#endif // __BusAssignmentManager_h