From patchwork Tue Jul 30 09:25:47 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Will Deacon X-Patchwork-Id: 170046 Delivered-To: patch@linaro.org Received: by 2002:a92:512:0:0:0:0:0 with SMTP id q18csp2396252ile; Tue, 30 Jul 2019 02:25:58 -0700 (PDT) X-Google-Smtp-Source: APXvYqy4Y3bguEMMXXwEP8b6kJRlDk3vo+5VTPBHrGezBzoCaGp/NJTLvN7CqWBUa3q8IKc2Gsfk X-Received: by 2002:a65:5144:: with SMTP id g4mr55750361pgq.202.1564478758017; Tue, 30 Jul 2019 02:25:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564478758; cv=none; d=google.com; s=arc-20160816; b=ANB61VWj225KeH7quxeVLDz56ILis1h6Y78Y7Ou7E9a62xbkoewUk6gkZ9eEJD9U60 wYhsj6lPiqFVbwHGZmF5mfspwhB36olvqUunaq8vW1xLZsX4q9De/8LWfzzQI+OOI1sH XwBUXMk8jyPNDW8W1vqoPrwpM6mTP4Q7THtILfp3M/QpfY3w26PAJB+aK6zuNSQU8GMI mv1EFpFVcWUeXzhemZcmTRVRnPTE/gcN0EZENxqdguzSmW71neAT5UJpTcrXuDU66Uso iXX3X4BZtmU5ytaIRQGDOYDBBhfckVgnjMDLos7WZrnWu/onsBB7hSa+xL19HXdBHrvS vJfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=M8DZskHqbuRArsZ4rb7mqM0n3TFAEQ1TZRpe94KHKSc=; b=KRnUDUjjrvXSovbkSniQq67ONJ29DEmpFtlLIkhZdLOzPuHonIPx8tBOjHHyrt2SZL h80Br87eZQmysFeWWUFAZBQFdSBmwOWARvv8ukPcE0B6IT870HRrHLaic5OqXxUtgP34 GL74sVO1N62SnR+9KK0Ks11KHe021QxnzIiGV1oHFMliapvJ8LChXZKvG2H9ueJsIprB a4qLk5WR09KjrzohUHzXzy/FIF0EoS7G31R6MrW+gl6f66GN77v3sG7NTwJx+wFVeLYR 4IYEOlejRh36SyfG40gKPmVfS3WNspYgmE0zyh40zFjeIXHtRv8VxyFhhnuS5gPdPC1U +Uzw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=2F0v4akX; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q13si29105481pgr.514.2019.07.30.02.25.57; Tue, 30 Jul 2019 02:25:58 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=2F0v4akX; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731218AbfG3JZ4 (ORCPT + 29 others); Tue, 30 Jul 2019 05:25:56 -0400 Received: from mail.kernel.org ([198.145.29.99]:59216 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731046AbfG3JZy (ORCPT ); Tue, 30 Jul 2019 05:25:54 -0400 Received: from localhost.localdomain (236.31.169.217.in-addr.arpa [217.169.31.236]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 906A22089E; Tue, 30 Jul 2019 09:25:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1564478753; bh=nqU4k4X/e7lYeTAPiZAW8mdKZR5UN/bj9V8U1bHWGn8=; h=From:To:Cc:Subject:Date:From; b=2F0v4akXyoiqT9/IdB6Ohu4GIcsn8FKvMOtHoG+WiVduFmfrv/2DFnEhZcTFRMI38 djITFzPR+wZabZ+x6kLMIDxM8IeHsUqlAD02hW1ZOJmf8bPYufh5CJ1EzwQEM2Abru Yd+T5QoVt9ASTYqx5qMTWhukv0Vsan1typDxX4/Q= From: Will Deacon To: gregkh@linuxfoundation.org Cc: linux-kernel@vger.kernel.org, Will Deacon , "# 4 . 9+" , Aurelien Jarno , Arnd Bergmann , Dominik Brodowski , "Eric W. Biederman" , Andrew Morton , Al Viro , Oleg Nesterov , Catalin Marinas Subject: [PATCH] arm64: compat: Provide definition for COMPAT_SIGMINSTKSZ Date: Tue, 30 Jul 2019 10:25:47 +0100 Message-Id: <20190730092547.1284-1-will@kernel.org> X-Mailer: git-send-email 2.11.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Will Deacon [ Upstream commit 24951465cbd279f60b1fdc2421b3694405bcff42 ] arch/arm/ defines a SIGMINSTKSZ of 2k, so we should use the same value for compat tasks. Cc: # 4.9+ Cc: Aurelien Jarno Cc: Arnd Bergmann Cc: Dominik Brodowski Cc: "Eric W. Biederman" Cc: Andrew Morton Cc: Al Viro Cc: Oleg Nesterov Reviewed-by: Dave Martin Reported-by: Steve McIntyre Tested-by: Steve McIntyre <93sam@debian.org> Signed-off-by: Will Deacon Signed-off-by: Catalin Marinas --- Aurelien points out that this didn't get selected for -stable despite its counterpart (22839869f21a ("signal: Introduce COMPAT_SIGMINSTKSZ for use in compat_sys_sigaltstack")) being backported to 4.9. Oops. arch/arm64/include/asm/compat.h | 1 + 1 file changed, 1 insertion(+) -- 2.11.0 diff --git a/arch/arm64/include/asm/compat.h b/arch/arm64/include/asm/compat.h index 1a037b94eba1..cee28a05ee98 100644 --- a/arch/arm64/include/asm/compat.h +++ b/arch/arm64/include/asm/compat.h @@ -159,6 +159,7 @@ static inline compat_uptr_t ptr_to_compat(void __user *uptr) } #define compat_user_stack_pointer() (user_stack_pointer(task_pt_regs(current))) +#define COMPAT_MINSIGSTKSZ 2048 static inline void __user *arch_compat_alloc_user_space(long len) {