All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/4] Add virtio-iommu driver
@ 2018-02-14 14:53 ` Jean-Philippe Brucker
  0 siblings, 0 replies; 61+ messages in thread
From: Jean-Philippe Brucker @ 2018-02-14 14:53 UTC (permalink / raw)
  To: iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA,
	kvm-u79uwXL29TY76Z2rM5mHXA,
	virtualization-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA,
	virtio-dev-sDuHXQ4OtrM4h7I2RyI4rWD2FQJk+8+b,
	kvmarm-FPEHb7Xf0XXUo1n7N8X6UoWGPAHP3yOg
  Cc: jayachandran.nair-YGCgFSpz5w/QT0dZR+AlfA,
	tnowicki-M3mlKVOIwJVv6pq1l3V1OdBPR1lH4CV8,
	mst-H+wXaHxf7aLQT0dZR+AlfA, marc.zyngier-5wv7dgnIgG8,
	jasowang-H+wXaHxf7aLQT0dZR+AlfA, will.deacon-5wv7dgnIgG8,
	jintack-eQaUEPhvms7ENvBUuze7eA,
	eric.auger.pro-Re5JQEeQqe8AvxtiuMwx3w

Implement the virtio-iommu driver following version 0.6 of the
specification [1]. Previous version, RFCv2, was sent in November [2].
This version addresses Eric's comments and changes the device number.
(Since last week I also tested and fixed the probe/release functions,
they now use devm properly.)

I did not include ACPI support because the next IORT specifications
isn't ready yet (even though the virtio-iommu spec describes the node
format, a new node type has to be allocated). Therefore only device-tree
guests are supported for the moment but the x86 prototype, on branch
virtio-iommu/devel, doesn't add much complexity.

	git://linux-arm.org/linux-jpb.git virtio-iommu/v0.6

Test it with Eric's latest QEMU device [3], for example with the
following command-line:

$ qemu-system-aarch64 -M virt -cpu cortex-a57 -nographic
	-kernel Image -append 'console=ttyAMA0 root=/dev/vda rw'
	-device virtio-iommu-device
	-device virtio-blk-pci,iommu_platform,disable-legacy=on,drive=hd0
	-drive if=none,file=rootfs.bin,id=hd0

You can also try the kvmtool device [4]. For example on AMD Seattle I
use the following commands to boot a guest with all devices behind a
virtio-iommu, then display mapping stats.

$ lkvm run -k Image --irqchip gicv2m --console virtio --vfio-pci 01:00.0
	--viommu vfio --viommu virtio
$ lkvm debug -a -i stats

[1] [RFC] virtio-iommu version 0.6
    https://www.spinics.net/lists/linux-virtualization/msg32628.html
[2] [RFC PATCH v2 0/5] Add virtio-iommu driver
    https://www.spinics.net/lists/kvm/msg159047.html
[3] [RFC v6 00/22] VIRTIO-IOMMU device
    http://lists.gnu.org/archive/html/qemu-arm/2018-02/msg00274.html
[4] git://linux-arm.org/kvmtool-jpb.git virtio-iommu/v0.6

Jean-Philippe Brucker (4):
  iommu: Add virtio-iommu driver
  iommu/virtio: Add probe request
  iommu/virtio: Add event queue
  vfio: Allow type-1 IOMMU instantiation with a virtio-iommu

 MAINTAINERS                       |    6 +
 drivers/iommu/Kconfig             |   11 +
 drivers/iommu/Makefile            |    1 +
 drivers/iommu/virtio-iommu.c      | 1220 +++++++++++++++++++++++++++++++++++++
 drivers/vfio/Kconfig              |    2 +-
 include/uapi/linux/virtio_ids.h   |    1 +
 include/uapi/linux/virtio_iommu.h |  171 ++++++
 7 files changed, 1411 insertions(+), 1 deletion(-)
 create mode 100644 drivers/iommu/virtio-iommu.c
 create mode 100644 include/uapi/linux/virtio_iommu.h

-- 
2.16.1

^ permalink raw reply	[flat|nested] 61+ messages in thread

end of thread, other threads:[~2018-04-11 18:35 UTC | newest]

Thread overview: 61+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-14 14:53 [PATCH 0/4] Add virtio-iommu driver Jean-Philippe Brucker
2018-02-14 14:53 ` [virtio-dev] " Jean-Philippe Brucker
2018-02-14 14:53 ` [PATCH 1/4] iommu: " Jean-Philippe Brucker
2018-02-14 14:53 ` Jean-Philippe Brucker
2018-02-14 14:53   ` [virtio-dev] " Jean-Philippe Brucker
2018-02-21 20:12   ` kbuild test robot
2018-02-21 21:08   ` kbuild test robot
     [not found]   ` <20180214145340.1223-2-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-02-19 12:23     ` Tomasz Nowicki
2018-02-20 11:30       ` Jean-Philippe Brucker
2018-02-20 11:30       ` Jean-Philippe Brucker
2018-02-20 11:30         ` [virtio-dev] " Jean-Philippe Brucker
2018-02-21 20:12     ` kbuild test robot
     [not found]       ` <201802220455.lMEb6LLi%fengguang.wu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2018-02-22 11:04         ` Jean-Philippe Brucker
2018-02-22 11:04           ` [virtio-dev] " Jean-Philippe Brucker
2018-02-27 14:47           ` Michael S. Tsirkin
     [not found]           ` <e5ffc52f-4510-f757-aa83-2a99af3ae06b-5wv7dgnIgG8@public.gmane.org>
