MCPcopy Create free account
hub / github.com/cloud-hypervisor/cloud-hypervisor / drop

Method drop

pci/src/vfio.rs:1865–1883  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

1863
1864impl Drop for VfioPciDevice {
1865 fn drop(&mut self) {
1866 self.unmap_mmio_regions();
1867
1868 if let Some(msix) = &self.common.interrupt.msix
1869 && msix.bar.enabled()
1870 {
1871 self.common.disable_msix();
1872 }
1873
1874 if let Some(msi) = &self.common.interrupt.msi
1875 && msi.cfg.enabled()
1876 {
1877 self.common.disable_msi();
1878 }
1879
1880 if self.common.interrupt.intx_in_use() {
1881 self.common.disable_intx();
1882 }
1883 }
1884}
1885
1886impl BusDevice for VfioPciDevice {

Callers

nothing calls this directly

Calls 6

intx_in_useMethod · 0.80
disable_intxMethod · 0.80
unmap_mmio_regionsMethod · 0.45
enabledMethod · 0.45
disable_msixMethod · 0.45
disable_msiMethod · 0.45

Tested by

no test coverage detected