All of lore.kernel.org
 help / color / mirror / Atom feed
* [merged mm-stable] arm-mm-fix-swp-type-masking-in-__swp_entry.patch removed from -mm tree
@ 2023-02-10  0:52 Andrew Morton
  0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2023-02-10  0:52 UTC (permalink / raw)
  To: mm-commits, rmk+kernel, broonie, david, akpm


The quilt patch titled
     Subject: arm/mm: fix swp type masking in __swp_entry()
has been removed from the -mm tree.  Its filename was
     arm-mm-fix-swp-type-masking-in-__swp_entry.patch

This patch was dropped because it was merged into the mm-stable branch
of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: David Hildenbrand <david@redhat.com>
Subject: arm/mm: fix swp type masking in __swp_entry()
Date: Wed, 8 Feb 2023 15:08:01 +0100

We're masking with the number of type bits instead of the type mask, which
is obviously wrong.

Link: https://lkml.kernel.org/r/39fd91e3-c93b-23c6-afc6-cbe473bb0ca9@redhat.com
Fixes: 20aae9eff5ac ("arm/mm: support __HAVE_ARCH_PTE_SWP_EXCLUSIVE")
Signed-off-by: David Hildenbrand <david@redhat.com>
Reported-by: Mark Brown <broonie@kernel.org>
Tested-by: Mark Brown <broonie@kernel.org>
Cc: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 arch/arm/include/asm/pgtable.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/arch/arm/include/asm/pgtable.h~arm-mm-fix-swp-type-masking-in-__swp_entry
+++ a/arch/arm/include/asm/pgtable.h
@@ -292,7 +292,7 @@ static inline pte_t pte_modify(pte_t pte
 
 #define __swp_type(x)		(((x).val >> __SWP_TYPE_SHIFT) & __SWP_TYPE_MASK)
 #define __swp_offset(x)		((x).val >> __SWP_OFFSET_SHIFT)
-#define __swp_entry(type, offset) ((swp_entry_t) { (((type) & __SWP_TYPE_BITS) << __SWP_TYPE_SHIFT) | \
+#define __swp_entry(type, offset) ((swp_entry_t) { (((type) & __SWP_TYPE_MASK) << __SWP_TYPE_SHIFT) | \
 						   ((offset) << __SWP_OFFSET_SHIFT) })
 
 #define __pte_to_swp_entry(pte)	((swp_entry_t) { pte_val(pte) })
_

Patches currently in -mm which might be from david@redhat.com are



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-02-10  0:52 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-10  0:52 [merged mm-stable] arm-mm-fix-swp-type-masking-in-__swp_entry.patch removed from -mm tree Andrew Morton

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.