Commit 08a3800e authored by 4lDO2's avatar 4lDO2 🖖

Also allow ?Sized types to get the physaddr.

parent a2938fc7
......@@ -49,10 +49,13 @@ impl<T> Dma<T> {
virt: virt
})
}
}
impl<T: ?Sized> Dma<T> {
pub fn physical(&self) -> usize {
self.phys.address
}
}
impl<T> Dma<[T]> {
/// Crates a new DMA buffer with a size only known at runtime.
/// ## Safety
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment