Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1670886

[PATCH v3 9/9] vfio: Add AMBA driver_override support

From Alex Williamson <alex.williamson@redhat.com>
Newsgroups linux.kernel
Subject [PATCH v3 9/9] vfio: Add AMBA driver_override support
Date 2017-06-20 17:50 +0200
Message-ID <tUtzI-238-19@gated-at.bofh.it> (permalink)
References <tUtzH-238-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


AMBA also supports driver_override, but amba_bustype was not exported
to be able to identify an amba device.

Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
---
 drivers/vfio/vfio.c |    6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/vfio/vfio.c b/drivers/vfio/vfio.c
index 20e57fecf652..36f0fcfded0b 100644
--- a/drivers/vfio/vfio.c
+++ b/drivers/vfio/vfio.c
@@ -36,6 +36,7 @@
 #include <linux/uuid.h>
 #include <linux/vfio.h>
 #include <linux/wait.h>
+#include <linux/amba/bus.h>
 
 #define DRIVER_VERSION	"0.3"
 #define DRIVER_AUTHOR	"Alex Williamson <alex.williamson@redhat.com>"
@@ -743,6 +744,11 @@ static char **vfio_find_driver_override(struct device *dev)
 	} else if (dev->bus == &platform_bus_type) {
 		struct platform_device *pdev = to_platform_device(dev);
 		return &pdev->driver_override;
+#ifdef CONFIG_ARM_AMBA
+	} else if (dev->bus == &amba_bustype) {
+		struct amba_device *adev = to_amba_device(dev);
+		return &adev->driver_override;
+#endif
 	}
 
 	return NULL;

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v3 0/9] vfio: Fix release ordering races and use  driver_override Alex Williamson <alex.williamson@redhat.com> - 2017-06-20 17:50 +0200
  [PATCH v3 9/9] vfio: Add AMBA driver_override support Alex Williamson <alex.williamson@redhat.com> - 2017-06-20 17:50 +0200
    Re: [PATCH v3 9/9] vfio: Add AMBA driver_override support Auger Eric <eric.auger@redhat.com> - 2017-06-26 09:40 +0200
  [PATCH v3 4/9] iommu: Add driver-not-bound notification Alex Williamson <alex.williamson@redhat.com> - 2017-06-20 17:50 +0200
  [PATCH v3 6/9] vfio: Register pci, platform, amba,  and mdev bus drivers Alex Williamson <alex.williamson@redhat.com> - 2017-06-20 17:50 +0200
  [PATCH v3 3/9] vfio: New external user group/file match Alex Williamson <alex.williamson@redhat.com> - 2017-06-20 17:50 +0200
  [PATCH v3 1/9] vfio: Fix group release deadlock Alex Williamson <alex.williamson@redhat.com> - 2017-06-20 17:50 +0200
  [PATCH v3 7/9] vfio: Use driver_override to avert binding to  compromising drivers Alex Williamson <alex.williamson@redhat.com> - 2017-06-20 17:50 +0200
    Re: [PATCH v3 7/9] vfio: Use driver_override to avert binding to  compromising drivers Russell King - ARM Linux <linux@armlinux.org.uk> - 2017-06-26 11:10 +0200
      Re: [PATCH v3 7/9] vfio: Use driver_override to avert binding to  compromising drivers Alex Williamson <alex.williamson@redhat.com> - 2017-06-26 21:40 +0200
  [PATCH v3 5/9] vfio: Create interface for vfio bus drivers to  register Alex Williamson <alex.williamson@redhat.com> - 2017-06-20 17:50 +0200
  [PATCH v3 8/9] amba: Export amba_bustype Alex Williamson <alex.williamson@redhat.com> - 2017-06-20 17:50 +0200
    Re: [PATCH v3 8/9] amba: Export amba_bustype Auger Eric <eric.auger@redhat.com> - 2017-06-26 09:40 +0200
  [PATCH v3 2/9] kvm-vfio: Decouple only when we match a group Alex Williamson <alex.williamson@redhat.com> - 2017-06-20 18:00 +0200
    Re: [PATCH v3 2/9] kvm-vfio: Decouple only when we match a group Auger Eric <eric.auger@redhat.com> - 2017-06-26 09:40 +0200
    Re: [PATCH v3 2/9] kvm-vfio: Decouple only when we match a group Paolo Bonzini <pbonzini@redhat.com> - 2017-06-28 20:00 +0200
  Re: [PATCH v3 0/9] vfio: Fix release ordering races and use  driver_override Auger Eric <eric.auger@redhat.com> - 2017-06-26 09:40 +0200

csiph-web