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

Function create_dsdt_table

vmm/src/acpi.rs:259–276  ·  view source on GitHub ↗
(
    device_manager: &DeviceManager,
    cpu_manager: &CpuManager,
    memory_manager: &MemoryManager,
)

Source from the content-addressed store, hash-verified

257}
258
259pub fn create_dsdt_table(
260 device_manager: &DeviceManager,
261 cpu_manager: &CpuManager,
262 memory_manager: &MemoryManager,
263) -> Sdt {
264 trace_scoped!("create_dsdt_table");
265 // DSDT
266 let mut dsdt = Sdt::new(*b"DSDT", 36, 6, *b"CLOUDH", *b"CHDSDT ", 1);
267
268 let mut bytes = Vec::new();
269
270 device_manager.to_aml_bytes(&mut bytes);
271 cpu_manager.to_aml_bytes(&mut bytes);
272 memory_manager.to_aml_bytes(&mut bytes);
273 dsdt.append_slice(&bytes);
274
275 dsdt
276}
277
278const FACP_DSDT_OFFSET: usize = 140;
279

Callers 1

Calls 2

newFunction · 0.85
to_aml_bytesMethod · 0.45

Tested by

no test coverage detected