The patch titled Subject: arm64: move untagged_addr macro from uaccess.h to memory.h has been removed from the -mm tree. Its filename was arm64-move-untagged_addr-macro-from-uaccessh-to-memoryh.patch This patch was dropped because it was merged into mainline or a subsystem tree ------------------------------------------------------ From: Andrey Konovalov <andreyknvl@xxxxxxxxxx> Subject: arm64: move untagged_addr macro from uaccess.h to memory.h Move the untagged_addr() macro from arch/arm64/include/asm/uaccess.h to arch/arm64/include/asm/memory.h to be later reused by KASAN. Also make the untagged_addr() macro accept all kinds of address types (void *, unsigned long, etc.). This allows not to specify type casts in each place where the macro is used. This is done by using __typeof__. Link: http://lkml.kernel.org/r/2e9ef8d2ed594106eca514b268365b5419113f6a.1544099024.git.andreyknvl@xxxxxxxxxx Signed-off-by: Andrey Konovalov <andreyknvl@xxxxxxxxxx> Acked-by: Mark Rutland <mark.rutland@xxxxxxx> Acked-by: Will Deacon <will.deacon@xxxxxxx> Cc: Andrey Ryabinin <aryabinin@xxxxxxxxxxxxx> Cc: Christoph Lameter <cl@xxxxxxxxx> Cc: Dmitry Vyukov <dvyukov@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- --- a/arch/arm64/include/asm/memory.h~arm64-move-untagged_addr-macro-from-uaccessh-to-memoryh +++ a/arch/arm64/include/asm/memory.h @@ -219,6 +219,14 @@ extern u64 vabits_user; #define PHYS_PFN_OFFSET (PHYS_OFFSET >> PAGE_SHIFT) /* + * When dealing with data aborts, watchpoints, or instruction traps we may end + * up with a tagged userland pointer. Clear the tag to get a sane pointer to + * pass on to access_ok(), for instance. + */ +#define untagged_addr(addr) \ + ((__typeof__(addr))sign_extend64((u64)(addr), 55)) + +/* * Physical vs virtual RAM address space conversion. These are * private definitions which should NOT be used outside memory.h * files. Use virt_to_phys/phys_to_virt/__pa/__va instead. --- a/arch/arm64/include/asm/uaccess.h~arm64-move-untagged_addr-macro-from-uaccessh-to-memoryh +++ a/arch/arm64/include/asm/uaccess.h @@ -95,13 +95,6 @@ static inline unsigned long __range_ok(c return ret; } -/* - * When dealing with data aborts, watchpoints, or instruction traps we may end - * up with a tagged userland pointer. Clear the tag to get a sane pointer to - * pass on to access_ok(), for instance. - */ -#define untagged_addr(addr) sign_extend64(addr, 55) - #define access_ok(type, addr, size) __range_ok(addr, size) #define user_addr_max get_fs _ Patches currently in -mm which might be from andreyknvl@xxxxxxxxxx are