alpha/mm: support __HAVE_ARCH_PTE_SWP_EXCLUSIVE
authorDavid Hildenbrand <david@redhat.com>
Fri, 13 Jan 2023 17:10:02 +0000 (18:10 +0100)
committerAndrew Morton <akpm@linux-foundation.org>
Fri, 3 Feb 2023 06:33:06 +0000 (22:33 -0800)
commita172d5128706028ac07b8db709728379ecc72f6e
tree7eb8fb408708ec3ab4afc9ce054abb2072e3bcf8
parent2321ba3e3733f513e46e29b9c70512ecddbf1085
alpha/mm: support __HAVE_ARCH_PTE_SWP_EXCLUSIVE

Let's support __HAVE_ARCH_PTE_SWP_EXCLUSIVE by stealing one bit from the
type.  Generic MM currently only uses 5 bits for the type
(MAX_SWAPFILES_SHIFT), so the stolen bit is effectively unused.

While at it, mask the type in mk_swap_pte() as well.

Link: https://lkml.kernel.org/r/20230113171026.582290-3-david@redhat.com
Signed-off-by: David Hildenbrand <david@redhat.com>
Cc: Richard Henderson <richard.henderson@linaro.org>
Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Cc: Matt Turner <mattst88@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/alpha/include/asm/pgtable.h