Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp616232img; Mon, 18 Mar 2019 10:19:05 -0700 (PDT) X-Google-Smtp-Source: APXvYqw6jUk39jVnxAiHA1dZOIv7/lHfOE0hX3ZVlBtSe/9nnOOmmhL3YIBJrlgCPhEuDKoskm5r X-Received: by 2002:a65:41ca:: with SMTP id b10mr18677821pgq.146.1552929544891; Mon, 18 Mar 2019 10:19:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1552929544; cv=none; d=google.com; s=arc-20160816; b=q7XneFWcSy4aFCGfzUvqXR6CDJ1CKbh+VWbKVo8H4oe5p/m2RjzJnswAvAJeRQSMcp pWmNlBSra7GMxuh02jhTxSNaY5u6Z+Gpyks1OJ5vZeGBCuwpxNmou3RWQwsM6ZNWzE7+ FWtYsVm7wbZ2G/VgnzfITjSX7Z7JjtVj1j/L5s+w+pOuS3cpS55r9nUOtUN/AIfG5qY7 sgRKAHtngb2/LEQbU7mKfWUnfWO8+LA1/eHTHGtCWLxagU2Elr5Dq3jS1V4c4BcaKehb WDENEJfP3AJ63aVviQvr7jYZvRkANhrvfVM3JS8IQhTKqyHOvtgMJqa2ElD7L3DUaVoo WurA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:from:subject:references :mime-version:message-id:in-reply-to:date:dkim-signature; bh=20ADMBvUHCnrZbwN97RAJ/EQy38heFRI/sJcSeCbm08=; b=OKTiXZtLQBeZ4wGTvJERwpWynwQbP3AjKK2++Ml1FbGvrn5zjp9AwdBAS34gt9bWuY +bD1BRc7OP4525qy0Kr/JVAIhJNf8xINpkG3txJaK9+FDup1TKv8XWuv7xHyqobay1JR Vx8sQpz6mTx70ohNxqLPis+SAbOsUqWYDz7avr3KQCCKdw2LT8H0+4LZYX/sgPglt+Jw ayvorFLyUYacgzCB9+Up91jwNdASJU3lw2PaV38LYEo5zyjlpN01b/2GX0EPD86kUNj0 44qo+0Kp6Zqnk7nHi72EwT6qMbkAhmwR9mPedFYnlbdnsguX4mTt0s9Y7WnYoUTUfO/D uWKw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=ZCnCpHap; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m1si525437pgn.590.2019.03.18.10.18.49; Mon, 18 Mar 2019 10:19:04 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=ZCnCpHap; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727791AbfCRRR5 (ORCPT + 99 others); Mon, 18 Mar 2019 13:17:57 -0400 Received: from mail-it1-f201.google.com ([209.85.166.201]:55768 "EHLO mail-it1-f201.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727704AbfCRRRx (ORCPT ); Mon, 18 Mar 2019 13:17:53 -0400 Received: by mail-it1-f201.google.com with SMTP id y6so12672977itj.5 for ; Mon, 18 Mar 2019 10:17:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:in-reply-to:message-id:mime-version:references:subject:from:to :cc; bh=20ADMBvUHCnrZbwN97RAJ/EQy38heFRI/sJcSeCbm08=; b=ZCnCpHapZTf/qLS1N3vuiLVDpuei/65u8OAdfxmbj9C6UycfT7l0asJ7ukPP0vA4Qi HwZtqNnAkTEZNxdFQ6ErXg2Ws9tH+1NRLw2LH+z6sEsmpFcEdBiI9Wc+uKPOo3gmlZBe qurf9ufUqK/sY8KXNWAv2He9kNybaZ4j8MY9rM8iGvsQzRNy7m2xQuCJRiBD6UV/MuZG ZknYNqa6eOMfTCYDnGvBMcFPTyz86UhzqH2sZgKXS34VV/J9Ek9ZWHRf9Zq9g9xbx/V/ tDLUy208+7acHrCH16I/7nTUTuPpcoiSwjw+gJftawG7U+l13wzbQ4qY22WWvgzkuT8P l0fg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=20ADMBvUHCnrZbwN97RAJ/EQy38heFRI/sJcSeCbm08=; b=RXwAmRhBUCxGkIsLQvyLKmvOjCeBQYwWrU5wkB8Q7wg0mh8aFJ/5Bmrv1PLi4a/SeT KT0dYRL4D1r/K1UbFcHFb/uq6JxKbiln1GIDaN/KJ0G3FKJA1rU6VSfT4Hn/YSX51zIJ LovdpwaVNA5PUwse+kv/Y4nw5KdFrBl39jQ9iUl6LlrJFXChaN+HkEgIEhc7RLNmpC9G CIE8Wyj+2fmM75j/G8Zo1dA+XUJouXlYgiKchkhPrIGr2rNkY6I0SEZL+1Wh6NJ5ztbM EubRf6pB7czTuB59USvIo8ruIskxQWuCBXnuHs+CpyttbOalHkkIuTbAdXXr5aiP7KfX BxLA== X-Gm-Message-State: APjAAAWhwcmt1RdM6wHQ6kSw230UhegX3NRhkSb0NyEw2O/xKwd4l3rD L71KrZZPD7roDQF05HnO4xBgzLsOKnF4upFw X-Received: by 2002:a24:4503:: with SMTP id y3mr10296221ita.32.1552929472134; Mon, 18 Mar 2019 10:17:52 -0700 (PDT) Date: Mon, 18 Mar 2019 18:17:33 +0100 In-Reply-To: Message-Id: Mime-Version: 1.0 References: X-Mailer: git-send-email 2.21.0.225.g810b269d1ac-goog Subject: [PATCH v12 01/13] uaccess: add untagged_addr definition for other arches From: Andrey Konovalov To: Catalin Marinas , Will Deacon , Mark Rutland , Robin Murphy , Kees Cook , Kate Stewart , Greg Kroah-Hartman , Andrew Morton , Ingo Molnar , "Kirill A . Shutemov" , Shuah Khan , Vincenzo Frascino , Eric Dumazet , "David S. Miller" , Alexei Starovoitov , Daniel Borkmann , Steven Rostedt , Ingo Molnar , Peter Zijlstra , Arnaldo Carvalho de Melo , linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org, linux-mm@kvack.org, linux-arch@vger.kernel.org, netdev@vger.kernel.org, bpf@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Dmitry Vyukov , Kostya Serebryany , Evgeniy Stepanov , Lee Smith , Ramana Radhakrishnan , Jacob Bramley , Ruben Ayrapetyan , Chintan Pandya , Luc Van Oostenryck , Dave Martin , Kevin Brodsky , Szabolcs Nagy , Andrey Konovalov Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org To allow arm64 syscalls to accept tagged pointers from userspace, we must untag them when they are passed to the kernel. Since untagging is done in generic parts of the kernel, the untagged_addr macro needs to be defined for all architectures. Define it as a noop for architectures other than arm64. Acked-by: Catalin Marinas Signed-off-by: Andrey Konovalov --- include/linux/mm.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/linux/mm.h b/include/linux/mm.h index 76769749b5a5..4d674518d392 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -99,6 +99,10 @@ extern int mmap_rnd_compat_bits __read_mostly; #include #include +#ifndef untagged_addr +#define untagged_addr(addr) (addr) +#endif + #ifndef __pa_symbol #define __pa_symbol(x) __pa(RELOC_HIDE((unsigned long)(x), 0)) #endif -- 2.21.0.225.g810b269d1ac-goog