From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-12.9 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, MENTIONS_GIT_HOSTING,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id EBB0FC4727D for ; Fri, 25 Sep 2020 16:09:24 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 60B0023772 for ; Fri, 25 Sep 2020 16:09:24 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="Eul1t4DJ" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 60B0023772 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:MIME-Version:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id: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:In-Reply-To:References:List-Owner; bh=eIEq5U2FvHN3ZxFd7cA/5wuNxBLzdzU2q9xBmOUYw8k=; b=Eul1t4DJF+aY6HmGrYFhvm8bPQ vlAW/j5PZySWN4PGBZ0n5jnMhfJ5xDVgPN2mJJO10yLqDAVQNh2tFvXYksRp0+lX6NmBnbXoaFx5P vqwq1sJvrVaWHfm5R4t9Y/2sXT7ACYqP8vjqCPX9KNv2aRDQpwLjBdq9mq0AJaWYCmDypSTbWbs3m 7NOAH5mi2aIX3HeV1TQ1P2cjAcrhrGLu+TigQbwkgjaqeAU/bcorBTaUFwDAllpkIj2uY3rX64/aC aByKSqoXNkMCYbog9xE/uuX3qR2tO4/XB+nh+kfkF+hjP5kTH5eLjkArjBn/a6/EQ86G1HffxCKvq g9W9rW4A==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kLqFx-0006H7-D1; Fri, 25 Sep 2020 16:07:33 +0000 Received: from foss.arm.com ([217.140.110.172]) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kLqFu-0006GM-HC for linux-arm-kernel@lists.infradead.org; Fri, 25 Sep 2020 16:07:31 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 0A01A101E; Fri, 25 Sep 2020 09:07:29 -0700 (PDT) Received: from lakrids.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 05D803F718; Fri, 25 Sep 2020 09:07:27 -0700 (PDT) From: Mark Rutland To: linux-arm-kernel@lists.infradead.org Subject: [PATCH 00/13] arm64: remove set_fs() and friends Date: Fri, 25 Sep 2020 17:07:09 +0100 Message-Id: <20200925160722.27155-1-mark.rutland@arm.com> X-Mailer: git-send-email 2.11.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200925_120730_616063_F9E9AF83 X-CRM114-Status: GOOD ( 12.38 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: mark.rutland@arm.com, catalin.marinas@arm.com, robin.murphy@arm.com, james.morse@arm.com, will@kernel.org, hch@lst.de MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org This series removes set_fs() from arm64, building atop the core rework done by Christophe. The series can be found in my arm64/set_fs-removal branch [2]. The bulk of the rework is to address the way we manipulate PAN and UAO, which is largely rendered redundant. The kernel maccess routines (__{get,put}_kernel_nofault) are trivial wrappers which share code with the uaccess routines, so I expect these should just work, but they'll need testing in-context, especially where they're wrapped by the gerneric copy routines. So far this has seen some very basic boot testing. I intend to throw Syzkaller and LTP at this soon. Mark. [1] git://git.infradead.org/users/hch/misc.git set_fs-removal [2] git://git.kernel.org/pub/scm/linux/kernel/git/mark/linux.git arm64/set_fs-removal Mark Rutland (13): arm64: head.S: rename el2_setup -> init_kernel_el arm64: head.S: cleanup SCTLR_ELx initialization arm64: head.S: always initialize PSTATE arm64: sdei: move uaccess logic to arch/arm64/ arm64: uaccess: move uao_* alternatives to asm-uaccess.h arm64: uaccess: rename privileged uaccess routines arm64: uaccess: simplify __copy_user_flushcache() arm64: uaccess: refactor __{get,put}_user arm64: uaccess: split user/kernel routines arm64: uaccess cleanup macro naming arm64: uaccess: remove set_fs() arm64: uaccess: remove addr_limit_user_check() arm64: uaccess: remove redundant PAN toggling arch/arm64/Kconfig | 1 - arch/arm64/include/asm/alternative.h | 59 ------------ arch/arm64/include/asm/asm-uaccess.h | 29 ++++++ arch/arm64/include/asm/cpucaps.h | 1 - arch/arm64/include/asm/exec.h | 1 - arch/arm64/include/asm/futex.h | 8 +- arch/arm64/include/asm/processor.h | 4 +- arch/arm64/include/asm/ptrace.h | 8 +- arch/arm64/include/asm/sysreg.h | 16 +++- arch/arm64/include/asm/thread_info.h | 8 +- arch/arm64/include/asm/uaccess.h | 180 ++++++++++++++--------------------- arch/arm64/kernel/armv8_deprecated.c | 4 +- arch/arm64/kernel/asm-offsets.c | 3 +- arch/arm64/kernel/cpufeature.c | 11 --- arch/arm64/kernel/entry.S | 19 +--- arch/arm64/kernel/head.S | 46 +++++---- arch/arm64/kernel/process.c | 12 --- arch/arm64/kernel/sdei.c | 12 +-- arch/arm64/kernel/signal.c | 3 - arch/arm64/kernel/sleep.S | 2 +- arch/arm64/kernel/suspend.c | 3 +- arch/arm64/lib/clear_user.S | 8 +- arch/arm64/lib/copy_from_user.S | 8 +- arch/arm64/lib/copy_in_user.S | 16 ++-- arch/arm64/lib/copy_to_user.S | 8 +- arch/arm64/lib/uaccess_flushcache.c | 4 +- arch/arm64/mm/fault.c | 5 - arch/arm64/mm/proc.S | 2 +- drivers/firmware/arm_sdei.c | 14 --- 29 files changed, 189 insertions(+), 306 deletions(-) -- 2.11.0 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel