class FakePciroot

Defined at line 27 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

This FakePciroot class for the moment is a stub and test files

will specialize the methods they need. Eventually when more tests

are sorted out it may make sense to have pciroot tests be similar

to the mock-i2c style fakes.

Public Members

static const uint64_t kDefaultHighMemoryAddress
static const uint32_t kDefaultLowMemoryAddress
static const uint16_t kDefaultIoAddress

Public Methods

void FakePciroot (uint8_t bus_start, uint8_t bus_cnt, bool is_extended)

By default, pciroot won't populate an ecam unless it's called with Create().

Defined at line 33 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

void FakePciroot ()

Defined at line 46 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

void FakePciroot (FakePciroot && )

Defined at line 48 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

pciroot_protocol_t * proto ()

Defined at line 50 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

pci_platform_info_t info ()

Defined at line 51 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

FakeEcam & ecam ()

Defined at line 66 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

uint8_t bus_start ()

Defined at line 67 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

uint8_t bus_end ()

Defined at line 68 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

bool is_extended ()

Defined at line 69 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx::bti & bti ()

Defined at line 70 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx::resource & resource ()

Defined at line 71 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

std::vector<pci_legacy_irq_t> & legacy_irqs ()

Defined at line 72 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

std::vector<pci_irq_routing_entry_t> & routing_entries ()

Defined at line 73 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

std::vector<zx::eventpair> & allocation_eps ()

Defined at line 74 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

std::vector<pci_bdf_t> & acpi_devices ()

Defined at line 75 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootGetBti (uint32_t bdf, uint32_t index, zx::bti * bti)

Protocol methods.

Defined at line 78 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootConnectSysmem (zx::channel connection)

Defined at line 86 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootGetPciPlatformInfo (pci_platform_info_t * out_info)

Defined at line 94 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

bool PcirootDriverShouldProxyConfig ()

Defined at line 103 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootReadConfig8 (const pci_bdf_t * address, uint16_t offset, uint8_t * value)

Defined at line 104 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootReadConfig16 (const pci_bdf_t * address, uint16_t offset, uint16_t * value)

Defined at line 116 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootReadConfig32 (const pci_bdf_t * address, uint16_t offset, uint32_t * value)

Defined at line 128 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootWriteConfig8 (const pci_bdf_t * address, uint16_t offset, uint8_t value)

Defined at line 139 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootWriteConfig16 (const pci_bdf_t * address, uint16_t offset, uint16_t value)

Defined at line 150 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootWriteConfig32 (const pci_bdf_t * address, uint16_t offset, uint32_t value)

Defined at line 161 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootAllocateMsi (uint32_t requested_irqs, bool can_target_64bit, zx::msi * out_allocation)

Defined at line 173 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

zx_status_t PcirootGetAddressSpace (zx_paddr_t in_base, size_t size, pci_address_space_t type, bool low, uint64_t * out_base, zx::resource * resource, zx::eventpair * eventpair)

Defined at line 183 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

void enable_get_bti (bool enable)

Defined at line 215 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

void enable_connect_sysmem (bool enable)

Defined at line 216 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

void enable_get_pci_platform_info (bool enable)

Defined at line 217 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

void enable_driver_should_proxy_config (bool enable)

Defined at line 218 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

void enable_config_read (bool enable)

Defined at line 221 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

void enable_config_write (bool enable)

Defined at line 222 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

void enable_allocate_msi (bool enable)

Defined at line 223 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h

void enable_get_address_space (bool enable)

Defined at line 224 of file ../../src/devices/bus/drivers/pci/test/fakes/fake_pciroot.h