All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: iommu@lists.linux.dev, kvm@vger.kernel.org,
	linux-kernel@vger.kernel.org, Kevin Tian <kevin.tian@intel.com>
Subject: [GIT PULL] Please pull IOMMUFD subsystem changes
Date: Tue, 21 Feb 2023 11:39:51 -0400	[thread overview]
Message-ID: <Y/Tlx8j3i17n5bzL@nvidia.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 7203 bytes --]

Hi Linus,

This PR has a few smaller updates related to iommufd. Several big topics are
currently still on the mailing list in review:

- VFIO device cdev support to allow exposing all the iommufd features:
  https://lore.kernel.org/kvm/20230221034812.138051-1-yi.l.liu@intel.com/

- iommufd page table replace operation:
  https://lore.kernel.org/kvm/cover.1675802050.git.nicolinc@nvidia.com/

- IOMMU driver information query:
  https://lore.kernel.org/r/20230209041642.9346-1-yi.l.liu@intel.com

- Intel VT-d nested translation:
  https://lore.kernel.org/r/20230209043153.14964-1-yi.l.liu@intel.com

- Draft patches for ARM SMMUv3 nested translation:
  https://github.com/nicolinc/iommufd/commits/wip/iommufd-v6.2-rc5-nesting

Along with qemu patches implementing iommufd:
https://lore.kernel.org/qemu-devel/20230131205305.2726330-1-eric.auger@redhat.com/

And draft patches for the qemu side support for nested translation.

This PR has a shared branch with Joerg's tree changing the signature of
iommu_map() to add a gfp_t. There were some conflicts with v6.2 which I've
resolved in this PR and there will be a conflict against the rpmsg tree:

 https://lore.kernel.org/r/20230127180226.783baf07@canb.auug.org.au

