]> git.baikalelectronics.ru Git - kernel.git/commit
arm64: mte: Tags-aware copy_{user_,}highpage() implementations
authorVincenzo Frascino <vincenzo.frascino@arm.com>
Tue, 6 Aug 2019 10:37:53 +0000 (11:37 +0100)
committerCatalin Marinas <catalin.marinas@arm.com>
Fri, 4 Sep 2020 11:46:06 +0000 (12:46 +0100)
commit2f0ae11123788ca0ec215e35eef6ec183bfd86c5
treee2ae176783c6a2d18fccf3e6927ec01289534ed8
parent070bcde54743c8db81727a9278410d0fb6026320
arm64: mte: Tags-aware copy_{user_,}highpage() implementations

When the Memory Tagging Extension is enabled, the tags need to be
preserved across page copy (e.g. for copy-on-write, page migration).

Introduce MTE-aware copy_{user_,}highpage() functions to copy tags to
the destination if the source page has the PG_mte_tagged flag set.
copy_user_page() does not need to handle tag copying since, with this
patch, it is only called by the DAX code where there is no source page
structure (and no source tags).

Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
Co-developed-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will@kernel.org>
arch/arm64/include/asm/mte.h
arch/arm64/include/asm/page.h
arch/arm64/lib/mte.S
arch/arm64/mm/copypage.c