Lines Matching refs:vp_dev

24 	struct virtio_pci_device *vp_dev = to_vp_device(vdev);  in vp_get_features()  local
26 return vp_modern_get_features(&vp_dev->mdev); in vp_get_features()
31 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_transport_features() local
32 struct pci_dev *pci_dev = vp_dev->pci_dev; in vp_transport_features()
45 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_finalize_features() local
60 vp_modern_set_features(&vp_dev->mdev, vdev->features); in vp_finalize_features()
69 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_get() local
70 struct virtio_pci_modern_device *mdev = &vp_dev->mdev; in vp_get()
107 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_set() local
108 struct virtio_pci_modern_device *mdev = &vp_dev->mdev; in vp_set()
142 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_generation() local
144 return vp_modern_generation(&vp_dev->mdev); in vp_generation()
150 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_get_status() local
152 return vp_modern_get_status(&vp_dev->mdev); in vp_get_status()
157 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_set_status() local
161 vp_modern_set_status(&vp_dev->mdev, status); in vp_set_status()
166 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_reset() local
167 struct virtio_pci_modern_device *mdev = &vp_dev->mdev; in vp_reset()
184 struct virtio_pci_device *vp_dev = to_vp_device(vq->vdev); in vp_active_vq() local
185 struct virtio_pci_modern_device *mdev = &vp_dev->mdev; in vp_active_vq()
207 struct virtio_pci_device *vp_dev = to_vp_device(vq->vdev); in vp_modern_disable_vq_and_reset() local
208 struct virtio_pci_modern_device *mdev = &vp_dev->mdev; in vp_modern_disable_vq_and_reset()
217 info = vp_dev->vqs[vq->index]; in vp_modern_disable_vq_and_reset()
220 spin_lock_irqsave(&vp_dev->lock, flags); in vp_modern_disable_vq_and_reset()
222 spin_unlock_irqrestore(&vp_dev->lock, flags); in vp_modern_disable_vq_and_reset()
236 if (vp_dev->per_vq_vectors && info->msix_vector != VIRTIO_MSI_NO_VECTOR) in vp_modern_disable_vq_and_reset()
237 synchronize_irq(pci_irq_vector(vp_dev->pci_dev, info->msix_vector)); in vp_modern_disable_vq_and_reset()
246 struct virtio_pci_device *vp_dev = to_vp_device(vq->vdev); in vp_modern_enable_vq_after_reset() local
247 struct virtio_pci_modern_device *mdev = &vp_dev->mdev; in vp_modern_enable_vq_after_reset()
256 info = vp_dev->vqs[index]; in vp_modern_enable_vq_after_reset()
269 spin_lock_irqsave(&vp_dev->lock, flags); in vp_modern_enable_vq_after_reset()
270 list_add(&info->node, &vp_dev->virtqueues); in vp_modern_enable_vq_after_reset()
271 spin_unlock_irqrestore(&vp_dev->lock, flags); in vp_modern_enable_vq_after_reset()
280 vp_modern_set_queue_enable(&vp_dev->mdev, index, true); in vp_modern_enable_vq_after_reset()
286 static u16 vp_config_vector(struct virtio_pci_device *vp_dev, u16 vector) in vp_config_vector() argument
288 return vp_modern_config_vector(&vp_dev->mdev, vector); in vp_config_vector()
291 static struct virtqueue *setup_vq(struct virtio_pci_device *vp_dev, in setup_vq() argument
300 struct virtio_pci_modern_device *mdev = &vp_dev->mdev; in setup_vq()
314 dev_warn(&vp_dev->pci_dev->dev, "bad queue size %u", num); in setup_vq()
322 SMP_CACHE_BYTES, &vp_dev->vdev, in setup_vq()
353 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_modern_find_vqs() local
364 vp_modern_set_queue_enable(&vp_dev->mdev, vq->index, true); in vp_modern_find_vqs()
372 struct virtio_pci_device *vp_dev = to_vp_device(vq->vdev); in del_vq() local
373 struct virtio_pci_modern_device *mdev = &vp_dev->mdev; in del_vq()
375 if (vp_dev->msix_enabled) in del_vq()
453 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_get_shm_region() local
454 struct pci_dev *pci_dev = vp_dev->pci_dev; in vp_get_shm_region()
525 int virtio_pci_modern_probe(struct virtio_pci_device *vp_dev) in virtio_pci_modern_probe() argument
527 struct virtio_pci_modern_device *mdev = &vp_dev->mdev; in virtio_pci_modern_probe()
528 struct pci_dev *pci_dev = vp_dev->pci_dev; in virtio_pci_modern_probe()
538 vp_dev->vdev.config = &virtio_pci_config_ops; in virtio_pci_modern_probe()
540 vp_dev->vdev.config = &virtio_pci_config_nodev_ops; in virtio_pci_modern_probe()
542 vp_dev->config_vector = vp_config_vector; in virtio_pci_modern_probe()
543 vp_dev->setup_vq = setup_vq; in virtio_pci_modern_probe()
544 vp_dev->del_vq = del_vq; in virtio_pci_modern_probe()
545 vp_dev->isr = mdev->isr; in virtio_pci_modern_probe()
546 vp_dev->vdev.id = mdev->id; in virtio_pci_modern_probe()
551 void virtio_pci_modern_remove(struct virtio_pci_device *vp_dev) in virtio_pci_modern_remove() argument
553 struct virtio_pci_modern_device *mdev = &vp_dev->mdev; in virtio_pci_modern_remove()