(&self)
| 1181 | |
| 1182 | #[cfg(target_arch = "x86_64")] |
| 1183 | fn enable_split_irq(&self) -> vm::Result<()> { |
| 1184 | // Create split irqchip |
| 1185 | // Only the local APIC is emulated in kernel, both PICs and IOAPIC |
| 1186 | // are not. |
| 1187 | let mut cap = kvm_enable_cap { |
| 1188 | cap: KVM_CAP_SPLIT_IRQCHIP, |
| 1189 | ..Default::default() |
| 1190 | }; |
| 1191 | cap.args[0] = NUM_IOAPIC_PINS as u64; |
| 1192 | self.fd |
| 1193 | .enable_cap(&cap) |
| 1194 | .map_err(|e| vm::HypervisorVmError::EnableSplitIrq(e.into()))?; |
| 1195 | Ok(()) |
| 1196 | } |
| 1197 | |
| 1198 | #[cfg(target_arch = "x86_64")] |
| 1199 | fn enable_x2apic_api(&self) -> vm::Result<()> { |
no outgoing calls
no test coverage detected