iommu.lists.linux-foundation.org archive mirror
 help / color / mirror / Atom feed
From: Jean-Philippe Brucker <jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
To: iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org
Cc: kevin.tian-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org,
	ashok.raj-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org,
	linux-pci-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	ilias.apalodimas-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org,
	will.deacon-5wv7dgnIgG8@public.gmane.org,
	okaya-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org,
	alex.williamson-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
	liguozhu-C8/M+/jPZTeaMJb+Lgu22Q@public.gmane.org,
	robin.murphy-5wv7dgnIgG8@public.gmane.org,
	christian.koenig-5C7GfCeVMHo@public.gmane.org
Subject: [PATCH v3 00/10] Shared Virtual Addressing for the IOMMU
Date: Thu, 20 Sep 2018 18:00:36 +0100	[thread overview]
Message-ID: <20180920170046.20154-1-jean-philippe.brucker@arm.com> (raw)

This is version 3 of the core changes for Shared Virtual Addressing in
the IOMMU. It provides an API for sharing process address spaces with
devices, using for example PCI PASID and PRI.

This time I didn't append the VFIO and SMMUv3 example users. A smaller
series is easier for me to manage and may be less intimidating for
reviewers. If you're adding or updating SVA support to your IOMMU or
device driver, you can find my complete patch stack at [1] for
inspiration.

Changes to patches 1-9 address feedback from v2 [2]. Mostly small tweaks
and comments, that I tried to detail on each patch.

I added patch 10/10 from Jordan Crouse, for managing PASID without
sharing process address spaces. This interface might get superseded by
auxiliary domains [3], since they are more suitable than io_mm for Intel
vt-d's mdev virtualization. Auxiliary domains reuse existing iommu_map/
iommu_unmap/etc ops instead of introducing new ones, so even though it's
more invasive, I tend to prefer that solution. But since we need
something for testing right now, I'm appending patch 10 to the series.

The series depends on Jacob Pan's patches for fault reporting [4].
  iommu: introduce device fault data
  driver core: add per device iommu param
  iommu: add a timeout parameter for prq response
  iommu: introduce device fault report API
  iommu: introduce page response function

[1] git://linux-arm.org/linux-jpb.git sva/v3
[2] https://www.spinics.net/lists/kvm/msg168742.html
[3] https://lwn.net/ml/linux-kernel/20180830040922.30426-1-baolu.lu-VuQAYsv1563Yd54FQh9/CA@public.gmane.org/
[4] https://lwn.net/ml/linux-kernel/1526072055-86990-1-git-send-email-jacob.jun.pan%40linux.intel.com/

Jean-Philippe Brucker (10):
  iommu: Introduce Shared Virtual Addressing API
  iommu/sva: Bind process address spaces to devices
  iommu/sva: Manage process address spaces
  iommu/sva: Add a mm_exit callback for device drivers
  iommu/sva: Track mm changes with an MMU notifier
  iommu/sva: Search mm by PASID
  iommu: Add a page fault handler
  iommu/iopf: Handle mm faults
  iommu/sva: Register page fault handler
  iommu/sva: Add support for private PASIDs

 drivers/iommu/Kconfig      |   9 +
 drivers/iommu/Makefile     |   2 +
 drivers/iommu/io-pgfault.c | 464 ++++++++++++++++++
 drivers/iommu/iommu-sva.c  | 967 +++++++++++++++++++++++++++++++++++++
 drivers/iommu/iommu.c      | 143 +++++-
 include/linux/iommu.h      | 289 ++++++++++-
 6 files changed, 1855 insertions(+), 19 deletions(-)
 create mode 100644 drivers/iommu/io-pgfault.c
 create mode 100644 drivers/iommu/iommu-sva.c

