From: Joerg Roedel <joro@8bytes.org>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: iommu@lists.linux-foundation.org, Will Deacon <will@kernel.org>,
linux-kernel@vger.kernel.org
Subject: [git pull] IOMMU Updates for Linux v5.16
Date: Thu, 4 Nov 2021 15:16:22 +0100 [thread overview]
Message-ID: <YYPrNkweZahTdAbA@8bytes.org> (raw)
[-- Attachment #1.1: Type: text/plain, Size: 8320 bytes --]
Hi Linus,
there is a merge conflict this time between the IOMMU tree and FPU
changes which came from the tip tree. My conflict resolution is
attached. With that in mind:
The following changes since commit 8bb7eca972ad531c9b149c0a51ab43a417385813:
Linux 5.15 (2021-10-31 13:53:10 -0700)
are available in the Git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git tags/iommu-updates-v5.16
for you to fetch changes up to 52d96919d6a846aace5841cd23055927c6e6ec2c:
Merge branches 'apple/dart', 'arm/mediatek', 'arm/renesas', 'arm/smmu', 'arm/tegra', 'iommu/fixes', 'x86/amd', 'x86/vt-d' and 'core' into next (2021-10-31 22:26:53 +0100)
----------------------------------------------------------------
IOMMU Updates for Linux v5.16:
Including:
- Intel IOMMU Updates fro Lu Baolu:
- Dump DMAR translation structure when DMA fault occurs
- An optimization in the page table manipulation code
- Use second level for GPA->HPA translation
- Various cleanups
- Arm SMMU Updates from Will
- Minor optimisations to SMMUv3 command creation and submission
- Numerous new compatible string for Qualcomm SMMUv2 implementations
- Fixes for the SWIOTLB based implemenation of dma-iommu code for
untrusted devices
- Add support for r8a779a0 to the Renesas IOMMU driver and DT matching
code for r8a77980
- A couple of cleanups and fixes for the Apple DART IOMMU driver
- Make use of generic report_iommu_fault() interface in the AMD IOMMU
driver
- Various smaller fixes and cleanups
----------------------------------------------------------------
Arnd Bergmann (1):
iommu/mediatek: Fix out-of-range warning with clang
Christophe JAILLET (1):
iommu/tegra-smmu: Use devm_bitmap_zalloc when applicable
David Stevens (7):
iommu/dma: Fix sync_sg with swiotlb
iommu/dma: Fix arch_sync_dma for map
iommu/dma: Skip extra sync during unmap w/swiotlb
iommu/dma: Fold _swiotlb helpers into callers
iommu/dma: Check CONFIG_SWIOTLB more broadly
swiotlb: Support aligned swiotlb buffers
iommu/dma: Account for min_align_mask w/swiotlb
Fenghua Yu (1):
iommu/vt-d: Clean up unused PASID updating functions
Gustavo A. R. Silva (1):
iommu/dma: Use kvcalloc() instead of kvzalloc()
Joerg Roedel (2):
Merge tag 'arm-smmu-updates' of git://git.kernel.org/pub/scm/linux/kernel/git/will/linux into arm/smmu
Merge branches 'apple/dart', 'arm/mediatek', 'arm/renesas', 'arm/smmu', 'arm/tegra', 'iommu/fixes', 'x86/amd', 'x86/vt-d' and 'core' into next
Konrad Dybcio (2):
dt-bindings: arm-smmu: Add compatible for SM6350 SoC
iommu/arm-smmu-qcom: Add SM6350 SMMU compatible
Kyung Min Park (1):
iommu/vt-d: Dump DMAR translation structure when DMA fault occurs
Lennert Buytenhek (1):
iommu/amd: Use report_iommu_fault()
Logan Gunthorpe (1):
iommu/dma: Fix incorrect error return on iommu deferred attach
Loic Poulain (2):
dt-bindings: arm-smmu: Add compatible for QCM2290 SoC
iommu: arm-smmu-qcom: Add compatible for QCM2290
Longpeng(Mike) (2):
iommu/vt-d: Convert the return type of first_pte_in_page to bool
iommu/vt-d: Avoid duplicate removing in __domain_mapping()
Lu Baolu (4):
iommu/vt-d: Remove duplicate identity domain flag
iommu/vt-d: Check FL and SL capability sanity in scalable mode
iommu/vt-d: Use second level for GPA->HPA translation
iommu/vt-d: Delete dev_has_feat callback
Nikita Yushchenko (1):
iommu/ipmmu-vmsa: Hook up r8a77980 DT matching code
Robin Murphy (2):
iommu/dart: Clean up IOVA cookie crumbs
iommu/dma: Unexport IOVA cookie management
Sibi Sankar (1):
iommu/arm-smmu-qcom: Request direct mapping for modem device
Sven Peter (1):
iommu/dart: Initialize DART_STREAMS_ENABLE
Tvrtko Ursulin (1):
iommu/vt-d: Do not falsely log intel_iommu is unsupported kernel option
Wan Jiabing (1):
iommu/dart: Use kmemdup instead of kzalloc and memcpy
Yoshihiro Shimoda (2):
dt-bindings: iommu: renesas,ipmmu-vmsa: add r8a779a0 support
iommu/ipmmu-vmsa: Add support for r8a779a0
Zhen Lei (2):
iommu/arm-smmu-v3: Stop pre-zeroing batch commands in arm_smmu_atc_inv_master()
iommu/arm-smmu-v3: Properly handle the return value of arm_smmu_cmdq_build_cmd()
.../devicetree/bindings/iommu/arm,smmu.yaml | 2 +
.../bindings/iommu/renesas,ipmmu-vmsa.yaml | 1 +
arch/x86/include/asm/fpu/api.h | 2 -
drivers/iommu/amd/amd_iommu_types.h | 2 +
drivers/iommu/amd/iommu.c | 21 ++
drivers/iommu/apple-dart.c | 10 +-
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c | 21 +-
drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c | 3 +
drivers/iommu/dma-iommu.c | 200 +++++++++----------
drivers/iommu/intel/Kconfig | 4 +
drivers/iommu/intel/cap_audit.c | 13 ++
drivers/iommu/intel/cap_audit.h | 1 +
drivers/iommu/intel/dmar.c | 10 +-
drivers/iommu/intel/iommu.c | 213 ++++++++++++++-------
drivers/iommu/intel/svm.c | 24 +--
drivers/iommu/iommu.c | 3 +-
drivers/iommu/ipmmu-vmsa.c | 32 +++-
drivers/iommu/mtk_iommu.c | 4 +-
drivers/iommu/tegra-smmu.c | 5 +-
drivers/xen/swiotlb-xen.c | 2 +-
include/linux/dmar.h | 8 +
include/linux/intel-iommu.h | 13 +-
include/linux/swiotlb.h | 3 +-
kernel/dma/swiotlb.c | 13 +-
24 files changed, 367 insertions(+), 243 deletions(-)
Please pull.
Thanks,
Joerg
diff --cc arch/x86/include/asm/fpu/api.h
index b7267b9e452f,ca4d0dee1ecd..6053674f9132
--- a/arch/x86/include/asm/fpu/api.h
+++ b/arch/x86/include/asm/fpu/api.h
@@@ -108,58 -106,4 +108,56 @@@ extern int cpu_has_xfeatures(u64 xfeatu
*/
#define PASID_DISABLED 0
- static inline void update_pasid(void) { }
-
+/* Trap handling */
+extern int fpu__exception_code(struct fpu *fpu, int trap_nr);
+extern void fpu_sync_fpstate(struct fpu *fpu);
+extern void fpu_reset_from_exception_fixup(void);
+
+/* Boot, hotplug and resume */
+extern void fpu__init_cpu(void);
+extern void fpu__init_system(struct cpuinfo_x86 *c);
+extern void fpu__init_check_bugs(void);
+extern void fpu__resume_cpu(void);
+
+#ifdef CONFIG_MATH_EMULATION
+extern void fpstate_init_soft(struct swregs_state *soft);
+#else
+static inline void fpstate_init_soft(struct swregs_state *soft) {}
+#endif
+
+/* State tracking */
+DECLARE_PER_CPU(struct fpu *, fpu_fpregs_owner_ctx);
+
+/* Process cleanup */
+#ifdef CONFIG_X86_64
+extern void fpstate_free(struct fpu *fpu);
+#else
+static inline void fpstate_free(struct fpu *fpu) { }
+#endif
+
+/* fpstate-related functions which are exported to KVM */
+extern void fpstate_clear_xstate_component(struct fpstate *fps, unsigned int xfeature);
+
+/* KVM specific functions */
+extern bool fpu_alloc_guest_fpstate(struct fpu_guest *gfpu);
+extern void fpu_free_guest_fpstate(struct fpu_guest *gfpu);
+extern int fpu_swap_kvm_fpstate(struct fpu_guest *gfpu, bool enter_guest);
+
+extern void fpu_copy_guest_fpstate_to_uabi(struct fpu_guest *gfpu, void *buf, unsigned int size, u32 pkru);
+extern int fpu_copy_uabi_to_guest_fpstate(struct fpu_guest *gfpu, const void *buf, u64 xcr0, u32 *vpkru);
+
+static inline void fpstate_set_confidential(struct fpu_guest *gfpu)
+{
+ gfpu->fpstate->is_confidential = true;
+}
+
+static inline bool fpstate_is_confidential(struct fpu_guest *gfpu)
+{
+ return gfpu->fpstate->is_confidential;
+}
+
+/* prctl */
+struct task_struct;
+extern long fpu_xstate_prctl(struct task_struct *tsk, int option, unsigned long arg2);
+
#endif /* _ASM_X86_FPU_API_H */
[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
[-- Attachment #2: Type: text/plain, Size: 156 bytes --]
_______________________________________________
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu
WARNING: multiple messages have this Message-ID (diff)
From: Joerg Roedel <joro@8bytes.org>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Will Deacon <will@kernel.org>,
linux-kernel@vger.kernel.org, iommu@lists.linux-foundation.org
Subject: [git pull] IOMMU Updates for Linux v5.16
Date: Thu, 4 Nov 2021 15:16:22 +0100 [thread overview]
Message-ID: <YYPrNkweZahTdAbA@8bytes.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 8320 bytes --]
Hi Linus,
there is a merge conflict this time between the IOMMU tree and FPU
changes which came from the tip tree. My conflict resolution is
attached. With that in mind:
The following changes since commit 8bb7eca972ad531c9b149c0a51ab43a417385813:
Linux 5.15 (2021-10-31 13:53:10 -0700)
are available in the Git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git tags/iommu-updates-v5.16
for you to fetch changes up to 52d96919d6a846aace5841cd23055927c6e6ec2c:
Merge branches 'apple/dart', 'arm/mediatek', 'arm/renesas', 'arm/smmu', 'arm/tegra', 'iommu/fixes', 'x86/amd', 'x86/vt-d' and 'core' into next (2021-10-31 22:26:53 +0100)
----------------------------------------------------------------
IOMMU Updates for Linux v5.16:
Including:
- Intel IOMMU Updates fro Lu Baolu:
- Dump DMAR translation structure when DMA fault occurs
- An optimization in the page table manipulation code
- Use second level for GPA->HPA translation
- Various cleanups
- Arm SMMU Updates from Will
- Minor optimisations to SMMUv3 command creation and submission
- Numerous new compatible string for Qualcomm SMMUv2 implementations
- Fixes for the SWIOTLB based implemenation of dma-iommu code for
untrusted devices
- Add support for r8a779a0 to the Renesas IOMMU driver and DT matching
code for r8a77980
- A couple of cleanups and fixes for the Apple DART IOMMU driver
- Make use of generic report_iommu_fault() interface in the AMD IOMMU
driver
- Various smaller fixes and cleanups
----------------------------------------------------------------
Arnd Bergmann (1):
iommu/mediatek: Fix out-of-range warning with clang
Christophe JAILLET (1):
iommu/tegra-smmu: Use devm_bitmap_zalloc when applicable
David Stevens (7):
iommu/dma: Fix sync_sg with swiotlb
iommu/dma: Fix arch_sync_dma for map
iommu/dma: Skip extra sync during unmap w/swiotlb
iommu/dma: Fold _swiotlb helpers into callers
iommu/dma: Check CONFIG_SWIOTLB more broadly
swiotlb: Support aligned swiotlb buffers
iommu/dma: Account for min_align_mask w/swiotlb
Fenghua Yu (1):
iommu/vt-d: Clean up unused PASID updating functions
Gustavo A. R. Silva (1):
iommu/dma: Use kvcalloc() instead of kvzalloc()
Joerg Roedel (2):
Merge tag 'arm-smmu-updates' of git://git.kernel.org/pub/scm/linux/kernel/git/will/linux into arm/smmu
Merge branches 'apple/dart', 'arm/mediatek', 'arm/renesas', 'arm/smmu', 'arm/tegra', 'iommu/fixes', 'x86/amd', 'x86/vt-d' and 'core' into next
Konrad Dybcio (2):
dt-bindings: arm-smmu: Add compatible for SM6350 SoC
iommu/arm-smmu-qcom: Add SM6350 SMMU compatible
Kyung Min Park (1):
iommu/vt-d: Dump DMAR translation structure when DMA fault occurs
Lennert Buytenhek (1):
iommu/amd: Use report_iommu_fault()
Logan Gunthorpe (1):
iommu/dma: Fix incorrect error return on iommu deferred attach
Loic Poulain (2):
dt-bindings: arm-smmu: Add compatible for QCM2290 SoC
iommu: arm-smmu-qcom: Add compatible for QCM2290
Longpeng(Mike) (2):
iommu/vt-d: Convert the return type of first_pte_in_page to bool
iommu/vt-d: Avoid duplicate removing in __domain_mapping()
Lu Baolu (4):
iommu/vt-d: Remove duplicate identity domain flag
iommu/vt-d: Check FL and SL capability sanity in scalable mode
iommu/vt-d: Use second level for GPA->HPA translation
iommu/vt-d: Delete dev_has_feat callback
Nikita Yushchenko (1):
iommu/ipmmu-vmsa: Hook up r8a77980 DT matching code
Robin Murphy (2):
iommu/dart: Clean up IOVA cookie crumbs
iommu/dma: Unexport IOVA cookie management
Sibi Sankar (1):
iommu/arm-smmu-qcom: Request direct mapping for modem device
Sven Peter (1):
iommu/dart: Initialize DART_STREAMS_ENABLE
Tvrtko Ursulin (1):
iommu/vt-d: Do not falsely log intel_iommu is unsupported kernel option
Wan Jiabing (1):
iommu/dart: Use kmemdup instead of kzalloc and memcpy
Yoshihiro Shimoda (2):
dt-bindings: iommu: renesas,ipmmu-vmsa: add r8a779a0 support
iommu/ipmmu-vmsa: Add support for r8a779a0
Zhen Lei (2):
iommu/arm-smmu-v3: Stop pre-zeroing batch commands in arm_smmu_atc_inv_master()
iommu/arm-smmu-v3: Properly handle the return value of arm_smmu_cmdq_build_cmd()
.../devicetree/bindings/iommu/arm,smmu.yaml | 2 +
.../bindings/iommu/renesas,ipmmu-vmsa.yaml | 1 +
arch/x86/include/asm/fpu/api.h | 2 -
drivers/iommu/amd/amd_iommu_types.h | 2 +
drivers/iommu/amd/iommu.c | 21 ++
drivers/iommu/apple-dart.c | 10 +-
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c | 21 +-
drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c | 3 +
drivers/iommu/dma-iommu.c | 200 +++++++++----------
drivers/iommu/intel/Kconfig | 4 +
drivers/iommu/intel/cap_audit.c | 13 ++
drivers/iommu/intel/cap_audit.h | 1 +
drivers/iommu/intel/dmar.c | 10 +-
drivers/iommu/intel/iommu.c | 213 ++++++++++++++-------
drivers/iommu/intel/svm.c | 24 +--
drivers/iommu/iommu.c | 3 +-
drivers/iommu/ipmmu-vmsa.c | 32 +++-
drivers/iommu/mtk_iommu.c | 4 +-
drivers/iommu/tegra-smmu.c | 5 +-
drivers/xen/swiotlb-xen.c | 2 +-
include/linux/dmar.h | 8 +
include/linux/intel-iommu.h | 13 +-
include/linux/swiotlb.h | 3 +-
kernel/dma/swiotlb.c | 13 +-
24 files changed, 367 insertions(+), 243 deletions(-)
Please pull.
Thanks,
Joerg
diff --cc arch/x86/include/asm/fpu/api.h
index b7267b9e452f,ca4d0dee1ecd..6053674f9132
--- a/arch/x86/include/asm/fpu/api.h
+++ b/arch/x86/include/asm/fpu/api.h
@@@ -108,58 -106,4 +108,56 @@@ extern int cpu_has_xfeatures(u64 xfeatu
*/
#define PASID_DISABLED 0
- static inline void update_pasid(void) { }
-
+/* Trap handling */
+extern int fpu__exception_code(struct fpu *fpu, int trap_nr);
+extern void fpu_sync_fpstate(struct fpu *fpu);
+extern void fpu_reset_from_exception_fixup(void);
+
+/* Boot, hotplug and resume */
+extern void fpu__init_cpu(void);
+extern void fpu__init_system(struct cpuinfo_x86 *c);
+extern void fpu__init_check_bugs(void);
+extern void fpu__resume_cpu(void);
+
+#ifdef CONFIG_MATH_EMULATION
+extern void fpstate_init_soft(struct swregs_state *soft);
+#else
+static inline void fpstate_init_soft(struct swregs_state *soft) {}
+#endif
+
+/* State tracking */
+DECLARE_PER_CPU(struct fpu *, fpu_fpregs_owner_ctx);
+
+/* Process cleanup */
+#ifdef CONFIG_X86_64
+extern void fpstate_free(struct fpu *fpu);
+#else
+static inline void fpstate_free(struct fpu *fpu) { }
+#endif
+
+/* fpstate-related functions which are exported to KVM */
+extern void fpstate_clear_xstate_component(struct fpstate *fps, unsigned int xfeature);
+
+/* KVM specific functions */
+extern bool fpu_alloc_guest_fpstate(struct fpu_guest *gfpu);
+extern void fpu_free_guest_fpstate(struct fpu_guest *gfpu);
+extern int fpu_swap_kvm_fpstate(struct fpu_guest *gfpu, bool enter_guest);
+
+extern void fpu_copy_guest_fpstate_to_uabi(struct fpu_guest *gfpu, void *buf, unsigned int size, u32 pkru);
+extern int fpu_copy_uabi_to_guest_fpstate(struct fpu_guest *gfpu, const void *buf, u64 xcr0, u32 *vpkru);
+
+static inline void fpstate_set_confidential(struct fpu_guest *gfpu)
+{
+ gfpu->fpstate->is_confidential = true;
+}
+
+static inline bool fpstate_is_confidential(struct fpu_guest *gfpu)
+{
+ return gfpu->fpstate->is_confidential;
+}
+
+/* prctl */
+struct task_struct;
+extern long fpu_xstate_prctl(struct task_struct *tsk, int option, unsigned long arg2);
+
#endif /* _ASM_X86_FPU_API_H */
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next reply other threads:[~2021-11-04 14:16 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-04 14:16 Joerg Roedel [this message]
2021-11-04 14:16 ` [git pull] IOMMU Updates for Linux v5.16 Joerg Roedel
2021-11-04 18:10 ` Linus Torvalds
2021-11-04 18:10 ` Linus Torvalds
2021-11-05 7:35 ` Joerg Roedel
2021-11-05 7:35 ` Joerg Roedel
2021-11-05 8:04 ` Lu Baolu
2021-11-05 8:04 ` Lu Baolu
2021-11-04 18:51 ` pr-tracker-bot
2021-11-04 18:51 ` 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=YYPrNkweZahTdAbA@8bytes.org \
--to=joro@8bytes.org \
--cc=iommu@lists.linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@linux-foundation.org \
--cc=will@kernel.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.