pub struct SerialWrapper<T: Trigger, EV: SerialEvents> {
pub serial: Serial<T, EV, AdapterWriter>,
pub out: Arc<Mutex<Option<Box<dyn Write + Send>>>>,
}
Fields§
§serial: Serial<T, EV, AdapterWriter>
§out: Arc<Mutex<Option<Box<dyn Write + Send>>>>
Implementations§
Trait Implementations§
Source§impl DeviceIoMut for SerialWrapper<EventFdTrigger, SerialEventsWrapper>
impl DeviceIoMut for SerialWrapper<EventFdTrigger, SerialEventsWrapper>
Source§fn pio_read(&mut self, _base: PioAddress, offset: PioAddress, data: &mut [u8])
fn pio_read(&mut self, _base: PioAddress, offset: PioAddress, data: &mut [u8])
Read from port
base + offset
into data
.Source§fn pio_write(&mut self, _base: PioAddress, offset: PioAddress, data: &[u8])
fn pio_write(&mut self, _base: PioAddress, offset: PioAddress, data: &[u8])
Write from
data
to the port base + offset
.Source§fn read(&mut self, _base: IoAddress, offset: IoAddress, data: &mut [u8])
fn read(&mut self, _base: IoAddress, offset: IoAddress, data: &mut [u8])
Read from the MMIO address
base + offset
into data
.Source§fn write(&mut self, _base: IoAddress, offset: IoAddress, data: &[u8])
fn write(&mut self, _base: IoAddress, offset: IoAddress, data: &[u8])
Write from
data
to the MMIO address base + offset
.Source§fn get_assigned_resources(&self) -> DeviceResources
fn get_assigned_resources(&self) -> DeviceResources
Get resources assigned to the device.
Source§fn get_trapped_io_resources(&self) -> DeviceResources
fn get_trapped_io_resources(&self) -> DeviceResources
Get the trapped IO address ranges for the device. Read more
Auto Trait Implementations§
impl<T, EV> Freeze for SerialWrapper<T, EV>
impl<T, EV> RefUnwindSafe for SerialWrapper<T, EV>where
T: RefUnwindSafe,
EV: RefUnwindSafe,
impl<T, EV> Send for SerialWrapper<T, EV>
impl<T, EV> Sync for SerialWrapper<T, EV>
impl<T, EV> Unpin for SerialWrapper<T, EV>
impl<T, EV> UnwindSafe for SerialWrapper<T, EV>where
T: UnwindSafe,
EV: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more