]> git.baikalelectronics.ru Git - kernel.git/commit
arm64: uaccess: simplify __copy_user_flushcache()
authorMark Rutland <mark.rutland@arm.com>
Wed, 2 Dec 2020 13:15:51 +0000 (13:15 +0000)
committerCatalin Marinas <catalin.marinas@arm.com>
Wed, 2 Dec 2020 19:49:10 +0000 (19:49 +0000)
commit38c61af6db577e3b657b2ef854420cfc4384ccab
treec76d94f31c9d8c5926c32b22f41ad471903b8ee8
parentb962e3996a03a2c5d33c7e1cad659de148ebaae6
arm64: uaccess: simplify __copy_user_flushcache()

Currently __copy_user_flushcache() open-codes raw_copy_from_user(), and
doesn't use uaccess_mask_ptr() on the user address. Let's have it call
raw_copy_from_user(), which is both a simplification and ensures that
user pointers are masked under speculation.

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Reviewed-by: Robin Murphy <robin.murphy@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-6-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/lib/uaccess_flushcache.c