pub struct MemControllerProxy { /* private fields */ }
Implementations§
Source§impl MemControllerProxy
impl MemControllerProxy
Sourcepub fn new(channel: AsyncChannel) -> Self
pub fn new(channel: AsyncChannel) -> Self
Create a new Proxy for fuchsia.virtualization/MemController.
Sourcepub fn take_event_stream(&self) -> MemControllerEventStream
pub fn take_event_stream(&self) -> MemControllerEventStream
Get a Stream of events from the remote end of the protocol.
§Panics
Panics if the event stream was already taken.
Sourcepub fn get_mem_size(
&self,
) -> QueryResponseFut<(u64, u64, u64, u64, u64), DefaultFuchsiaResourceDialect>
pub fn get_mem_size( &self, ) -> QueryResponseFut<(u64, u64, u64, u64, u64), DefaultFuchsiaResourceDialect>
Get the configured region size, usable region size, plugged size and requestd size
block_size is the size and the alignment in bytes of a memory block. Cannot change. region_size is the size of device-managed memory region in bytes. Cannot change. usable_region_size is the size of the usable device-managed memory region. Can grow up to the region_size. Can only shrink due to VIRTIO_MEM_REQ_UNPLUG_ALL requests. plugged_size is the amount of plugged memory in bytes within the usable device-managed memory region. requested_size is the requested amount of plugged memory within the usable device-managed memory region.
Sourcepub fn request_size(&self, requested_size: u64) -> Result<(), Error>
pub fn request_size(&self, requested_size: u64) -> Result<(), Error>
Update the requested size to plug or unplug memory
The driver SHOULD react to resize requests from the device (requested_size in the device configuration changed) by (un)plugging memory blocks.
Trait Implementations§
Source§impl Clone for MemControllerProxy
impl Clone for MemControllerProxy
Source§fn clone(&self) -> MemControllerProxy
fn clone(&self) -> MemControllerProxy
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for MemControllerProxy
impl Debug for MemControllerProxy
Source§impl MemControllerProxyInterface for MemControllerProxy
impl MemControllerProxyInterface for MemControllerProxy
type GetMemSizeResponseFut = QueryResponseFut<(u64, u64, u64, u64, u64)>
fn get_mem_size(&self) -> Self::GetMemSizeResponseFut
fn request_size(&self, requested_size: u64) -> Result<(), Error>
Source§impl Proxy for MemControllerProxy
impl Proxy for MemControllerProxy
Source§type Protocol = MemControllerMarker
type Protocol = MemControllerMarker
Proxy
controls.Source§fn from_channel(inner: AsyncChannel) -> Self
fn from_channel(inner: AsyncChannel) -> Self
Source§fn into_channel(self) -> Result<AsyncChannel, Self>
fn into_channel(self) -> Result<AsyncChannel, Self>
Source§fn as_channel(&self) -> &AsyncChannel
fn as_channel(&self) -> &AsyncChannel
§fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
Auto Trait Implementations§
impl Freeze for MemControllerProxy
impl !RefUnwindSafe for MemControllerProxy
impl Send for MemControllerProxy
impl Sync for MemControllerProxy
impl Unpin for MemControllerProxy
impl !UnwindSafe for MemControllerProxy
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)