mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-22 08:53:29 +00:00
Avoid generic_const_exprs
feature
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
b08e655a76
commit
0d36375dfa
@ -2,7 +2,7 @@
|
||||
|
||||
use aster_util::safe_ptr::SafePtr;
|
||||
use bitflags::bitflags;
|
||||
use ostd::{io_mem::IoMem, Pod};
|
||||
use ostd::{io_mem::IoMem, mm::PodOnce, Pod};
|
||||
|
||||
use crate::transport::VirtioTransport;
|
||||
|
||||
@ -32,6 +32,8 @@ pub struct VirtioVsockConfig {
|
||||
pub guest_cid_high: u32,
|
||||
}
|
||||
|
||||
impl PodOnce for VirtioVsockConfig {}
|
||||
|
||||
impl VirtioVsockConfig {
|
||||
pub(crate) fn new(transport: &dyn VirtioTransport) -> SafePtr<Self, IoMem> {
|
||||
let memory = transport.device_config_mem().unwrap();
|
||||
|
@ -13,7 +13,7 @@ use aster_util::{field_ptr, safe_ptr::SafePtr};
|
||||
use bitflags::bitflags;
|
||||
use log::debug;
|
||||
use ostd::{
|
||||
mm::{DmaCoherent, FrameAllocOptions},
|
||||
mm::{DmaCoherent, FrameAllocOptions, PodOnce},
|
||||
offset_of, Pod,
|
||||
};
|
||||
|
||||
@ -445,6 +445,8 @@ bitflags! {
|
||||
}
|
||||
}
|
||||
|
||||
impl PodOnce for DescFlags {}
|
||||
|
||||
/// The driver uses the available ring to offer buffers to the device:
|
||||
/// each ring entry refers to the head of a descriptor chain.
|
||||
/// It is only written by the driver and read by the device.
|
||||
@ -487,3 +489,5 @@ bitflags! {
|
||||
const VIRTQ_AVAIL_F_NO_INTERRUPT = 1;
|
||||
}
|
||||
}
|
||||
|
||||
impl PodOnce for AvailFlags {}
|
||||
|
Reference in New Issue
Block a user