Documentation ¶
Overview ¶
Package mmio implements a virtio-mmio device bus.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Bus ¶
type Bus struct {
// contains filtered or unexported fields
}
func NewBus ¶
func NewBus(devices []virtio.DeviceConfig, cfg Config) (*Bus, error)
NewBus creates a new bus and installs a device for for each of the given handlers. The configured MemAt callback is called when a device needs to access a virtqueue in guest memory. The configured Notify callback is called when a device needs to notify the guest of a config or buffer event.
Devices are assigned an IRQ and a 4K memory region. See the Devices method.
func (*Bus) Devices ¶
func (b *Bus) Devices() []DeviceInfo
Devices returns a slice describing the installed devices.
Click to show internal directories.
Click to hide internal directories.