Message ID | f63094e20c1eb163ba3ae6f3531e791d2675a2a5.1525356769.git.andreyknvl@google.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.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 4FDAF603B4 for <patchwork-linux-arm@patchwork.kernel.org>; Thu, 3 May 2018 14:18:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3BDC128CC5 for <patchwork-linux-arm@patchwork.kernel.org>; Thu, 3 May 2018 14:18:33 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3049028E26; Thu, 3 May 2018 14:18:33 +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=-2.9 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, DKIM_VALID, MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id B673E28CC5 for <patchwork-linux-arm@patchwork.kernel.org>; Thu, 3 May 2018 14:18:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=DlRTXbAmCWSuMvYlchOf9mcnxXvcBepgLIB02dwUJ5A=; b=tYFgGvyjNvU0FOcX1CG99PgViE bcPlawTREIY1fxr0UifU8+nTMPtSjy3+jtj2l9oef8rbhryxnvwBb+fU23Z8N1/DpcHNCS6pFXXPR zG+sHnRY+EUFoqPRdruOewZHL7IQUAVbEgHKzPUWulwKSDlIyIpEjIa8qhwEBzndVdnYQXtZ066pI 0BMM1/DDRQaCCBocAlTSwCfjXXvTyJH+bIn/2n9KzPD2wZHiWaj2F3XTfw646WxLC5qRsuLShrF/5 jEojpvXE9lMasYMyigE631oQmra2P992Er/s1RbyOAcjQ3AR4Vmeb8YE+uXKFX4fnriBmjzacIzPJ MaX2wjhw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fEF3s-0004Yq-Vw; Thu, 03 May 2018 14:18:21 +0000 Received: from mail-wr0-x242.google.com ([2a00:1450:400c:c0c::242]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fEF1g-0003Uo-0h for linux-arm-kernel@lists.infradead.org; Thu, 03 May 2018 14:16:09 +0000 Received: by mail-wr0-x242.google.com with SMTP id i14-v6so14627958wre.2 for <linux-arm-kernel@lists.infradead.org>; Thu, 03 May 2018 07:15:53 -0700 (PDT) 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-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=wXNsOIULzRBowlkHlt/Dd2liRl3+STS0XzbkUxVElPM=; b=sSdiLHfCBxhTuSWUQLNp6IQZAUzuD5HKrdRVfrMLUmRccWVG/K5JjKdUTTPXXYpjtc kK/veIDwZ+oFvDXL/nCt+L5r0+AQQUSjwshkFI0fsIlvpZi9/wI0ucLIkazy5wXRxffH GxUgGaME2enr4euySDeNR1rGQdBRbhSIdqXcMDl7KRRpZA/Y4wbA+LhPMMkkeO58dR5m ii42M9O47GIGJ01ssiFrZ0bXNNvAShAsGxZZw/8BIk+HK2SVNzbS1Yz9527/LvnzMwR2 txwkRf4uuI7poAbmCQpvDUyKiuQKyO3HUJFR7RrSG6kKkpWgr9Qpqx5eX1ajYfaz/ExG CjbA== X-Gm-Message-State: ALQs6tCCAfvVEaShHU8nQffLj18Zdgou8kKKCrJSrurXqs4XXJChsA8s 0wJTmyNeS/GT+e2c/YijKHv6ZA== 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 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-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180503_071604_076241_89531277 X-CRM114-Status: GOOD ( 14.68 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: <linux-arm-kernel.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-arm-kernel/> List-Post: <mailto:linux-arm-kernel@lists.infradead.org> List-Help: <mailto:linux-arm-kernel-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=subscribe> Cc: Chintan Pandya <cpandya@codeaurora.org>, Jacob Bramley <Jacob.Bramley@arm.com>, Ruben Ayrapetyan <Ruben.Ayrapetyan@arm.com>, Lee Smith <Lee.Smith@arm.com>, Kostya Serebryany <kcc@google.com>, Dmitry Vyukov <dvyukov@google.com>, Ramana Radhakrishnan <Ramana.Radhakrishnan@arm.com>, Evgeniy Stepanov <eugenis@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org> Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.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(+)