--- a/drivers/remoteproc/qcom_q6v5_adsp.c
+++ b/drivers/remoteproc/qcom_q6v5_adsp.c
@@ -367,7 +367,8 @@ static int adsp_map_carveout(struct rproc *rproc)
        iova =  adsp->mem_phys | (sid << 32);

        ret = iommu_map(rproc->domain, iova, adsp->mem_phys,
-                       adsp->mem_size, IOMMU_READ | IOMMU_WRITE);
+                       adsp->mem_size, IOMMU_READ | IOMMU_WRITE,
+                       GFP_KERNEL);
        if (ret) {
                dev_err(adsp->dev, "Unable to map ADSP Physical Memory\n");
                return ret;

Thanks,
Jason

The following changes since commit c9c3395d5e3dcc6daee66c6908354d47bf98cb0c:

  Linux 6.2 (2023-02-19 14:24:22 -0800)

are available in the Git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/jgg/iommufd.git tags/for-linus-iommufd

for you to fetch changes up to 939204e4df962982cbc84acc26b29b421dd530a8:

  Merge tag 'v6.2' into iommufd.git for-next (2023-02-21 11:11:03 -0400)

----------------------------------------------------------------
iommufd for 6.3

Some polishing and small fixes for iommufd:

- Remove IOMMU_CAP_INTR_REMAP, instead rely on the interrupt subsystem

- Use GFP_KERNEL_ACCOUNT inside the iommu_domains

- Support VFIO_NOIOMMU mode with iommufd

- Various typos

- A list corruption bug if HWPTs are used for attach

----------------------------------------------------------------
Jason Gunthorpe (26):
      genirq/msi: Add msi_device_has_isolated_msi()
      iommu: Add iommu_group_has_isolated_msi()
      vfio/type1: Convert to iommu_group_has_isolated_msi()
      iommufd: Convert to msi_device_has_isolated_msi()
      genirq/irqdomain: Remove unused irq_domain_check_msi_remap() code
      genirq/msi: Rename IRQ_DOMAIN_MSI_REMAP to IRQ_DOMAIN_ISOLATED_MSI
      iommu/x86: Replace IOMMU_CAP_INTR_REMAP with IRQ_DOMAIN_FLAG_ISOLATED_MSI
      irq/s390: Add arch_is_isolated_msi() for s390
      iommu: Remove IOMMU_CAP_INTR_REMAP
      Merge branch 'isolated_msi' into iommufd.git for-next
      iommu: Add a gfp parameter to iommu_map()
      iommu: Remove iommu_map_atomic()
      iommu: Add a gfp parameter to iommu_map_sg()
      iommu/dma: Use the gfp parameter in __iommu_dma_alloc_noncontiguous()
      iommufd: Use GFP_KERNEL_ACCOUNT for iommu_map()
      iommu/intel: Add a gfp parameter to alloc_pgtable_page()
      iommu/intel: Support the gfp argument to the map_pages op
      iommu/intel: Use GFP_KERNEL in sleepable contexts
      iommu/s390: Push the gfp parameter to the kmem_cache_alloc()'s
      iommu/s390: Use GFP_KERNEL in sleepable contexts
      Merge branch 'iommu-memory-accounting' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/joro/iommu intoiommufd/for-next
      vfio: Support VFIO_NOIOMMU with iommufd
      Merge branch 'vfio-no-iommu' into iommufd.git for-next
      iommufd: Make sure to zero vfio_iommu_type1_info before copying to user
      iommufd: Do not add the same hwpt to the ioas->hwpt_list twice
      Merge tag 'v6.2' into iommufd.git for-next

Nicolin Chen (1):
      selftests: iommu: Fix test_cmd_destroy_access() call in user_copy

Yi Liu (1):
      iommufd: Add three missing structures in ucmd_buffer

 arch/arm/mm/dma-mapping.c                          |  11 ++-
 arch/s390/include/asm/msi.h                        |  17 ++++
 arch/s390/include/asm/pci_dma.h                    |   5 +-
 arch/s390/pci/pci_dma.c                            |  31 +++---
 .../gpu/drm/nouveau/nvkm/subdev/instmem/gk20a.c    |   3 +-
 drivers/gpu/drm/tegra/drm.c                        |   2 +-
 drivers/gpu/host1x/cdma.c                          |   2 +-
 drivers/infiniband/hw/usnic/usnic_uiom.c           |   8 +-
 drivers/iommu/amd/iommu.c                          |   5 +-
 drivers/iommu/dma-iommu.c                          |  18 +++-
 drivers/iommu/intel/iommu.c                        |  38 ++++----
 drivers/iommu/intel/iommu.h                        |   2 +-
 drivers/iommu/intel/irq_remapping.c                |   3 +-
 drivers/iommu/intel/pasid.c                        |   2 +-
 drivers/iommu/iommu.c                              |  77 ++++++++-------
 drivers/iommu/iommufd/Kconfig                      |   2 +-
 drivers/iommu/iommufd/device.c                     |   8 +-
 drivers/iommu/iommufd/iommufd_private.h            |   2 +
 drivers/iommu/iommufd/main.c                       |   3 +
 drivers/iommu/iommufd/pages.c                      |   6 +-
 drivers/iommu/iommufd/vfio_compat.c                | 107 +++++++++++++++++----
 drivers/iommu/s390-iommu.c                         |  17 ++--
 drivers/irqchip/irq-gic-v3-its.c                   |   4 +-
 drivers/media/platform/qcom/venus/firmware.c       |   2 +-
 drivers/net/ipa/ipa_mem.c                          |   6 +-
 drivers/net/wireless/ath/ath10k/snoc.c             |   2 +-
 drivers/net/wireless/ath/ath11k/ahb.c              |   4 +-
 drivers/remoteproc/remoteproc_core.c               |   5 +-
 drivers/vfio/Kconfig                               |   2 +-
 drivers/vfio/container.c                           |   7 --
 drivers/vfio/group.c                               |   7 +-
 drivers/vfio/iommufd.c                             |  19 +++-
 drivers/vfio/vfio.h                                |   8 +-
 drivers/vfio/vfio_iommu_type1.c                    |  25 ++---
 drivers/vfio/vfio_main.c                           |   7 ++
 drivers/vhost/vdpa.c                               |   2 +-
 include/linux/iommu.h                              |  33 ++-----
 include/linux/iommufd.h                            |  12 ++-
 include/linux/irqdomain.h                          |  29 +-----
 include/linux/msi.h                                |  17 ++++
 kernel/irq/irqdomain.c                             |  39 --------
 kernel/irq/msi.c                                   |  27 ++++++
 tools/testing/selftests/iommu/iommufd.c            |   2 +-
 43 files changed, 369 insertions(+), 259 deletions(-)
 create mode 100644 arch/s390/include/asm/msi.h

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

             reply	other threads:[~2023-02-21 15:40 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-21 15:39 Jason Gunthorpe [this message]
2023-02-24 22:50 ` [GIT PULL] Please pull IOMMUFD subsystem changes Linus Torvalds
2023-02-25  0:02   ` Jason Gunthorpe
2023-02-25  0:50     ` Linus Torvalds
2023-02-24 23:27 ` pr-tracker-bot
  -- strict thread matches above, loose matches on Subject: below --
2024-04-19 17:29 Jason Gunthorpe
2024-04-19 21:07 ` pr-tracker-bot
2024-03-02  0:08 Jason Gunthorpe
2024-03-02  1:31 ` pr-tracker-bot
2024-02-22 13:23 Jason Gunthorpe
2024-02-22 20:03 ` pr-tracker-bot
2024-01-12 17:49 Jason Gunthorpe
2024-01-18 23:35 ` pr-tracker-bot
2023-12-04 19:35 Jason Gunthorpe
2023-12-04 21:59 ` pr-tracker-bot
2023-10-31 13:14 Jason Gunthorpe
2023-11-02  2:51 ` pr-tracker-bot
2023-08-30 23:40 Jason Gunthorpe
2023-08-31  3:50 ` pr-tracker-bot
2023-08-31  3:59 ` Linus Torvalds
2023-08-31 16:43   ` Jason Gunthorpe
2023-07-28 13:48 Jason Gunthorpe
2023-07-28 18:39 ` pr-tracker-bot
2023-06-28 14:04 Jason Gunthorpe
2023-06-30  4:16 ` pr-tracker-bot
2023-04-25 14:46 Jason Gunthorpe
2023-04-27 17:15 ` pr-tracker-bot
2023-04-06 13:34 Jason Gunthorpe
2023-04-06 18:46 ` pr-tracker-bot
2022-12-12 18:30 Jason Gunthorpe
2022-12-14 18:04 ` pr-tracker-bot

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=Y/Tlx8j3i17n5bzL@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=iommu@lists.linux.dev \
    --cc=kevin.tian@intel.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.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 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.