pub trait ProtoPartition {
type Partition: Partition;
type ProcessorBinder: 'static + BindProcessor + Send;
type Error: Error + Send + Sync + 'static;
// Required methods
fn max_physical_address_size(&self) -> u8;
fn build(
self,
config: PartitionConfig<'_>,
) -> Result<(Self::Partition, Vec<Self::ProcessorBinder>), Self::Error>;
}Expand description
Trait for a prototype partition, one that is partially created but still needs final configuration.
This is separate from the partition so that it can be queried to determine the final partition configuration.
Required Associated Types§
Sourcetype ProcessorBinder: 'static + BindProcessor + Send
type ProcessorBinder: 'static + BindProcessor + Send
The VP binder type.
Required Methods§
Sourcefn max_physical_address_size(&self) -> u8
fn max_physical_address_size(&self) -> u8
The maximum physical address width that processors and devices for this partition can access.
This may be smaller than what is reported to the guest via architectural interfaces by default, and it may be larger or smaller than what the VMM ultimately chooses to report to the guest.
Sourcefn build(
self,
config: PartitionConfig<'_>,
) -> Result<(Self::Partition, Vec<Self::ProcessorBinder>), Self::Error>
fn build( self, config: PartitionConfig<'_>, ) -> Result<(Self::Partition, Vec<Self::ProcessorBinder>), Self::Error>
Constructs the full partition.