/* When someone needs more than 32 feature bits, we'll need to
* steal a bit to indicate that the rest are somewhere else. */ return vp_legacy_get_features(&vp_dev->ldev);
}
staticvoid vp_set_status(struct virtio_device *vdev, u8 status)
{ struct virtio_pci_device *vp_dev = to_vp_device(vdev); /* We should never be setting status to 0. */
BUG_ON(status == 0);
vp_legacy_set_status(&vp_dev->ldev, status);
}
staticvoid vp_reset(struct virtio_device *vdev)
{ struct virtio_pci_device *vp_dev = to_vp_device(vdev); /* 0 status means a reset. */
vp_legacy_set_status(&vp_dev->ldev, 0); /* Flush out the status write, and flush in device writes,
* including MSi-X interrupts, if any. */
vp_legacy_get_status(&vp_dev->ldev); /* Flush pending VQ/configuration callbacks. */
vp_synchronize_vectors(vdev);
}
/* Check if queue is either not available or already active. */
num = vp_legacy_get_queue_size(&vp_dev->ldev, index); if (!num || vp_legacy_get_queue_enable(&vp_dev->ldev, index)) return ERR_PTR(-ENOENT);
if (vp_dev->msix_enabled) {
vp_legacy_queue_vector(&vp_dev->ldev, vq->index,
VIRTIO_MSI_NO_VECTOR); /* Flush the write out to device */
ioread8(vp_dev->ldev.ioaddr + VIRTIO_PCI_ISR);
}
/* Select and deactivate the queue */
vp_legacy_set_queue_address(&vp_dev->ldev, vq->index, 0);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.