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 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id BC0FAC433F5 for ; Mon, 27 Sep 2021 15:06:50 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 8486760FF2 for ; Mon, 27 Sep 2021 15:06:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 8486760FF2 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :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=WV0tFI27/Vz6QkrOHmJwORuYw2rlqggGt/tN5zIVI/c=; b=gdLiH8uxjVOoyX stsmt4H4zNnMwPZwZPuxR70UDS1eGXJWe9vtljq6hI64Jo7wQGu6meiStudiJoHVT3wUXolhqoGEt HQZM9fll4Xjx0PpxilefWC5yL/Sf93asAMyDyhqk1Cmj3SIa5kw9c6y9Db3IPSBEqU3PZwI3L/SqW bQcYN9GNqQqARHwh8Dft8M1ch4FvEkD7STV8VKQTvG8AlvKrU46wfZIAOzEIBrjmx1Rm6qVDY0zjk MLOblk7hi5p0q21HZeCC+6SfHp7P6kAnQ81WNbj4pfLSwLujXC4NJ9nLJmtarNdJH9biOPUegJEMz ds6w4KtH989zkzC4IAtA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mUsBZ-00319x-Es; Mon, 27 Sep 2021 15:04:53 +0000 Received: from mail.kernel.org ([198.145.29.99]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mUsBV-003199-D0 for linux-arm-kernel@lists.infradead.org; Mon, 27 Sep 2021 15:04:50 +0000 Received: by mail.kernel.org (Postfix) with ESMTPSA id 6801E60FF2; Mon, 27 Sep 2021 15:04:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1632755089; bh=8huCXlGV2MjXjiaHsVT9c4Jyelh4N9YfjHJleIaEAPo=; h=From:To:Cc:Subject:Date:From; b=XlurzwPAuEqFCw3cJQhIZ6IdTEpAanD/6etqOk2FioA+gr/PJQXPNG/SbcGeTjzva TiYsKZixqKFl32TmwUQ2XDYkzxO9Yjf6y9p8W6JSs34bxIILHxOMSyH9htlcDO8wfJ /ouMaLwhv/fY9l4E1QFoQJgEJxtQAzqK5DWnC4oK8/0Ep3QBWbZm4vHECBOKDTD+Qk BstFDJOn+6WW+dZzBiGBKh8sFxkJXKZQqgeCORsXnwU9fz+DUPZuX5UvSmy/Rj9RNO znFXXtm8D5YF004Xa9M604rF4d96icqw3fNsgEhhaAwbXQc3z+HKQAQkdR6HsfPIiI 3uI8gBBF9JzTQ== From: Ard Biesheuvel To: linux-arm-kernel@lists.infradead.org, linux+pull@armlinux.org.uk Cc: Keith Packard , Kees Cook , Arnd Bergmann , Amit Daniel Kachhap , Linus Walleij Subject: [GIT PULL] ARM: support THREAD_INFO_IN_TASK Date: Mon, 27 Sep 2021 17:04:43 +0200 Message-Id: <20210927150443.2654851-1-ardb@kernel.org> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210927_080449_493959_736C92B0 X-CRM114-Status: GOOD ( 14.47 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , 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 The following changes since commit 6880fa6c56601bb8ed59df6c30fd390cc5f6dd8f: Linux 5.15-rc1 (2021-09-12 16:28:37 -0700) are available in the Git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/ardb/linux.git tags/pr-arm32-ti-in-task for you to fetch changes up to 18ed1c01a7dd3d7c780b06a49124da237a4c1790: ARM: smp: Enable THREAD_INFO_IN_TASK (2021-09-27 16:54:02 +0200) ---------------------------------------------------------------- ARM: support THREAD_INFO_IN_TASK Move thread_info off the stack and into the task struct, as is done by many other architectures. This requires a method to find the task struct of the task currently running on the CPU, which is provided in this case by the user space TLS (Thread Local Storage) register. This implies that the feature is only supported on CPUs that implement this register, i.e., ARM v6k or later. Kindly tested by Amit and reviewed by Linus. The first patch is against the GCC plugins subsystem, but was reviewed by the maintainer and can be taken through the ARM tree. ---------------------------------------------------------------- Cc: Keith Packard Cc: Kees Cook Cc: Arnd Bergmann Cc: Amit Daniel Kachhap Cc: Linus Walleij Ard Biesheuvel (4): gcc-plugins: arm-ssp: Prepare for THREAD_INFO_IN_TASK support ARM: smp: Free up the TLS register while running in the kernel ARM: smp: Store current pointer in TPIDRURO register if available ARM: smp: Enable THREAD_INFO_IN_TASK Keith Packard (1): ARM: smp: Pass task to secondary_start_kernel arch/arm/Kconfig | 8 ++++- arch/arm/Makefile | 9 ++--- arch/arm/include/asm/assembler.h | 29 ++++++++++++++++ arch/arm/include/asm/current.h | 50 +++++++++++++++++++++++++++ arch/arm/include/asm/smp.h | 3 +- arch/arm/include/asm/stackprotector.h | 2 -- arch/arm/include/asm/switch_to.h | 16 +++++++++ arch/arm/include/asm/thread_info.h | 15 +++++--- arch/arm/include/asm/tls.h | 10 ++++-- arch/arm/kernel/asm-offsets.c | 6 ++-- arch/arm/kernel/entry-armv.S | 5 +++ arch/arm/kernel/entry-common.S | 1 + arch/arm/kernel/entry-header.S | 8 +++++ arch/arm/kernel/head-common.S | 5 +++ arch/arm/kernel/head-nommu.S | 1 + arch/arm/kernel/head.S | 5 +-- arch/arm/kernel/process.c | 8 ++--- arch/arm/kernel/smp.c | 13 +++++-- arch/arm/mm/proc-macros.S | 3 +- scripts/gcc-plugins/arm_ssp_per_task_plugin.c | 27 ++++----------- 20 files changed, 174 insertions(+), 50 deletions(-) create mode 100644 arch/arm/include/asm/current.h _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel