Message ID | f63094e20c1eb163ba3ae6f3531e791d2675a2a5.1525356769.git.andreyknvl@google.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 5392F60353 for <patchwork-linux-mm@patchwork.kernel.org>; Thu, 3 May 2018 14:15:59 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4017628EC4 for <patchwork-linux-mm@patchwork.kernel.org>; Thu, 3 May 2018 14:15:59 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 33F7D2904B; Thu, 3 May 2018 14:15:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.5 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE, USER_IN_DEF_DKIM_WL autolearn=ham version=3.3.1 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 11C3228EC4 for <patchwork-linux-mm@patchwork.kernel.org>; Thu, 3 May 2018 14:15:58 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 3F6C16B000E; Thu, 3 May 2018 10:15:54 -0400 (EDT) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 3585C6B0010; Thu, 3 May 2018 10:15:54 -0400 (EDT) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 1F97E6B0011; Thu, 3 May 2018 10:15:54 -0400 (EDT) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-wm0-f72.google.com (mail-wm0-f72.google.com [74.125.82.72]) by kanga.kvack.org (Postfix) with ESMTP id B63806B000E for <linux-mm@kvack.org>; Thu, 3 May 2018 10:15:53 -0400 (EDT) Received: by mail-wm0-f72.google.com with SMTP id v2so5688432wmc.0 for <linux-mm@kvack.org>; Thu, 03 May 2018 07:15:53 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:dkim-signature:from:to:cc:subject:date :message-id:in-reply-to:references:in-reply-to:references; bh=wXNsOIULzRBowlkHlt/Dd2liRl3+STS0XzbkUxVElPM=; b=iQbZoCSFKKlqGq00HOH3Tri63VDJ7qyHF4UsyOGhwXLweTwW/q8fH+Zlcj1KMxYjxn ZL7/5hSnIHNOpd6NXa+YuX/fpDH+MZaK9vBYcKnsFHqNhFBom93+ssPHWwjHoPpWLfny DvlFhuxz1FDf/bEkmPOs1qX64ZzEIecWMRRzvK1XKcSwz0JD10FGESQoABgi+p1Y9BL/ k1Sh+UxiBIyQNSC5usg4cVvUQ38jyLLBKkqGgy/h7RBmtfPqJEBdCNaFbk/cj8fSkUw+ CjAd/76Ae0cAJ1w6CpY4rP31wS+4wwjKekYro083GWemNMWAYws/LIB3qw9/wRCMbbOr tocg== X-Gm-Message-State: ALQs6tBGTSoNMfPYxmWlxhcZ3vhJ/Rul//VLXDpAIh0Y1QVtjKTMh1kF Kc4vnREWzsil+kYs/UnAJ3XJwG35uXLddm0406EDeJFHjOCJO4tlhVhTxv78KQvC8riB+LFRntB PWuAv7ob0rSE7zipSdP3hyHpafPd0tIrjFe3PTY7bhCQaUhW/r1febeBKwPfu3yYQ4+prbafbJe u3vz542CCDOXZ3R8BHvlqaP5deyxEXbvnlf4IJKPPTDr5FxyiQfUiKFYHagjrvLx0IRctGklmjm a4kDF2CxrXsGZptd4jrOebnSNcJc1hf/4GSm98hxTdgqafQL8bthQ7JcPTVoyqtXmOeSVDtxwde dJuzGs+z0bw43lV3w46i37IgqpOqEyOGhP+dtrnZs98yt8xiqcEZ8aBfjetGlUfQMJBdRSNPyzG a X-Received: by 2002:adf:9658:: with SMTP id c24-v6mr17009274wra.190.1525356953286; Thu, 03 May 2018 07:15:53 -0700 (PDT) X-Received: by 2002:adf:9658:: with SMTP id c24-v6mr17009242wra.190.1525356952584; Thu, 03 May 2018 07:15:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525356952; cv=none; d=google.com; s=arc-20160816; b=Yfu8tCUpyS5cqGnkqSgEJk6SKkVtbsWxCroCrb0iW4WftxJe5Cor5AX5kbMV5g42pg ITeeSOxondRRCoXqL2gXDc74/E69+iOQtiqBMbW/XOJVpXoOeQ/IXMi1JerU0Lq43dlc WOUBQL/X+8MBchfQT/3FM/0MpU3krIC+2Mor0HKMNV9imLYXOQZTPr13820tZbneNgdK qveUj/GxvZWovzCEIkwjqdDNNVfH8Mt+zxZRUZbH5NUwPRKPuli8mOhOidwtZssEnSul PUIpBJq+qGFZTsZQ4wvJmlbNqesVenDS+q1PRniLjdwu1OPxXiZGDeFE/SNCtE3DYL2c 589Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=references:in-reply-to:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=wXNsOIULzRBowlkHlt/Dd2liRl3+STS0XzbkUxVElPM=; b=RJEptCgB8I8CpKJUixW7FDwz9jWQzgytK6TKBW5X3xXaCvxz9eDHeKki0XurScTA3r jAUwdALQ+pZRW8QcUud4hU7PSJLnASiETSS0lTiRM2LxOoL3nH54xUv+iDaoOie2NDZQ 77xYp3xdV+dzqPkzqy9BR+kNMs4cEd24sqlnH3FVMOkcv1YsiFDxr0Fl3Mg1DKtvhTeO MREGn9eLcftApqT3xVXc9xSDYp6pGt9OLzBpcfxID1sZGo1cx/aJxUvP5IKoEiToW5nO OyatRg/haQucrcSE6hySvAwAxfs1QrINsKJWpPQNeaWdN0YFPXkfsO8RpINLZO/u8nve EGnQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=cKfcqw7O; spf=pass (google.com: domain of andreyknvl@google.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=andreyknvl@google.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id p14-v6sor6198432wrc.56.2018.05.03.07.15.52 for <linux-mm@kvack.org> (Google Transport Security); Thu, 03 May 2018 07:15:52 -0700 (PDT) Received-SPF: pass (google.com: domain of andreyknvl@google.com designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=cKfcqw7O; spf=pass (google.com: domain of andreyknvl@google.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=andreyknvl@google.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=wXNsOIULzRBowlkHlt/Dd2liRl3+STS0XzbkUxVElPM=; b=cKfcqw7OehAu6sY0jYTYgvFAKeiqX4rmTWXzo9tmakVGK40VkXlaUnz5a8Z53Qhu2Q Gh5OtrObUQocBRBjVI7Z8CoDIEvKdeK59I7DkrR5c8m6ydG9Mcj/Qqx5oqQXJOg8yMDu bds1ptMh30yiHgIO/cUBougBwYQWYkjGIhddP3NjGd18fWY/2D7Mrwl+xRSdwVP6CraB WCXbL3g9DTSGN6lWa6DjJ6eHwYFEacCD+fEIlxrlLuXwrB9YpgusfvWSnaCfAVUj7A4u 1D+X9jceL+7Yvnrel8cBHdZMrEF2UJ/uN4ZiIIItgFjD/PpbHKTpqpSzek/YQsl4a00B WOsA== X-Google-Smtp-Source: AB8JxZoPsEixtvtPtjFL5/kf9+eJmruA8lLTNPHuSDxpygbMTUZneSzwIrOUpIYddWNTRGnTIGl+ig== X-Received: by 2002:adf:ec41:: with SMTP id w1-v6mr19831174wrn.211.1525356952020; Thu, 03 May 2018 07:15:52 -0700 (PDT) Received: from andreyknvl0.muc.corp.google.com ([2a00:79e0:15:10:84be:a42a:826d:c530]) by smtp.gmail.com with ESMTPSA id u20-v6sm22090298wru.33.2018.05.03.07.15.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 03 May 2018 07:15:51 -0700 (PDT) From: Andrey Konovalov <andreyknvl@google.com> To: Catalin Marinas <catalin.marinas@arm.com>, Will Deacon <will.deacon@arm.com>, Jonathan Corbet <corbet@lwn.net>, Mark Rutland <mark.rutland@arm.com>, Robin Murphy <robin.murphy@arm.com>, Al Viro <viro@zeniv.linux.org.uk>, Andrey Konovalov <andreyknvl@google.com>, James Morse <james.morse@arm.com>, Kees Cook <keescook@chromium.org>, Bart Van Assche <bart.vanassche@wdc.com>, Kate Stewart <kstewart@linuxfoundation.org>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Thomas Gleixner <tglx@linutronix.de>, Philippe Ombredanne <pombredanne@nexb.com>, Andrew Morton <akpm@linux-foundation.org>, Ingo Molnar <mingo@kernel.org>, "Kirill A . Shutemov" <kirill.shutemov@linux.intel.com>, Dan Williams <dan.j.williams@intel.com>, "Aneesh Kumar K . V" <aneesh.kumar@linux.vnet.ibm.com>, Zi Yan <zi.yan@cs.rutgers.edu>, linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org Cc: Dmitry Vyukov <dvyukov@google.com>, Kostya Serebryany <kcc@google.com>, Evgeniy Stepanov <eugenis@google.com>, Lee Smith <Lee.Smith@arm.com>, Ramana Radhakrishnan <Ramana.Radhakrishnan@arm.com>, Jacob Bramley <Jacob.Bramley@arm.com>, Ruben Ayrapetyan <Ruben.Ayrapetyan@arm.com>, Chintan Pandya <cpandya@codeaurora.org> Subject: [PATCH v2 2/6] uaccess: add untagged_addr definition for other arches Date: Thu, 3 May 2018 16:15:40 +0200 Message-Id: <f63094e20c1eb163ba3ae6f3531e791d2675a2a5.1525356769.git.andreyknvl@google.com> X-Mailer: git-send-email 2.17.0.441.gb46fe60e1d-goog In-Reply-To: <cover.1525356769.git.andreyknvl@google.com> References: <cover.1525356769.git.andreyknvl@google.com> In-Reply-To: <cover.1525356769.git.andreyknvl@google.com> References: <cover.1525356769.git.andreyknvl@google.com> X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/include/linux/uaccess.h b/include/linux/uaccess.h index efe79c1cdd47..c045b4eff95e 100644 --- a/include/linux/uaccess.h +++ b/include/linux/uaccess.h @@ -13,6 +13,10 @@ #include <asm/uaccess.h> +#ifndef untagged_addr +#define untagged_addr(addr) addr +#endif + /* * Architectures should provide two primitives (raw_copy_{to,from}_user()) * and get rid of their private instances of copy_{to,from}_user() and
To allow arm64 syscalls 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 (like the mm subsystem), the untagged_addr macro should be defined for all architectures. Define it as a noop for other architectures besides arm64. Signed-off-by: Andrey Konovalov <andreyknvl@google.com> --- include/linux/uaccess.h | 4 ++++ 1 file changed, 4 insertions(+)