pub struct AhciController { /* private fields */ }Expand description
AHCI Host Bus Adapter controller.
Implementations§
Source§impl AhciController
impl AhciController
Sourcepub fn new(mmio_base: usize) -> Result<Self, KernelError>
pub fn new(mmio_base: usize) -> Result<Self, KernelError>
Create a new AHCI controller from a mapped MMIO base address.
Sourcepub fn sata_ports(&self) -> Vec<&AhciPort>
pub fn sata_ports(&self) -> Vec<&AhciPort>
Get all detected SATA ports.
Sourcepub fn port_mut(&mut self, port_num: u8) -> Option<&mut AhciPort>
pub fn port_mut(&mut self, port_num: u8) -> Option<&mut AhciPort>
Get a mutable reference to a specific port by number.
Sourcepub fn port_count(&self) -> usize
pub fn port_count(&self) -> usize
Get the number of detected ports.