vmm: acpi: Take &T instead of &Arc<Mutex<T>>

Refactor ACPI table creation functions to accept borrowed
references, removing double indirection and moving locking
to callers.

Signed-off-by: Chinmoy <daschinmoyy21@gmail.com>
This commit is contained in:
Chinmoy
2026-02-16 22:28:31 +05:30
committed by Rob Bradford
parent 7461143194
commit ef9133a3ee
3 changed files with 43 additions and 58 deletions

View File

@@ -1756,7 +1756,7 @@ impl DeviceManager {
}
#[cfg(target_arch = "aarch64")]
pub fn get_interrupt_controller(&mut self) -> Option<&Arc<Mutex<gic::Gic>>> {
pub fn get_interrupt_controller(&self) -> Option<&Arc<Mutex<gic::Gic>>> {
self.interrupt_controller.as_ref()
}
@@ -1793,7 +1793,7 @@ impl DeviceManager {
}
#[cfg(target_arch = "riscv64")]
pub fn get_interrupt_controller(&mut self) -> Option<&Arc<Mutex<aia::Aia>>> {
pub fn get_interrupt_controller(&self) -> Option<&Arc<Mutex<aia::Aia>>> {
self.interrupt_controller.as_ref()
}