You copied the Doc URL to your clipboard.

VirtioBlockDevice component

This section describes the VirtioBlockDevice component.

VirtioBlockDevice component - about

Virtio block device. This model is written in C++.

VirtioBlockDevice contains the following CADI targets:

  • VirtioBlockDevice

VirtioBlockDevice contains the following MTI components:

VirtioBlockDevice implements a block device that can be accessed from the simulated OS if it has an appropriate driver. Similarly to the VirtioP9Device, this component is targeted primarily at Linux, which has a built-in Virtio block driver. VirtioBlockDevice allows you to use a file on the host that you specify using the image_path parameter, as a hard drive in the simulated OS.

Unlike the VirtioP9Device, you should not need to carry out any special set up to use VirtioBlockDevice on VE or Base platforms, because it is usually already included in the device trees. Set the image_path parameter to point to your image, and then on Linux it is available as a block device, usually /dev/vda, which you then use like any other hard drive.

VirtioBlockDevice - ports

This section describes the ports.

Table 4-207 VirtioBlockDevice ports

Name Protocol Type Description
intr Signal Master Virtio device sets interrupt to signal completion.
pvbus PVBus Slave Virtio MMIO control/config/status registers.
virtio_m PVBus Master Virtio device performs DMA accesses via master.

VirtioBlockDevice - parameters

This section describes the parameters.

Table 4-208 VirtioBlockDevice parameters

Parameter Type Allowed values Default value Description
image_path string - '' Image file path.
quiet bool true, false false Do not print warnings for malformed commands or descriptors.
read_only bool true, false false Permit reads from the device, but not writes to it.
secure_accesses bool true, false false Force the device to generate transactions with NS=0.
Was this page helpful? Yes No