Lines Matching defs:mdev
36 struct virtio_pci_modern_device *mdev;
48 struct virtio_pci_modern_device *mdev;
61 return vp_vdpa->mdev;
66 return vp_vdpa->mdev;
78 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
80 vp_modern_set_features(mdev, features);
87 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
89 return vp_modern_get_driver_features(mdev);
94 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
96 return vp_modern_get_status(mdev);
112 struct virtio_pci_modern_device *mdev = vp_vdpa_to_mdev(vp_vdpa);
113 struct pci_dev *pdev = mdev->pci_dev;
118 vp_modern_queue_vector(mdev, i, VIRTIO_MSI_NO_VECTOR);
126 vp_modern_config_vector(mdev, VIRTIO_MSI_NO_VECTOR);
159 struct virtio_pci_modern_device *mdev = vp_vdpa_to_mdev(vp_vdpa);
160 struct pci_dev *pdev = mdev->pci_dev;
188 vp_modern_queue_vector(mdev, i, i);
202 vp_modern_config_vector(mdev, queues);
214 struct virtio_pci_modern_device *mdev = vp_vdpa_to_mdev(vp_vdpa);
222 vp_modern_set_status(mdev, status);
228 struct virtio_pci_modern_device *mdev = vp_vdpa_to_mdev(vp_vdpa);
231 vp_modern_set_status(mdev, 0);
282 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
288 if ((vp_modern_get_status(mdev) & VIRTIO_CONFIG_S_FEATURES_OK) &&
289 !vp_modern_get_queue_enable(mdev, qid)) {
290 if (vp_modern_get_driver_features(mdev) &
311 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
313 vp_modern_set_queue_enable(mdev, qid, ready);
318 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
320 return vp_modern_get_queue_enable(mdev, qid);
326 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
328 vp_modern_set_queue_size(mdev, qid, num);
335 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
337 vp_modern_queue_address(mdev, qid, desc_area,
352 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
354 return vp_modern_generation(mdev);
359 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
361 return mdev->id.device;
366 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
368 return mdev->id.vendor;
378 struct virtio_pci_modern_device *mdev = vdpa_to_mdev(vdpa);
380 return mdev->device_len;
388 struct virtio_pci_modern_device *mdev = vp_vdpa_to_mdev(vp_vdpa);
394 old = vp_ioread8(&mdev->common->config_generation);
397 *p++ = vp_ioread8(mdev->device + offset + i);
399 new = vp_ioread8(&mdev->common->config_generation);
408 struct virtio_pci_modern_device *mdev = vp_vdpa_to_mdev(vp_vdpa);
413 vp_iowrite8(*p++, mdev->device + offset + i);
428 struct virtio_pci_modern_device *mdev = vp_vdpa_to_mdev(vp_vdpa);
432 notify.size = mdev->notify_offset_multiplier;
476 struct virtio_pci_modern_device *mdev = vp_vdpa_mgtdev->mdev;
477 struct pci_dev *pdev = mdev->pci_dev;
494 vp_vdpa->queues = vp_modern_get_num_queues(mdev);
495 vp_vdpa->mdev = mdev;
497 device_features = vp_modern_get_features(mdev);
530 vp_modern_map_vq_notify(mdev, i,
540 vp_vdpa->vdpa.mdev = &vp_vdpa_mgtdev->mgtdev;
576 struct virtio_pci_modern_device *mdev = NULL;
588 mdev = kzalloc(sizeof(struct virtio_pci_modern_device), GFP_KERNEL);
589 if (!mdev) {
600 vp_vdpa_mgtdev->mdev = mdev;
601 mdev->pci_dev = pdev;
608 err = vp_modern_probe(mdev);
614 mdev_id->device = mdev->id.device;
615 mdev_id->vendor = mdev->id.vendor;
617 mgtdev->max_supported_vqs = vp_modern_get_num_queues(mdev);
618 mgtdev->supported_features = vp_modern_get_features(mdev);
632 vp_modern_remove(vp_vdpa_mgtdev->mdev);
636 kfree(mdev);
645 struct virtio_pci_modern_device *mdev = NULL;
647 mdev = vp_vdpa_mgtdev->mdev;
649 vp_modern_remove(mdev);
651 kfree(mdev);