mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-27 03:13:23 +00:00
Revise the BlockDevice
trait
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
e83e1fc01b
commit
ff525112d0
@ -19,7 +19,7 @@ mod test {
|
||||
|
||||
use aster_block::{
|
||||
bio::{BioEnqueueError, BioStatus, BioType, SubmittedBio},
|
||||
BlockDevice,
|
||||
BlockDevice, BlockDeviceMeta,
|
||||
};
|
||||
use ostd::{
|
||||
mm::{FrameAllocOptions, Segment, VmIo},
|
||||
@ -99,8 +99,11 @@ mod test {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
fn max_nr_segments_per_bio(&self) -> usize {
|
||||
usize::MAX
|
||||
fn metadata(&self) -> BlockDeviceMeta {
|
||||
BlockDeviceMeta {
|
||||
max_nr_segments_per_bio: usize::MAX,
|
||||
nr_sectors: self.sectors_count(),
|
||||
}
|
||||
}
|
||||
}
|
||||
/// Exfat disk image
|
||||
|
Reference in New Issue
Block a user