]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
drop some broken s390 and powerpc patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 26 Nov 2023 15:41:16 +0000 (15:41 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 26 Nov 2023 15:41:16 +0000 (15:41 +0000)
17 files changed:
queue-4.19/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch [deleted file]
queue-4.19/series
queue-5.10/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch [deleted file]
queue-5.10/series
queue-5.15/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch [deleted file]
queue-5.15/series
queue-5.4/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch [deleted file]
queue-5.4/series
queue-6.1/powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch [deleted file]
queue-6.1/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch [deleted file]
queue-6.1/series
queue-6.5/powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch [deleted file]
queue-6.5/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch [deleted file]
queue-6.5/series
queue-6.6/powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch [deleted file]
queue-6.6/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch [deleted file]
queue-6.6/series

diff --git a/queue-4.19/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch b/queue-4.19/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
deleted file mode 100644 (file)
index 8cbc7fa..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-From 84bb41d5df48868055d159d9247b80927f1f70f9 Mon Sep 17 00:00:00 2001
-From: Heiko Carstens <hca@linux.ibm.com>
-Date: Tue, 24 Oct 2023 10:15:20 +0200
-Subject: s390/cmma: fix handling of swapper_pg_dir and invalid_pg_dir
-
-From: Heiko Carstens <hca@linux.ibm.com>
-
-commit 84bb41d5df48868055d159d9247b80927f1f70f9 upstream.
-
-If the cmma no-dat feature is available the kernel page tables are walked
-to identify and mark all pages which are used for address translation (all
-region, segment, and page tables). In a subsequent loop all other pages are
-marked as "no-dat" pages with the ESSA instruction.
-
-This information is visible to the hypervisor, so that the hypervisor can
-optimize purging of guest TLB entries. All pages used for swapper_pg_dir
-and invalid_pg_dir are incorrectly marked as no-dat, which in turn can
-result in incorrect guest TLB flushes.
-
-Fix this by marking those pages correctly as being used for DAT.
-
-Cc: <stable@vger.kernel.org>
-Reviewed-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
-Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
-Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/s390/mm/page-states.c |    6 ++++++
- 1 file changed, 6 insertions(+)
-
---- a/arch/s390/mm/page-states.c
-+++ b/arch/s390/mm/page-states.c
-@@ -197,6 +197,12 @@ void __init cmma_init_nodat(void)
-               return;
-       /* Mark pages used in kernel page tables */
-       mark_kernel_pgd();
-+      page = virt_to_page(&swapper_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-+      page = virt_to_page(&invalid_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-       /* Set all kernel pages not used for page tables to stable/no-dat */
-       for_each_memblock(memory, reg) {
index d71e3ccee69cf107313cd65a7189ca1a8de2903a..390cb5c073efa0c14d324125c624e669a096ffe8 100644 (file)
@@ -65,7 +65,6 @@ jbd2-fix-potential-data-lost-in-recovering-journal-raced-with-synchronizing-fs-b
 quota-explicitly-forbid-quota-files-from-being-encrypted.patch
 mcb-fix-error-handling-for-different-scenarios-when-parsing.patch
 dmaengine-stm32-mdma-correct-desc-prep-when-channel-running.patch
-s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
 parisc-prevent-booting-64-bit-kernels-on-pa1.x-machines.patch
 parisc-pgtable-do-not-drop-upper-5-address-bits-of-physical-address.patch
 alsa-info-fix-potential-deadlock-at-disconnection.patch
diff --git a/queue-5.10/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch b/queue-5.10/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
deleted file mode 100644 (file)
index d11c626..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-From 84bb41d5df48868055d159d9247b80927f1f70f9 Mon Sep 17 00:00:00 2001
-From: Heiko Carstens <hca@linux.ibm.com>
-Date: Tue, 24 Oct 2023 10:15:20 +0200
-Subject: s390/cmma: fix handling of swapper_pg_dir and invalid_pg_dir
-
-From: Heiko Carstens <hca@linux.ibm.com>
-
-commit 84bb41d5df48868055d159d9247b80927f1f70f9 upstream.
-
-If the cmma no-dat feature is available the kernel page tables are walked
-to identify and mark all pages which are used for address translation (all
-region, segment, and page tables). In a subsequent loop all other pages are
-marked as "no-dat" pages with the ESSA instruction.
-
-This information is visible to the hypervisor, so that the hypervisor can
-optimize purging of guest TLB entries. All pages used for swapper_pg_dir
-and invalid_pg_dir are incorrectly marked as no-dat, which in turn can
-result in incorrect guest TLB flushes.
-
-Fix this by marking those pages correctly as being used for DAT.
-
-Cc: <stable@vger.kernel.org>
-Reviewed-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
-Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
-Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/s390/mm/page-states.c |    6 ++++++
- 1 file changed, 6 insertions(+)
-
---- a/arch/s390/mm/page-states.c
-+++ b/arch/s390/mm/page-states.c
-@@ -191,6 +191,12 @@ void __init cmma_init_nodat(void)
-               return;
-       /* Mark pages used in kernel page tables */
-       mark_kernel_pgd();
-+      page = virt_to_page(&swapper_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-+      page = virt_to_page(&invalid_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-       /* Set all kernel pages not used for page tables to stable/no-dat */
-       for_each_mem_pfn_range(i, MAX_NUMNODES, &start, &end, NULL) {
index c07bfb85200b01a3ce444001200ae98e55d75ac6..4662bfdb2ccbfad771a4c6361b862126e8992de5 100644 (file)
@@ -131,7 +131,6 @@ kernel-reboot-emergency_restart-set-correct-system_state.patch
 i2c-core-run-atomic-i2c-xfer-when-preemptible.patch
 mcb-fix-error-handling-for-different-scenarios-when-parsing.patch
 dmaengine-stm32-mdma-correct-desc-prep-when-channel-running.patch
-s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
 mm-cma-use-nth_page-in-place-of-direct-struct-page-manipulation.patch
 mm-memory_hotplug-use-pfn-math-in-place-of-direct-struct-page-manipulation.patch
 mtd-cfi_cmdset_0001-byte-swap-otp-info.patch
diff --git a/queue-5.15/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch b/queue-5.15/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
deleted file mode 100644 (file)
index d11c626..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-From 84bb41d5df48868055d159d9247b80927f1f70f9 Mon Sep 17 00:00:00 2001
-From: Heiko Carstens <hca@linux.ibm.com>
-Date: Tue, 24 Oct 2023 10:15:20 +0200
-Subject: s390/cmma: fix handling of swapper_pg_dir and invalid_pg_dir
-
-From: Heiko Carstens <hca@linux.ibm.com>
-
-commit 84bb41d5df48868055d159d9247b80927f1f70f9 upstream.
-
-If the cmma no-dat feature is available the kernel page tables are walked
-to identify and mark all pages which are used for address translation (all
-region, segment, and page tables). In a subsequent loop all other pages are
-marked as "no-dat" pages with the ESSA instruction.
-
-This information is visible to the hypervisor, so that the hypervisor can
-optimize purging of guest TLB entries. All pages used for swapper_pg_dir
-and invalid_pg_dir are incorrectly marked as no-dat, which in turn can
-result in incorrect guest TLB flushes.
-
-Fix this by marking those pages correctly as being used for DAT.
-
-Cc: <stable@vger.kernel.org>
-Reviewed-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
-Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
-Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/s390/mm/page-states.c |    6 ++++++
- 1 file changed, 6 insertions(+)
-
---- a/arch/s390/mm/page-states.c
-+++ b/arch/s390/mm/page-states.c
-@@ -191,6 +191,12 @@ void __init cmma_init_nodat(void)
-               return;
-       /* Mark pages used in kernel page tables */
-       mark_kernel_pgd();
-+      page = virt_to_page(&swapper_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-+      page = virt_to_page(&invalid_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-       /* Set all kernel pages not used for page tables to stable/no-dat */
-       for_each_mem_pfn_range(i, MAX_NUMNODES, &start, &end, NULL) {
index 30472471d5e8dae83131cdd99b575ec32e612bc0..9eee137f6d4eb3f39f0bede3b80f456dbebe6ea8 100644 (file)
@@ -216,7 +216,6 @@ tracing-have-the-user-copy-of-synthetic-event-address-use-correct-context.patch
 mcb-fix-error-handling-for-different-scenarios-when-parsing.patch
 dmaengine-stm32-mdma-correct-desc-prep-when-channel-running.patch
 s390-cmma-fix-detection-of-dat-pages.patch
-s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
 mm-cma-use-nth_page-in-place-of-direct-struct-page-manipulation.patch
 mm-memory_hotplug-use-pfn-math-in-place-of-direct-struct-page-manipulation.patch
 mtd-cfi_cmdset_0001-byte-swap-otp-info.patch
diff --git a/queue-5.4/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch b/queue-5.4/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
deleted file mode 100644 (file)
index 352a2e0..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-From 84bb41d5df48868055d159d9247b80927f1f70f9 Mon Sep 17 00:00:00 2001
-From: Heiko Carstens <hca@linux.ibm.com>
-Date: Tue, 24 Oct 2023 10:15:20 +0200
-Subject: s390/cmma: fix handling of swapper_pg_dir and invalid_pg_dir
-
-From: Heiko Carstens <hca@linux.ibm.com>
-
-commit 84bb41d5df48868055d159d9247b80927f1f70f9 upstream.
-
-If the cmma no-dat feature is available the kernel page tables are walked
-to identify and mark all pages which are used for address translation (all
-region, segment, and page tables). In a subsequent loop all other pages are
-marked as "no-dat" pages with the ESSA instruction.
-
-This information is visible to the hypervisor, so that the hypervisor can
-optimize purging of guest TLB entries. All pages used for swapper_pg_dir
-and invalid_pg_dir are incorrectly marked as no-dat, which in turn can
-result in incorrect guest TLB flushes.
-
-Fix this by marking those pages correctly as being used for DAT.
-
-Cc: <stable@vger.kernel.org>
-Reviewed-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
-Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
-Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/s390/mm/page-states.c |    6 ++++++
- 1 file changed, 6 insertions(+)
-
---- a/arch/s390/mm/page-states.c
-+++ b/arch/s390/mm/page-states.c
-@@ -191,6 +191,12 @@ void __init cmma_init_nodat(void)
-               return;
-       /* Mark pages used in kernel page tables */
-       mark_kernel_pgd();
-+      page = virt_to_page(&swapper_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-+      page = virt_to_page(&invalid_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-       /* Set all kernel pages not used for page tables to stable/no-dat */
-       for_each_memblock(memory, reg) {
index 128bceb26059fadc5b7db8031036722697d7de2c..809dcb6e82ef5602b06fef508367522d8b7b8995 100644 (file)
@@ -90,7 +90,6 @@ kernel-reboot-emergency_restart-set-correct-system_state.patch
 i2c-core-run-atomic-i2c-xfer-when-preemptible.patch
 mcb-fix-error-handling-for-different-scenarios-when-parsing.patch
 dmaengine-stm32-mdma-correct-desc-prep-when-channel-running.patch
-s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
 mm-cma-use-nth_page-in-place-of-direct-struct-page-manipulation.patch
 i3c-master-cdns-fix-reading-status-register.patch
 parisc-prevent-booting-64-bit-kernels-on-pa1.x-machines.patch
diff --git a/queue-6.1/powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch b/queue-6.1/powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch
deleted file mode 100644 (file)
index 9542e7d..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-From 3bf983e4e93ce8e6d69e9d63f52a66ec0856672e Mon Sep 17 00:00:00 2001
-From: Gaurav Batra <gbatra@linux.vnet.ibm.com>
-Date: Mon, 2 Oct 2023 22:08:02 -0500
-Subject: powerpc/pseries/iommu: enable_ddw incorrectly returns direct mapping for SR-IOV device
-
-From: Gaurav Batra <gbatra@linux.vnet.ibm.com>
-
-commit 3bf983e4e93ce8e6d69e9d63f52a66ec0856672e upstream.
-
-When a device is initialized, the driver invokes dma_supported() twice -
-first for streaming mappings followed by coherent mappings. For an
-SR-IOV device, default window is deleted and DDW created. With vPMEM
-enabled, TCE mappings are dynamically created for both vPMEM and SR-IOV
-device.  There are no direct mappings.
-
-First time when dma_supported() is called with 64 bit mask, DDW is created
-and marked as dynamic window. The second time dma_supported() is called,
-enable_ddw() finds existing window for the device and incorrectly returns
-it as "direct mapping".
-
-This only happens when size of DDW is big enough to map max LPAR memory.
-
-This results in streaming TCEs to not get dynamically mapped, since code
-incorrently assumes these are already pre-mapped. The adapter initially
-comes up but goes down due to EEH.
-
-Fixes: 381ceda88c4c ("powerpc/pseries/iommu: Make use of DDW for indirect mapping")
-Cc: stable@vger.kernel.org # v5.15+
-Signed-off-by: Gaurav Batra <gbatra@linux.vnet.ibm.com>
-Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
-Link: https://msgid.link/20231003030802.47914-1-gbatra@linux.vnet.ibm.com
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/powerpc/platforms/pseries/iommu.c |    8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
---- a/arch/powerpc/platforms/pseries/iommu.c
-+++ b/arch/powerpc/platforms/pseries/iommu.c
-@@ -909,7 +909,8 @@ static int remove_ddw(struct device_node
-       return 0;
- }
--static bool find_existing_ddw(struct device_node *pdn, u64 *dma_addr, int *window_shift)
-+static bool find_existing_ddw(struct device_node *pdn, u64 *dma_addr, int *window_shift,
-+                            bool *direct_mapping)
- {
-       struct dma_win *window;
-       const struct dynamic_dma_window_prop *dma64;
-@@ -922,6 +923,7 @@ static bool find_existing_ddw(struct dev
-                       dma64 = window->prop;
-                       *dma_addr = be64_to_cpu(dma64->dma_base);
-                       *window_shift = be32_to_cpu(dma64->window_shift);
-+                      *direct_mapping = window->direct;
-                       found = true;
-                       break;
-               }
-@@ -1275,10 +1277,8 @@ static bool enable_ddw(struct pci_dev *d
-       mutex_lock(&dma_win_init_mutex);
--      if (find_existing_ddw(pdn, &dev->dev.archdata.dma_offset, &len)) {
--              direct_mapping = (len >= max_ram_len);
-+      if (find_existing_ddw(pdn, &dev->dev.archdata.dma_offset, &len, &direct_mapping))
-               goto out_unlock;
--      }
-       /*
-        * If we already went through this for a previous function of
diff --git a/queue-6.1/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch b/queue-6.1/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
deleted file mode 100644 (file)
index becb86d..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-From 84bb41d5df48868055d159d9247b80927f1f70f9 Mon Sep 17 00:00:00 2001
-From: Heiko Carstens <hca@linux.ibm.com>
-Date: Tue, 24 Oct 2023 10:15:20 +0200
-Subject: s390/cmma: fix handling of swapper_pg_dir and invalid_pg_dir
-
-From: Heiko Carstens <hca@linux.ibm.com>
-
-commit 84bb41d5df48868055d159d9247b80927f1f70f9 upstream.
-
-If the cmma no-dat feature is available the kernel page tables are walked
-to identify and mark all pages which are used for address translation (all
-region, segment, and page tables). In a subsequent loop all other pages are
-marked as "no-dat" pages with the ESSA instruction.
-
-This information is visible to the hypervisor, so that the hypervisor can
-optimize purging of guest TLB entries. All pages used for swapper_pg_dir
-and invalid_pg_dir are incorrectly marked as no-dat, which in turn can
-result in incorrect guest TLB flushes.
-
-Fix this by marking those pages correctly as being used for DAT.
-
-Cc: <stable@vger.kernel.org>
-Reviewed-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
-Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
-Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/s390/mm/page-states.c |    6 ++++++
- 1 file changed, 6 insertions(+)
-
---- a/arch/s390/mm/page-states.c
-+++ b/arch/s390/mm/page-states.c
-@@ -192,6 +192,12 @@ void __init cmma_init_nodat(void)
-               return;
-       /* Mark pages used in kernel page tables */
-       mark_kernel_pgd();
-+      page = virt_to_page(&swapper_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-+      page = virt_to_page(&invalid_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-       /* Set all kernel pages not used for page tables to stable/no-dat */
-       for_each_mem_pfn_range(i, MAX_NUMNODES, &start, &end, NULL) {
index 7bee0e01b77c74523ca70dfb59c3278a43a902f8..cc1c1d551a1fda44ac60e61574c963969312aa3c 100644 (file)
@@ -243,10 +243,8 @@ i2c-core-run-atomic-i2c-xfer-when-preemptible.patch
 tracing-have-the-user-copy-of-synthetic-event-address-use-correct-context.patch
 driver-core-release-all-resources-during-unbind-before-updating-device-links.patch
 mcb-fix-error-handling-for-different-scenarios-when-parsing.patch
-powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch
 dmaengine-stm32-mdma-correct-desc-prep-when-channel-running.patch
 s390-cmma-fix-detection-of-dat-pages.patch
-s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
 mm-cma-use-nth_page-in-place-of-direct-struct-page-manipulation.patch
 mm-memory_hotplug-use-pfn-math-in-place-of-direct-struct-page-manipulation.patch
 mtd-cfi_cmdset_0001-byte-swap-otp-info.patch
diff --git a/queue-6.5/powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch b/queue-6.5/powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch
deleted file mode 100644 (file)
index b019731..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-From 3bf983e4e93ce8e6d69e9d63f52a66ec0856672e Mon Sep 17 00:00:00 2001
-From: Gaurav Batra <gbatra@linux.vnet.ibm.com>
-Date: Mon, 2 Oct 2023 22:08:02 -0500
-Subject: powerpc/pseries/iommu: enable_ddw incorrectly returns direct mapping for SR-IOV device
-
-From: Gaurav Batra <gbatra@linux.vnet.ibm.com>
-
-commit 3bf983e4e93ce8e6d69e9d63f52a66ec0856672e upstream.
-
-When a device is initialized, the driver invokes dma_supported() twice -
-first for streaming mappings followed by coherent mappings. For an
-SR-IOV device, default window is deleted and DDW created. With vPMEM
-enabled, TCE mappings are dynamically created for both vPMEM and SR-IOV
-device.  There are no direct mappings.
-
-First time when dma_supported() is called with 64 bit mask, DDW is created
-and marked as dynamic window. The second time dma_supported() is called,
-enable_ddw() finds existing window for the device and incorrectly returns
-it as "direct mapping".
-
-This only happens when size of DDW is big enough to map max LPAR memory.
-
-This results in streaming TCEs to not get dynamically mapped, since code
-incorrently assumes these are already pre-mapped. The adapter initially
-comes up but goes down due to EEH.
-
-Fixes: 381ceda88c4c ("powerpc/pseries/iommu: Make use of DDW for indirect mapping")
-Cc: stable@vger.kernel.org # v5.15+
-Signed-off-by: Gaurav Batra <gbatra@linux.vnet.ibm.com>
-Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
-Link: https://msgid.link/20231003030802.47914-1-gbatra@linux.vnet.ibm.com
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/powerpc/platforms/pseries/iommu.c |    8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
---- a/arch/powerpc/platforms/pseries/iommu.c
-+++ b/arch/powerpc/platforms/pseries/iommu.c
-@@ -916,7 +916,8 @@ static int remove_ddw(struct device_node
-       return 0;
- }
--static bool find_existing_ddw(struct device_node *pdn, u64 *dma_addr, int *window_shift)
-+static bool find_existing_ddw(struct device_node *pdn, u64 *dma_addr, int *window_shift,
-+                            bool *direct_mapping)
- {
-       struct dma_win *window;
-       const struct dynamic_dma_window_prop *dma64;
-@@ -929,6 +930,7 @@ static bool find_existing_ddw(struct dev
-                       dma64 = window->prop;
-                       *dma_addr = be64_to_cpu(dma64->dma_base);
-                       *window_shift = be32_to_cpu(dma64->window_shift);
-+                      *direct_mapping = window->direct;
-                       found = true;
-                       break;
-               }
-@@ -1272,10 +1274,8 @@ static bool enable_ddw(struct pci_dev *d
-       mutex_lock(&dma_win_init_mutex);
--      if (find_existing_ddw(pdn, &dev->dev.archdata.dma_offset, &len)) {
--              direct_mapping = (len >= max_ram_len);
-+      if (find_existing_ddw(pdn, &dev->dev.archdata.dma_offset, &len, &direct_mapping))
-               goto out_unlock;
--      }
-       /*
-        * If we already went through this for a previous function of
diff --git a/queue-6.5/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch b/queue-6.5/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
deleted file mode 100644 (file)
index 45794b1..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-From 84bb41d5df48868055d159d9247b80927f1f70f9 Mon Sep 17 00:00:00 2001
-From: Heiko Carstens <hca@linux.ibm.com>
-Date: Tue, 24 Oct 2023 10:15:20 +0200
-Subject: s390/cmma: fix handling of swapper_pg_dir and invalid_pg_dir
-
-From: Heiko Carstens <hca@linux.ibm.com>
-
-commit 84bb41d5df48868055d159d9247b80927f1f70f9 upstream.
-
-If the cmma no-dat feature is available the kernel page tables are walked
-to identify and mark all pages which are used for address translation (all
-region, segment, and page tables). In a subsequent loop all other pages are
-marked as "no-dat" pages with the ESSA instruction.
-
-This information is visible to the hypervisor, so that the hypervisor can
-optimize purging of guest TLB entries. All pages used for swapper_pg_dir
-and invalid_pg_dir are incorrectly marked as no-dat, which in turn can
-result in incorrect guest TLB flushes.
-
-Fix this by marking those pages correctly as being used for DAT.
-
-Cc: <stable@vger.kernel.org>
-Reviewed-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
-Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
-Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/s390/mm/page-states.c |    6 ++++++
- 1 file changed, 6 insertions(+)
-
---- a/arch/s390/mm/page-states.c
-+++ b/arch/s390/mm/page-states.c
-@@ -181,6 +181,12 @@ void __init cmma_init_nodat(void)
-               return;
-       /* Mark pages used in kernel page tables */
-       mark_kernel_pgd();
-+      page = virt_to_page(&swapper_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-+      page = virt_to_page(&invalid_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-       /* Set all kernel pages not used for page tables to stable/no-dat */
-       for_each_mem_pfn_range(i, MAX_NUMNODES, &start, &end, NULL) {
index 4b6fdf1b85a8ce66a0f88053c963bc7753bc0601..c5932e72e742991656daeec2a8e90fac5fdfe762 100644 (file)
@@ -340,11 +340,9 @@ selftests-clone3-fix-broken-test-under-config_time_ns.patch
 tracing-have-the-user-copy-of-synthetic-event-address-use-correct-context.patch
 driver-core-release-all-resources-during-unbind-before-updating-device-links.patch
 mcb-fix-error-handling-for-different-scenarios-when-parsing.patch
-powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch
 dmaengine-stm32-mdma-correct-desc-prep-when-channel-running.patch
 s390-mm-add-missing-arch_set_page_dat-call-to-vmem_crst_alloc.patch
 s390-cmma-fix-detection-of-dat-pages.patch
-s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
 mm-cma-use-nth_page-in-place-of-direct-struct-page-manipulation.patch
 mm-memory_hotplug-use-pfn-math-in-place-of-direct-struct-page-manipulation.patch
 mm-make-pr_mdwe_refuse_exec_gain-an-unsigned-long.patch
diff --git a/queue-6.6/powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch b/queue-6.6/powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch
deleted file mode 100644 (file)
index c1ba996..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-From 3bf983e4e93ce8e6d69e9d63f52a66ec0856672e Mon Sep 17 00:00:00 2001
-From: Gaurav Batra <gbatra@linux.vnet.ibm.com>
-Date: Mon, 2 Oct 2023 22:08:02 -0500
-Subject: powerpc/pseries/iommu: enable_ddw incorrectly returns direct mapping for SR-IOV device
-
-From: Gaurav Batra <gbatra@linux.vnet.ibm.com>
-
-commit 3bf983e4e93ce8e6d69e9d63f52a66ec0856672e upstream.
-
-When a device is initialized, the driver invokes dma_supported() twice -
-first for streaming mappings followed by coherent mappings. For an
-SR-IOV device, default window is deleted and DDW created. With vPMEM
-enabled, TCE mappings are dynamically created for both vPMEM and SR-IOV
-device.  There are no direct mappings.
-
-First time when dma_supported() is called with 64 bit mask, DDW is created
-and marked as dynamic window. The second time dma_supported() is called,
-enable_ddw() finds existing window for the device and incorrectly returns
-it as "direct mapping".
-
-This only happens when size of DDW is big enough to map max LPAR memory.
-
-This results in streaming TCEs to not get dynamically mapped, since code
-incorrently assumes these are already pre-mapped. The adapter initially
-comes up but goes down due to EEH.
-
-Fixes: 381ceda88c4c ("powerpc/pseries/iommu: Make use of DDW for indirect mapping")
-Cc: stable@vger.kernel.org # v5.15+
-Signed-off-by: Gaurav Batra <gbatra@linux.vnet.ibm.com>
-Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
-Link: https://msgid.link/20231003030802.47914-1-gbatra@linux.vnet.ibm.com
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/powerpc/platforms/pseries/iommu.c |    8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
---- a/arch/powerpc/platforms/pseries/iommu.c
-+++ b/arch/powerpc/platforms/pseries/iommu.c
-@@ -914,7 +914,8 @@ static int remove_ddw(struct device_node
-       return 0;
- }
--static bool find_existing_ddw(struct device_node *pdn, u64 *dma_addr, int *window_shift)
-+static bool find_existing_ddw(struct device_node *pdn, u64 *dma_addr, int *window_shift,
-+                            bool *direct_mapping)
- {
-       struct dma_win *window;
-       const struct dynamic_dma_window_prop *dma64;
-@@ -927,6 +928,7 @@ static bool find_existing_ddw(struct dev
-                       dma64 = window->prop;
-                       *dma_addr = be64_to_cpu(dma64->dma_base);
-                       *window_shift = be32_to_cpu(dma64->window_shift);
-+                      *direct_mapping = window->direct;
-                       found = true;
-                       break;
-               }
-@@ -1270,10 +1272,8 @@ static bool enable_ddw(struct pci_dev *d
-       mutex_lock(&dma_win_init_mutex);
--      if (find_existing_ddw(pdn, &dev->dev.archdata.dma_offset, &len)) {
--              direct_mapping = (len >= max_ram_len);
-+      if (find_existing_ddw(pdn, &dev->dev.archdata.dma_offset, &len, &direct_mapping))
-               goto out_unlock;
--      }
-       /*
-        * If we already went through this for a previous function of
diff --git a/queue-6.6/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch b/queue-6.6/s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
deleted file mode 100644 (file)
index 45794b1..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-From 84bb41d5df48868055d159d9247b80927f1f70f9 Mon Sep 17 00:00:00 2001
-From: Heiko Carstens <hca@linux.ibm.com>
-Date: Tue, 24 Oct 2023 10:15:20 +0200
-Subject: s390/cmma: fix handling of swapper_pg_dir and invalid_pg_dir
-
-From: Heiko Carstens <hca@linux.ibm.com>
-
-commit 84bb41d5df48868055d159d9247b80927f1f70f9 upstream.
-
-If the cmma no-dat feature is available the kernel page tables are walked
-to identify and mark all pages which are used for address translation (all
-region, segment, and page tables). In a subsequent loop all other pages are
-marked as "no-dat" pages with the ESSA instruction.
-
-This information is visible to the hypervisor, so that the hypervisor can
-optimize purging of guest TLB entries. All pages used for swapper_pg_dir
-and invalid_pg_dir are incorrectly marked as no-dat, which in turn can
-result in incorrect guest TLB flushes.
-
-Fix this by marking those pages correctly as being used for DAT.
-
-Cc: <stable@vger.kernel.org>
-Reviewed-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
-Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
-Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- arch/s390/mm/page-states.c |    6 ++++++
- 1 file changed, 6 insertions(+)
-
---- a/arch/s390/mm/page-states.c
-+++ b/arch/s390/mm/page-states.c
-@@ -181,6 +181,12 @@ void __init cmma_init_nodat(void)
-               return;
-       /* Mark pages used in kernel page tables */
-       mark_kernel_pgd();
-+      page = virt_to_page(&swapper_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-+      page = virt_to_page(&invalid_pg_dir);
-+      for (i = 0; i < 4; i++)
-+              set_bit(PG_arch_1, &page[i].flags);
-       /* Set all kernel pages not used for page tables to stable/no-dat */
-       for_each_mem_pfn_range(i, MAX_NUMNODES, &start, &end, NULL) {
index 12cd03282e9d5da357e24fb23d1e7ab0257b8231..6b64ee83199368836a9a6296805ff628c6da6890 100644 (file)
@@ -368,12 +368,10 @@ selftests-clone3-fix-broken-test-under-config_time_ns.patch
 tracing-have-the-user-copy-of-synthetic-event-address-use-correct-context.patch
 driver-core-release-all-resources-during-unbind-before-updating-device-links.patch
 mcb-fix-error-handling-for-different-scenarios-when-parsing.patch
-powerpc-pseries-iommu-enable_ddw-incorrectly-returns-direct-mapping-for-sr-iov-device.patch
 dmaengine-stm32-mdma-correct-desc-prep-when-channel-running.patch
 s390-mm-add-missing-arch_set_page_dat-call-to-vmem_crst_alloc.patch
 s390-mm-add-missing-arch_set_page_dat-call-to-gmap-allocations.patch
 s390-cmma-fix-detection-of-dat-pages.patch
-s390-cmma-fix-handling-of-swapper_pg_dir-and-invalid_pg_dir.patch
 mm-cma-use-nth_page-in-place-of-direct-struct-page-manipulation.patch
 mm-hugetlb-use-nth_page-in-place-of-direct-struct-page-manipulation.patch
 mm-memory_hotplug-use-pfn-math-in-place-of-direct-struct-page-manipulation.patch