Displaying 15 results from an estimated 15 matches for "vfio_pci_prob".
Did you mean:
vfio_pci_probe
2016 Aug 30
2
[PATCH v2 2/2] vfio: add virtio pci quirk
...VFIO_PCI_PRIVATE_H */
> > > diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
> > > index d624a52..e93bf0c 100644
> > > --- a/drivers/vfio/pci/vfio_pci.c
> > > +++ b/drivers/vfio/pci/vfio_pci.c
> > > @@ -1236,6 +1236,20 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
> > > return ret;
> > > }
> > >
> > > + if (pdev->vendor == PCI_VENDOR_ID_REDHAT_QUMRANET) {
> >
> > Perhaps a vfio_pci_is_virtio() like vga below? Let's test the device
> &...
2016 Aug 30
2
[PATCH v2 2/2] vfio: add virtio pci quirk
...VFIO_PCI_PRIVATE_H */
> > > diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
> > > index d624a52..e93bf0c 100644
> > > --- a/drivers/vfio/pci/vfio_pci.c
> > > +++ b/drivers/vfio/pci/vfio_pci.c
> > > @@ -1236,6 +1236,20 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
> > > return ret;
> > > }
> > >
> > > + if (pdev->vendor == PCI_VENDOR_ID_REDHAT_QUMRANET) {
> >
> > Perhaps a vfio_pci_is_virtio() like vga below? Let's test the device
> &...
2016 Aug 30
4
[PATCH v2 2/2] vfio: add virtio pci quirk
..._pci_device *vdev, bool noiommu);
> #endif /* VFIO_PCI_PRIVATE_H */
> diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
> index d624a52..e93bf0c 100644
> --- a/drivers/vfio/pci/vfio_pci.c
> +++ b/drivers/vfio/pci/vfio_pci.c
> @@ -1236,6 +1236,20 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
> return ret;
> }
>
> + if (pdev->vendor == PCI_VENDOR_ID_REDHAT_QUMRANET) {
Perhaps a vfio_pci_is_virtio() like vga below? Let's test the device
ID range initially as well, this test raised a big red flag for me
whe...
2016 Aug 30
4
[PATCH v2 2/2] vfio: add virtio pci quirk
..._pci_device *vdev, bool noiommu);
> #endif /* VFIO_PCI_PRIVATE_H */
> diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
> index d624a52..e93bf0c 100644
> --- a/drivers/vfio/pci/vfio_pci.c
> +++ b/drivers/vfio/pci/vfio_pci.c
> @@ -1236,6 +1236,20 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
> return ret;
> }
>
> + if (pdev->vendor == PCI_VENDOR_ID_REDHAT_QUMRANET) {
Perhaps a vfio_pci_is_virtio() like vga below? Let's test the device
ID range initially as well, this test raised a big red flag for me
whe...
2016 Aug 30
0
[PATCH v2 2/2] vfio: add virtio pci quirk
...; > > > diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
> > > > index d624a52..e93bf0c 100644
> > > > --- a/drivers/vfio/pci/vfio_pci.c
> > > > +++ b/drivers/vfio/pci/vfio_pci.c
> > > > @@ -1236,6 +1236,20 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
> > > > return ret;
> > > > }
> > > >
> > > > + if (pdev->vendor == PCI_VENDOR_ID_REDHAT_QUMRANET) {
> > >
> > > Perhaps a vfio_pci_is_virtio() like vga below? Le...
2016 Aug 30
0
[PATCH v2 2/2] vfio: add virtio pci quirk
...u);
> > #endif /* VFIO_PCI_PRIVATE_H */
> > diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
> > index d624a52..e93bf0c 100644
> > --- a/drivers/vfio/pci/vfio_pci.c
> > +++ b/drivers/vfio/pci/vfio_pci.c
> > @@ -1236,6 +1236,20 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
> > return ret;
> > }
> >
> > + if (pdev->vendor == PCI_VENDOR_ID_REDHAT_QUMRANET) {
>
> Perhaps a vfio_pci_is_virtio() like vga below? Let's test the device
> ID range initially as well, this...
2016 Apr 18
5
[PATCH RFC 0/3] virtio-pci: iommu support
This is an attempt to allow enabling IOMMU for DMA.
Design:
- new feature bit IOMMU_PLATFORM which means
host won't bypass IOMMU
- virtio core uses DMA API if it sees IOMMU_PLATFORM
- add quirk for vfio to disable device unless IOMMU_PLATFORM is set
or the no-iommu mode is enabled
- while I'm not sure how it will be used, it seems like a good idea to
also have
2016 Apr 18
5
[PATCH RFC 0/3] virtio-pci: iommu support
This is an attempt to allow enabling IOMMU for DMA.
Design:
- new feature bit IOMMU_PLATFORM which means
host won't bypass IOMMU
- virtio core uses DMA API if it sees IOMMU_PLATFORM
- add quirk for vfio to disable device unless IOMMU_PLATFORM is set
or the no-iommu mode is enabled
- while I'm not sure how it will be used, it seems like a good idea to
also have
2016 Aug 30
6
[PATCH v2 0/2] vfio: blacklist legacy virtio devices
Legacy virtio devices always bypassed an IOMMU, so using them with vfio was
never safe. This adds a quirk detecting these and disabling VFIO unless the
noiommu mode is used. At the moment, this only applies to virtio-pci devices.
The patch might make sense on stable as well.
Michael S. Tsirkin (2):
vfio: report group noiommu status
vfio: add virtio pci quirk
2016 Aug 30
6
[PATCH v2 0/2] vfio: blacklist legacy virtio devices
Legacy virtio devices always bypassed an IOMMU, so using them with vfio was
never safe. This adds a quirk detecting these and disabling VFIO unless the
noiommu mode is used. At the moment, this only applies to virtio-pci devices.
The patch might make sense on stable as well.
Michael S. Tsirkin (2):
vfio: report group noiommu status
vfio: add virtio pci quirk
2016 Apr 18
0
[PATCH RFC 2/3] vfio: report group noiommu status
...tation/vfio.txt | 4 +++-
4 files changed, 9 insertions(+), 4 deletions(-)
diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
index 712a849..d622a41 100644
--- a/drivers/vfio/pci/vfio_pci.c
+++ b/drivers/vfio/pci/vfio_pci.c
@@ -1119,7 +1119,7 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
spin_lock_init(&vdev->irqlock);
ret = vfio_add_group_dev(&pdev->dev, &vfio_pci_ops, vdev);
- if (ret) {
+ if (ret < 0) {
vfio_iommu_group_put(group, &pdev->dev);
kfree(vdev);
return ret;
diff --git a/d...
2016 Apr 18
1
[PATCH RFC 3/3] vfio: add virtio pci quirk
...o_pci_device *vdev, int noiommu);
> #endif /* VFIO_PCI_PRIVATE_H */
> diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
> index d622a41..2bb8c76 100644
> --- a/drivers/vfio/pci/vfio_pci.c
> +++ b/drivers/vfio/pci/vfio_pci.c
> @@ -1125,6 +1125,17 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
> return ret;
> }
>
> + if (pdev->vendor == PCI_VENDOR_ID_REDHAT_QUMRANET &&
Virtio really owns this entire vendor ID block? Apparently nobody told
ivshmem: http://pci-ids.ucw.cz/read/PC/1af4/1110 Even the comme...
2016 Apr 18
1
[PATCH RFC 3/3] vfio: add virtio pci quirk
...o_pci_device *vdev, int noiommu);
> #endif /* VFIO_PCI_PRIVATE_H */
> diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
> index d622a41..2bb8c76 100644
> --- a/drivers/vfio/pci/vfio_pci.c
> +++ b/drivers/vfio/pci/vfio_pci.c
> @@ -1125,6 +1125,17 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
> return ret;
> }
>
> + if (pdev->vendor == PCI_VENDOR_ID_REDHAT_QUMRANET &&
Virtio really owns this entire vendor ID block? Apparently nobody told
ivshmem: http://pci-ids.ucw.cz/read/PC/1af4/1110 Even the comme...
2016 Apr 18
0
[PATCH RFC 3/3] vfio: add virtio pci quirk
...io_pci_virtio_quirk(struct vfio_pci_device *vdev, int noiommu);
#endif /* VFIO_PCI_PRIVATE_H */
diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
index d622a41..2bb8c76 100644
--- a/drivers/vfio/pci/vfio_pci.c
+++ b/drivers/vfio/pci/vfio_pci.c
@@ -1125,6 +1125,17 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
return ret;
}
+ if (pdev->vendor == PCI_VENDOR_ID_REDHAT_QUMRANET &&
+ ((ret = vfio_pci_virtio_quirk(vdev, ret)))) {
+ dev_warn(&vdev->pdev->dev,
+ "Failed to setup Virtio for VFIO\n");
+ vfio_del_...
2016 Aug 30
0
[PATCH v2 2/2] vfio: add virtio pci quirk
...o_pci_virtio_quirk(struct vfio_pci_device *vdev, bool noiommu);
#endif /* VFIO_PCI_PRIVATE_H */
diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
index d624a52..e93bf0c 100644
--- a/drivers/vfio/pci/vfio_pci.c
+++ b/drivers/vfio/pci/vfio_pci.c
@@ -1236,6 +1236,20 @@ static int vfio_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
return ret;
}
+ if (pdev->vendor == PCI_VENDOR_ID_REDHAT_QUMRANET) {
+ bool noiommu = vfio_is_noiommu_group_dev(&pdev->dev);
+
+ ret = vfio_pci_virtio_quirk(vdev, noiommu);
+ if (ret) {
+ dev_warn(&vdev->pdev->de...