Message ID | 20241010-arm-generic-entry-v1-1-b94f451d087b@linaro.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id A0BF3CF11D0 for <linux-arm-kernel@archiver.kernel.org>; Thu, 10 Oct 2024 11:36:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References :Message-Id:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date: From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=2ECqHBAN3rDV9yo1zqeLO+ji9lVIoh6IkMKI7b6YgP4=; b=oS80ddL9JKrLI832FyF/YZ0Tle XhNW7VnERD2mlgwqW31I2kpusnMd0R24cQb1KsRQTVm9sCszNaPKvgShHK3TMtu+RT8+KGxoWZ1Ur 3u/mz4kV02u+23kJgMau/bmF7/LGlEDiXfKZZKlAhCnnFDGnchxodbO4QWCtW9DlPg1hiWkZyDKjH hKJTQ5P9LkG6j6U/gvlK+h3HUuLnFfCJ4SdDOMEtQoOJD+CzW32KqgPdczHjXSFSHJpPgiX+BEZl4 pNzNk/Yiz1JZvfw9Z3Fno2RXcf3kmwB9lEDFEtEnExW5QOI4WIrdE6ATiqVHxeWgkDo2kzMGr3cgQ AN7FD0/Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1syrSR-0000000CYq7-0VmT; Thu, 10 Oct 2024 11:35:51 +0000 Received: from mail-lf1-x12d.google.com ([2a00:1450:4864:20::12d]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1syrQP-0000000CY9O-2zTh for linux-arm-kernel@lists.infradead.org; Thu, 10 Oct 2024 11:33:49 +0000 Received: by mail-lf1-x12d.google.com with SMTP id 2adb3069b0e04-5398b589032so1347474e87.1 for <linux-arm-kernel@lists.infradead.org>; Thu, 10 Oct 2024 04:33:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1728560024; x=1729164824; darn=lists.infradead.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=2ECqHBAN3rDV9yo1zqeLO+ji9lVIoh6IkMKI7b6YgP4=; b=v1UBSJoCf1Z5ktoUl0v0M3ed/okZW3qEn6a0MNSS1TXEPXYBar21kmXPyYLsbU6jJj ev+Qy677pFMoDNNEJMqFNkdDfhp29saHxln0C7Pk8A0MFwFzVCDuDCQOhd3APah8kL9d kbCNWnJlgcsJymXIGy1vE3GMuuhRM17VJ2OwoZbvp5MWdSK6kvRAVDPwTzQFyGPQ4SAM exWwMi5SYQaPFx0N3bopt/iD1eOMuaNtnOQBddjX67yBDy7nDFJVyAuRx0Vox7lkP7q+ 0mDb1ACScLRE96sb1j3YR8cZVTxlXCLwxJH2j0gLnkDijYopDjJu831er7ItHA/XRrLS SwDQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728560024; x=1729164824; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=2ECqHBAN3rDV9yo1zqeLO+ji9lVIoh6IkMKI7b6YgP4=; b=g3P9jOn7H+Pgu6AbMKIV5LMPOaVCHDsD3n+2mjTG/SuvctNoaKfR7gY+ll6fIVXZFT Be+54DcWeeGSr0+b4kgsJ6RH9X+C3bOlD4a4hch9G70zoDImyhsNj0RtsaZDbvSUhAdD MXjGu04n/8Q7y4x4SFjC0eb+QPNK+gpXTN4FJfDaQ09F9mZmsD1edwezyygvgmM1O4YE a5I/EIyPmnDYP3DvQ/OGAh3pPPzcAQZY3yjvblW5HkSrI7s6mi2m93w1N3ePgwDZYLez QOl/Gn32GVj4dOaIsjZ4yNEnvCsIRD1gV3ypwcXxuYFdqeBYOLinqdbEeNX6uELNohqd oYCw== X-Gm-Message-State: AOJu0YxtMKhiRsXJfLG1vZQrOYWdUbiQdPdpd8ir2uZezFm+vA1vow7N BKGXwA2NeDbSfvpKvOo/s/LDhP/DWRXRD4m4WBZZyiIFRH0wwDFyDDMgUVM/cEw= X-Google-Smtp-Source: AGHT+IEzOwjSeRaNRAgIP2djHbcgDjxIdas3zeUxGw2eRXDLl+1CJu9P76G7kqLMU7BvW+xxCPu7BQ== X-Received: by 2002:a05:6512:31ca:b0:52c:e17c:cd7b with SMTP id 2adb3069b0e04-539c489fecdmr5606542e87.22.1728560023941; Thu, 10 Oct 2024 04:33:43 -0700 (PDT) Received: from lino.lan ([85.235.12.238]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a99a7f25406sm77619066b.69.2024.10.10.04.33.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Oct 2024 04:33:42 -0700 (PDT) From: Linus Walleij <linus.walleij@linaro.org> Date: Thu, 10 Oct 2024 13:33:39 +0200 Subject: [PATCH RFC 01/28] ARM: Prepare includes for generic entry MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20241010-arm-generic-entry-v1-1-b94f451d087b@linaro.org> References: <20241010-arm-generic-entry-v1-0-b94f451d087b@linaro.org> In-Reply-To: <20241010-arm-generic-entry-v1-0-b94f451d087b@linaro.org> To: Oleg Nesterov <oleg@redhat.com>, Russell King <linux@armlinux.org.uk>, Kees Cook <kees@kernel.org>, Andy Lutomirski <luto@amacapital.net>, Will Drewry <wad@chromium.org>, Frederic Weisbecker <frederic@kernel.org>, "Paul E. McKenney" <paulmck@kernel.org>, Jinjie Ruan <ruanjinjie@huawei.com>, Arnd Bergmann <arnd@arndb.de>, Ard Biesheuvel <ardb@kernel.org>, Al Viro <viro@zeniv.linux.org.uk> Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Linus Walleij <linus.walleij@linaro.org> X-Mailer: b4 0.14.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241010_043345_790796_E465FB40 X-CRM114-Status: GOOD ( 14.04 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 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> Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org> Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org |
Series |
ARM: Switch to generic entry
|
expand
|
diff --git a/arch/arm/include/asm/ptrace.h b/arch/arm/include/asm/ptrace.h index 6eb311fb2da0..a01c66f0ad90 100644 --- a/arch/arm/include/asm/ptrace.h +++ b/arch/arm/include/asm/ptrace.h @@ -52,6 +52,11 @@ struct svc_pt_regs { #define fast_interrupts_enabled(regs) \ (!((regs)->ARM_cpsr & PSR_F_BIT)) +static inline int regs_irqs_disabled(struct pt_regs *regs) +{ + return !interrupts_enabled(regs); +} + /* Are the current registers suitable for user mode? * (used to maintain security in signal handlers) */ diff --git a/arch/arm/include/asm/stacktrace.h b/arch/arm/include/asm/stacktrace.h index f80a85b091d6..815b5f256af1 100644 --- a/arch/arm/include/asm/stacktrace.h +++ b/arch/arm/include/asm/stacktrace.h @@ -26,7 +26,7 @@ struct stackframe { #endif }; -static inline bool on_thread_stack(void) +static __always_inline bool on_thread_stack(void) { unsigned long delta = current_stack_pointer ^ (unsigned long)current->stack;
The generic entry code needs a static inline function for regs_irq_disabled() so add this, in further requires the signature of on_thread_stack() to be __always_inline so add this as well. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> --- arch/arm/include/asm/ptrace.h | 5 +++++ arch/arm/include/asm/stacktrace.h | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-)