pub struct VfsBackend { /* private fields */ }Expand description
The vhost-user backend hosting a VfsFileSystem [Server].
Trait Implementations§
Source§impl VhostUserBackendMut for VfsBackend
impl VhostUserBackendMut for VfsBackend
type Bitmap = ()
type Vring = VringRwLock
Source§fn num_queues(&self) -> usize
fn num_queues(&self) -> usize
Get number of queues supported.
Source§fn max_queue_size(&self) -> usize
fn max_queue_size(&self) -> usize
Get maximum queue size supported.
Source§fn protocol_features(&self) -> VhostUserProtocolFeatures
fn protocol_features(&self) -> VhostUserProtocolFeatures
Get available vhost protocol features.
Source§fn set_event_idx(&mut self, enabled: bool)
fn set_event_idx(&mut self, enabled: bool)
Enable or disable the virtio EVENT_IDX feature
Source§fn update_memory(
&mut self,
mem: GuestMemoryAtomic<GuestMemoryMmap>,
) -> Result<()>
fn update_memory( &mut self, mem: GuestMemoryAtomic<GuestMemoryMmap>, ) -> Result<()>
Update guest memory regions.
Source§fn handle_event(
&mut self,
device_event: u16,
_evset: EventSet,
vrings: &[Self::Vring],
_thread_id: usize,
) -> Result<()>
fn handle_event( &mut self, device_event: u16, _evset: EventSet, vrings: &[Self::Vring], _thread_id: usize, ) -> Result<()>
Handle IO events for backend registered file descriptors. Read more
Source§fn exit_event(&self, _thread_id: usize) -> Option<EventFd>
fn exit_event(&self, _thread_id: usize) -> Option<EventFd>
Provide an optional exit EventFd for the specified worker thread. Read more
§fn acked_features(&mut self, _features: u64)
fn acked_features(&mut self, _features: u64)
Set acknowledged virtio features.
§fn get_config(&self, _offset: u32, _size: u32) -> Vec<u8> ⓘ
fn get_config(&self, _offset: u32, _size: u32) -> Vec<u8> ⓘ
Get virtio device configuration. Read more
§fn set_config(&mut self, _offset: u32, _buf: &[u8]) -> Result<(), Error>
fn set_config(&mut self, _offset: u32, _buf: &[u8]) -> Result<(), Error>
Set virtio device configuration. Read more
§fn set_backend_req_fd(&mut self, _backend: Backend)
fn set_backend_req_fd(&mut self, _backend: Backend)
Set handler for communicating with the frontend by the backend communication channel. Read more
§fn queues_per_thread(&self) -> Vec<u64>
fn queues_per_thread(&self) -> Vec<u64>
Get the map to map queue index to worker thread index. Read more
Auto Trait Implementations§
impl Freeze for VfsBackend
impl !RefUnwindSafe for VfsBackend
impl Send for VfsBackend
impl Sync for VfsBackend
impl Unpin for VfsBackend
impl UnsafeUnpin for VfsBackend
impl !UnwindSafe for VfsBackend
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§impl<T> ServiceExt for T
impl<T> ServiceExt for T
§fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
Apply a transformation to the response body. Read more
§fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using HTTP status codes. Read more
§fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using gRPC headers. Read more