Struct kernel::drivers::disk::Disk [] [src]

pub struct Disk {
    pub irq: u8,
    // some fields omitted
}

A disk (data storage)

Fields

irq

Methods

impl Disk

fn primary_master(base: u16) -> Self

Get the primary master

fn primary_slave(base: u16) -> Self

Get the primary slave

fn secondary_master(base: u16) -> Self

Get the secondary master

fn secondary_slave(base: u16) -> Self

Get the secondary slave

unsafe fn identify(&self) -> bool

Identify

unsafe fn read(&self, lba: u64, count: u16, destination: usize) -> u8

Read from the disk

unsafe fn write(&self, lba: u64, count: u16, source: usize) -> u8

Write to the disk

fn request(&mut self, request: Request)

Send request

unsafe fn on_poll(&mut self)