-- 
2.18.0

             reply	other threads:[~2018-09-20 17:00 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-20 17:00 Jean-Philippe Brucker [this message]
     [not found] ` <20180920170046.20154-1-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-09-20 17:00   ` [PATCH v3 01/10] iommu: Introduce Shared Virtual Addressing API Jean-Philippe Brucker
     [not found]     ` <20180920170046.20154-2-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-09-23  2:39       ` Lu Baolu
     [not found]         ` <f406bcf7-4e54-9f1b-88eb-03fc642ffede-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2018-09-24 12:07           ` Jean-Philippe Brucker
2018-09-25 13:16           ` Joerg Roedel
     [not found]             ` <20180925131647.rygncwik5uszsm3n-zLv9SwRftAIdnm+yROfE0A@public.gmane.org>
2018-09-25 22:46               ` Jacob Pan
2018-09-26 10:14                 ` Jean-Philippe Brucker
2018-09-26 12:48                 ` Joerg Roedel
2018-09-20 17:00   ` [PATCH v3 02/10] iommu/sva: Bind process address spaces to devices Jean-Philippe Brucker
     [not found]     ` <20180920170046.20154-3-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-09-23  3:05       ` Lu Baolu
     [not found]         ` <cdcd4083-ef28-4c5e-4a2c-5b93e61a86b4-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2018-09-24 12:07           ` Jean-Philippe Brucker
     [not found]             ` <7cbd503a-c79e-3c40-7388-ce6c23f7f536-5wv7dgnIgG8@public.gmane.org>
2018-09-26 18:01               ` Jacob Pan
2018-09-27 15:06                 ` Jean-Philippe Brucker
     [not found]                   ` <79c0e0e1-691e-b8e1-0e68-21876135d2ab-5wv7dgnIgG8@public.gmane.org>
2018-09-28  1:14                     ` Tian, Kevin
2018-09-20 17:00   ` [PATCH v3 03/10] iommu/sva: Manage process address spaces Jean-Philippe Brucker
     [not found]     ` <20180920170046.20154-4-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-09-25  3:15       ` Lu Baolu
     [not found]         ` <09933fce-b959-32e1-b1f3-0d4389abf735-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2018-09-25 10:32           ` Jean-Philippe Brucker
     [not found]             ` <5aff8dc0-9ce7-5018-e78e-770279681cbc-5wv7dgnIgG8@public.gmane.org>
2018-09-26  3:12               ` Lu Baolu
2018-09-25 13:26           ` Joerg Roedel
     [not found]             ` <20180925132627.vbdotr23o7lqrmnd-zLv9SwRftAIdnm+yROfE0A@public.gmane.org>
2018-09-25 23:33               ` Lu Baolu
     [not found]                 ` <b33a1911-e100-586b-b8df-eb04312ecffd-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2018-09-26 10:20                   ` Jean-Philippe Brucker
     [not found]                     ` <754d495d-d016-f42f-5682-ba4a75a618e0-5wv7dgnIgG8@public.gmane.org>
2018-09-26 12:45                       ` Joerg Roedel
     [not found]                         ` <20180926124527.GD18287-zLv9SwRftAIdnm+yROfE0A@public.gmane.org>
2018-09-26 13:50                           ` Jean-Philippe Brucker
     [not found]                             ` <1f53c6f1-4e7a-1451-1abc-a7bca4a2359d-5wv7dgnIgG8@public.gmane.org>
2018-09-27  3:22                               ` Liu, Yi L
     [not found]                                 ` <A2975661238FB949B60364EF0F2C257439D0CC48-0J0gbvR4kTg/UvCtAeCM4rfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2018-09-27 13:37                                   ` Jean-Philippe Brucker
     [not found]                                     ` <9aedb22e-ff28-7bfd-feeb-ae86802e6400-5wv7dgnIgG8@public.gmane.org>
2018-10-08  8:29                                       ` Liu, Yi L
2018-09-26 22:58                           ` Jacob Pan
2018-09-26 22:35       ` Jacob Pan
2018-10-03 17:52         ` Jean-Philippe Brucker
     [not found]           ` <8ebfd3b5-9e16-85f6-a9f9-2627fb4b5b03-5wv7dgnIgG8@public.gmane.org>
2018-10-15 20:53             ` Jacob Pan
2018-09-20 17:00   ` [PATCH v3 04/10] iommu/sva: Add a mm_exit callback for device drivers Jean-Philippe Brucker
2018-09-20 17:00   ` [PATCH v3 05/10] iommu/sva: Track mm changes with an MMU notifier Jean-Philippe Brucker
2018-09-20 17:00   ` [PATCH v3 06/10] iommu/sva: Search mm by PASID Jean-Philippe Brucker
     [not found]     ` <20180920170046.20154-7-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-09-25  4:59       ` Lu Baolu
2018-09-20 17:00   ` [PATCH v3 07/10] iommu: Add a page fault handler Jean-Philippe Brucker
     [not found]     ` <20180920170046.20154-8-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-09-27 20:37       ` Jacob Pan
2018-10-03 17:46         ` Jean-Philippe Brucker
2018-09-20 17:00   ` [PATCH v3 08/10] iommu/iopf: Handle mm faults Jean-Philippe Brucker
2018-09-20 17:00   ` [PATCH v3 09/10] iommu/sva: Register page fault handler Jean-Philippe Brucker
2018-09-20 17:00   ` [RFC PATCH v3 10/10] iommu/sva: Add support for private PASIDs Jean-Philippe Brucker
     [not found]     ` <20180920170046.20154-11-jean-philippe.brucker-5wv7dgnIgG8@public.gmane.org>
2018-10-12 14:32       ` Jordan Crouse
     [not found]         ` <20181012143229.GI9977-9PYrDHPZ2Orvke4nUoYGnHL1okKdlPRT@public.gmane.org>
2018-10-17 14:21           ` Jean-Philippe Brucker
     [not found]             ` <3e1b58bb-eb16-5855-2922-2b15b37ba971-5wv7dgnIgG8@public.gmane.org>
2018-10-17 14:24               ` Jean-Philippe Brucker
2018-10-17 15:07               ` Jordan Crouse

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180920170046.20154-1-jean-philippe.brucker@arm.com \
    --to=jean-philippe.brucker-5wv7dgnigg8@public.gmane.org \
    --cc=alex.williamson-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=ashok.raj-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
    --cc=christian.koenig-5C7GfCeVMHo@public.gmane.org \
    --cc=ilias.apalodimas-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
    --cc=iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
    --cc=kevin.tian-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
    --cc=liguozhu-C8/M+/jPZTeaMJb+Lgu22Q@public.gmane.org \
    --cc=linux-pci-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=okaya-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org \
    --cc=robin.murphy-5wv7dgnIgG8@public.gmane.org \
    --cc=will.deacon-5wv7dgnIgG8@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).