mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-21 16:33:24 +00:00
Separate SegmentSlice
from Segment
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
d930829866
commit
909639fd70
@ -152,9 +152,9 @@ impl DmaPage {
|
||||
pool: Weak<DmaPool>,
|
||||
) -> Result<Self, ostd::Error> {
|
||||
let dma_stream = {
|
||||
let vm_segment = FrameAllocOptions::new(1).alloc_contiguous()?;
|
||||
let segment = FrameAllocOptions::new(1).alloc_contiguous()?;
|
||||
|
||||
DmaStream::map(vm_segment, direction, is_cache_coherent)
|
||||
DmaStream::map(segment, direction, is_cache_coherent)
|
||||
.map_err(|_| ostd::Error::AccessDenied)?
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user