pub struct StartInfo {
pub trap: Trap,
pub guest: Option<Guest>,
pub event: Event,
pub vmo: Vmo,
}
Expand description
Contains the basic information required to start execution of a device.
Fields§
§trap: Trap
The trap associated with a device. It is up to the device to set this trap during device setup.
guest: Option<Guest>
The guest associated with a device. This handle should be used to setup device traps, and then be released before device operation begins.
event: Event
The event associated with a device interrupt. This is how the device will notify the guest of events it should process.
The meaning of the different signals that can be raised on the event are documented by the EVENT_* constants above.
vmo: Vmo
The VMO used to represent guest physical memory.
Trait Implementations§
Source§impl Decode<StartInfo, DefaultFuchsiaResourceDialect> for StartInfo
impl Decode<StartInfo, DefaultFuchsiaResourceDialect> for StartInfo
Source§impl<T0: Encode<Trap, DefaultFuchsiaResourceDialect>, T1: Encode<Optional<HandleType<Guest, { _ }, 2147483648>>, DefaultFuchsiaResourceDialect>, T2: Encode<HandleType<Event, { _ }, 2147483648>, DefaultFuchsiaResourceDialect>, T3: Encode<HandleType<Vmo, { _ }, 2147483648>, DefaultFuchsiaResourceDialect>> Encode<StartInfo, DefaultFuchsiaResourceDialect> for (T0, T1, T2, T3)
impl<T0: Encode<Trap, DefaultFuchsiaResourceDialect>, T1: Encode<Optional<HandleType<Guest, { _ }, 2147483648>>, DefaultFuchsiaResourceDialect>, T2: Encode<HandleType<Event, { _ }, 2147483648>, DefaultFuchsiaResourceDialect>, T3: Encode<HandleType<Vmo, { _ }, 2147483648>, DefaultFuchsiaResourceDialect>> Encode<StartInfo, DefaultFuchsiaResourceDialect> for (T0, T1, T2, T3)
Source§impl Ord for StartInfo
impl Ord for StartInfo
Source§impl PartialOrd for StartInfo
impl PartialOrd for StartInfo
Source§impl ResourceTypeMarker for StartInfo
impl ResourceTypeMarker for StartInfo
Source§type Borrowed<'a> = &'a mut StartInfo
type Borrowed<'a> = &'a mut StartInfo
The Rust type to use for encoding. This is a particular
Encode<Self>
type cheaply obtainable from &mut Self::Owned
. There are three cases: Read moreSource§fn take_or_borrow<'a>(
value: &'a mut <Self as TypeMarker>::Owned,
) -> Self::Borrowed<'a>
fn take_or_borrow<'a>( value: &'a mut <Self as TypeMarker>::Owned, ) -> Self::Borrowed<'a>
Cheaply converts from
&mut Self::Owned
to Self::Borrowed
. For
HandleBased
types this is “take” (it returns an owned handle and
replaces value
with Handle::invalid
), and for all other types it is
“borrow” (just converts from one reference to another).Source§impl TypeMarker for StartInfo
impl TypeMarker for StartInfo
Source§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
Returns the minimum required alignment of the inline portion of the
encoded object. It must be a (nonzero) power of two.
Source§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
Returns the size of the inline portion of the encoded object, including
padding for alignment. Must be a multiple of
inline_align
.§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Returns true if the memory layout of
Self::Owned
matches the FIDL wire
format and encoding requires no validation. When true, we can optimize
encoding arrays and vectors of Self::Owned
to a single memcpy. Read more§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Returns true if the memory layout of
Self::Owned
matches the FIDL wire
format and decoding requires no validation. When true, we can optimize
decoding arrays and vectors of Self::Owned
to a single memcpy.impl Eq for StartInfo
impl Standalone<DefaultFuchsiaResourceDialect> for StartInfo
impl StructuralPartialEq for StartInfo
Auto Trait Implementations§
impl Freeze for StartInfo
impl RefUnwindSafe for StartInfo
impl Send for StartInfo
impl Sync for StartInfo
impl Unpin for StartInfo
impl UnwindSafe for StartInfo
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