2018-02-27 14:47             ` Michael S. Tsirkin
2018-02-27 14:47               ` [virtio-dev] " Michael S. Tsirkin
2018-02-21 21:08     ` kbuild test robot
2018-03-21  6:43     ` Tian, Kevin
2018-03-21  6:43       ` [virtio-dev] " Tian, Kevin
2018-03-21 13:14       ` Jean-Philippe Brucker
     [not found]       ` <AADFC41AFE54684AB9EE6CBC0274A5D19108B0FE-0J0gbvR4kThpB2pF5aRoyrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2018-03-21 13:14         ` Jean-Philippe Brucker
2018-03-21 13:14           ` [virtio-dev] " Jean-Philippe Brucker
2018-03-21 14:23           ` Robin Murphy
2018-03-22 10:06             ` Tian, Kevin
2018-03-22 10:06               ` [virtio-dev] " Tian, Kevin
     [not found]             ` <AADFC41AFE54684AB9EE6CBC0274A5D19108DC42@SHSMSX101.ccr.corp.intel.com>
2018-03-23  8:27               ` Tian, Kevin
     [not found]               ` <AADFC41AFE54684AB9EE6CBC0274A5D19108DC42-0J0gbvR4kThpB2pF5aRoyrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2018-03-23  8:27                 ` Tian, Kevin
2018-03-23  8:27                   ` [virtio-dev] " Tian, Kevin
2018-04-11 18:35                   ` Jean-Philippe Brucker
2018-04-11 18:35                     ` [virtio-dev] " Jean-Philippe Brucker
2018-04-11 18:35                   ` Jean-Philippe Brucker
2018-03-23 14:48     ` Robin Murphy
2018-04-11 18:33       ` Jean-Philippe Brucker
2018-04-11 18:33         ` [virtio-dev] " Jean-Philippe Brucker
2018-03-21  6:43   ` Tian, Kevin
2018-03-23 14:48   ` Robin Murphy
2018-02-14 14:53 ` [PATCH 2/4] iommu/virtio: Add probe request Jean-Philippe Brucker
2018-02-14 14:53   ` [virtio-dev] " Jean-Philippe Brucker
2018-03-23 15:00   ` Robin Murphy
     [not found]   ` <20180214145340.1223-3-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-03-23 15:00     ` Robin Murphy
2018-04-11 18:33       ` Jean-Philippe Brucker
2018-04-11 18:33       ` Jean-Philippe Brucker
2018-04-11 18:33         ` [virtio-dev] " Jean-Philippe Brucker
2018-02-14 14:53 ` Jean-Philippe Brucker
2018-02-14 14:53 ` [PATCH 3/4] iommu/virtio: Add event queue Jean-Philippe Brucker
2018-02-14 14:53 ` Jean-Philippe Brucker
2018-02-14 14:53   ` [virtio-dev] " Jean-Philippe Brucker
2018-02-22  1:35   ` kbuild test robot
     [not found]   ` <20180214145340.1223-4-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-02-22  1:35     ` kbuild test robot
2018-02-14 14:53 ` [PATCH 4/4] vfio: Allow type-1 IOMMU instantiation with a virtio-iommu Jean-Philippe Brucker
2018-02-14 14:53   ` [virtio-dev] " Jean-Philippe Brucker
2018-02-14 15:26   ` Alex Williamson
     [not found]   ` <20180214145340.1223-5-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-02-14 15:26     ` Alex Williamson
     [not found]       ` <20180214082639.54556efb-DGNDKt5SQtizQB+pC5nmwQ@public.gmane.org>
2018-02-14 15:35         ` Robin Murphy
2018-02-15 13:53           ` Jean-Philippe Brucker
2018-02-15 13:53           ` Jean-Philippe Brucker
2018-02-15 13:53             ` [virtio-dev] " Jean-Philippe Brucker
2018-02-15 13:53             ` Jean-Philippe Brucker
2018-02-14 15:35       ` Robin Murphy
2018-02-14 14:53 ` Jean-Philippe Brucker

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.