]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
fix up queue-6.1/mm-gup-handle-cont-pte-hugetlb-pages-correctly-in-gup_must_unshare...
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 27 Aug 2023 06:32:05 +0000 (08:32 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 27 Aug 2023 06:32:05 +0000 (08:32 +0200)
queue-6.1/mm-gup-handle-cont-pte-hugetlb-pages-correctly-in-gup_must_unshare-via-gup-fast.patch

index 5380d22408f58d4715415d6b9d4c41f2c06fc662..857391530c53dee9e9bb13916c5e7a912ae68047 100644 (file)
@@ -125,13 +125,13 @@ Cc: <stable@vger.kernel.org>
 Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
mm/internal.h |   10 ++++++++++
include/linux/mm.h |   10 ++++++++++
  1 file changed, 10 insertions(+)
 
---- a/mm/internal.h
-+++ b/mm/internal.h
-@@ -850,6 +850,16 @@ static inline bool vma_soft_dirty_enable
-               return false;
+--- a/include/linux/mm.h
++++ b/include/linux/mm.h
+@@ -3092,6 +3092,16 @@ static inline bool gup_must_unshare(unsi
+               smp_rmb();
  
        /*
 +       * During GUP-fast we might not get called on the head page for a
@@ -144,6 +144,6 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 +              page = compound_head(page);
 +
 +      /*
-        * Soft-dirty is kind of special: its tracking is enabled when the
-        * vma flags not set.
+        * Note that PageKsm() pages cannot be exclusive, and consequently,
+        * cannot get pinned.
         */