From nobody Fri Dec 19 00:02:44 2025 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id DCA60C54EE9 for ; Tue, 13 Sep 2022 14:13:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232619AbiIMONI (ORCPT ); Tue, 13 Sep 2022 10:13:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37580 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232849AbiIMOMe (ORCPT ); Tue, 13 Sep 2022 10:12:34 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5343C6366; Tue, 13 Sep 2022 07:09:59 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 87308B80EFB; Tue, 13 Sep 2022 14:09:57 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E09E9C433D7; Tue, 13 Sep 2022 14:09:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1663078196; bh=6byrZ7OCXiod0WvMwsQKy2Ly30zcGOEPk0FzEf+jWG4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=tE3/15uMN/Jz0XOtNluyrCiZtZe+a6on2+ShOB+kmom/dmowrNuBcDYsRfnWIZIjJ ym2dA4iesq6IElm6AetQLY5H7azPot0uyhCINuLpo23yTS64uzkabWsOS1xJ9i6Hm2 bx6M+2duEBVmC1o21tFQDWSMgHkdCrVMeShoH/YY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Mark Brown , Catalin Marinas , Will Deacon , Sasha Levin Subject: [PATCH 5.19 023/192] arm64/signal: Raise limit on stack frames Date: Tue, 13 Sep 2022 16:02:09 +0200 Message-Id: <20220913140411.062788224@linuxfoundation.org> X-Mailer: git-send-email 2.37.3 In-Reply-To: <20220913140410.043243217@linuxfoundation.org> References: <20220913140410.043243217@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Mark Brown [ Upstream commit 7ddcaf78e93c9282b4d92184f511b4d5bee75355 ] The signal code has a limit of 64K on the size of a stack frame that it will generate, if this limit is exceeded then a process will be killed if it receives a signal. Unfortunately with the advent of SME this limit is too small - the maximum possible size of the ZA register alone is 64K. This is not an issue for practical systems at present but is easily seen using virtual platforms. Raise the limit to 256K, this is substantially more than could be used by any current architecture extension. Signed-off-by: Mark Brown Acked-by: Catalin Marinas Link: https://lore.kernel.org/r/20220817182324.638214-2-broonie@kernel.org Signed-off-by: Will Deacon Signed-off-by: Sasha Levin --- arch/arm64/kernel/signal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/kernel/signal.c b/arch/arm64/kernel/signal.c index 8bb631bf9464c..e8e1f46d383da 100644 --- a/arch/arm64/kernel/signal.c +++ b/arch/arm64/kernel/signal.c @@ -91,7 +91,7 @@ static size_t sigframe_size(struct rt_sigframe_user_layou= t const *user) * not taken into account. This limit is not a guarantee and is * NOT ABI. */ -#define SIGFRAME_MAXSZ SZ_64K +#define SIGFRAME_MAXSZ SZ_256K =20 static int __sigframe_alloc(struct rt_sigframe_user_layout *user, unsigned long *offset, size_t size, bool extend) --=20 2.35.1