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=-11.2 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_SANE_1 autolearn=unavailable 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 F3E5FC433DF for ; Wed, 19 Aug 2020 10:31:23 +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 BCDBD2076E for ; Wed, 19 Aug 2020 10:31:23 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="OmKoAPqb" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org BCDBD2076E 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:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=6/L0zXn+FRXhU6t/ZyOpOzlFZEnBoRQ98EhV3oK/81s=; b=OmKoAPqbAt4KQoef8J66dxlVM jybxX88Fbw/fC2HPCR327vj9xlYKbGMMkaxVycD/WLZaUtLPxd+2at18CLyoBj+hTurA1uRxfOXiS OxVq3QD3m4sEAA9Rt5Ko5SUDNGOgAAvqFf9WiAkBaEZOmp0skmlqlHr3olOPJvxJPtX2A5f8zy40w irhmK3r6auj+A4wLCfLUbpulw9UJq9Tc3Y+tkJ88BJB/IViRyP+HO6634+I/ljDxxE+GWVdoyEoJ5 HKT6/MhixWc0Tqva9lf+rXGMupQ3cqp21bAAMM4wvPSF0+9gpPuc/NRZxswMgjNY7z8KNO86RnlT1 rIbwPDjjg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k8LM9-0007lG-Fh; Wed, 19 Aug 2020 10:30:09 +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 1k8LM6-0007km-UJ for linux-arm-kernel@lists.infradead.org; Wed, 19 Aug 2020 10:30:07 +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 C5727101E; Wed, 19 Aug 2020 03:30:04 -0700 (PDT) Received: from arm.com (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id DE9BF3F6CF; Wed, 19 Aug 2020 03:30:02 -0700 (PDT) Date: Wed, 19 Aug 2020 11:30:00 +0100 From: Dave Martin To: Peter Collingbourne Subject: Re: [PATCH v9 2/6] arch: move SA_* definitions to generic headers Message-ID: <20200819103000.GE6642@arm.com> References: <691510496a422023a2934d42b068493ed2d60ccc.1597720138.git.pcc@google.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <691510496a422023a2934d42b068493ed2d60ccc.1597720138.git.pcc@google.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200819_063007_143160_ABAF5C4A X-CRM114-Status: GOOD ( 25.87 ) 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: Linux ARM , linux-parisc@vger.kernel.org, Catalin Marinas , Kevin Brodsky , Oleg Nesterov , "James E.J. Bottomley" , Kostya Serebryany , "Eric W. Biederman" , Andrey Konovalov , David Spickett , Vincenzo Frascino , Will Deacon , Evgenii Stepanov , Richard Henderson 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 On Mon, Aug 17, 2020 at 08:33:47PM -0700, Peter Collingbourne wrote: > Most architectures with the exception of alpha, mips, parisc and > sparc use the same values for these flags. Move their definitions into > asm-generic/signal-defs.h and allow the architectures with non-standard > values to override them. Also, document the non-standard flag values > in order to make it easier to add new generic flags in the future. > > Signed-off-by: Peter Collingbourne > --- > View this change in Gerrit: https://linux-review.googlesource.com/q/Ia3849f18b8009bf41faca374e701cdca36974528 > > arch/alpha/include/uapi/asm/signal.h | 14 -------- > arch/arm/include/uapi/asm/signal.h | 28 ++------------- > arch/h8300/include/uapi/asm/signal.h | 24 ------------- > arch/ia64/include/uapi/asm/signal.h | 24 ------------- > arch/m68k/include/uapi/asm/signal.h | 24 ------------- > arch/mips/include/uapi/asm/signal.h | 12 ------- > arch/parisc/include/uapi/asm/signal.h | 13 ------- > arch/powerpc/include/uapi/asm/signal.h | 24 ------------- > arch/s390/include/uapi/asm/signal.h | 24 ------------- > arch/sparc/include/uapi/asm/signal.h | 4 +-- > arch/x86/include/uapi/asm/signal.h | 24 ------------- > arch/xtensa/include/uapi/asm/signal.h | 24 ------------- > include/uapi/asm-generic/signal-defs.h | 47 ++++++++++++++++++++++++++ > include/uapi/asm-generic/signal.h | 29 ---------------- > 14 files changed, 51 insertions(+), 264 deletions(-) Nice diffstat! > > diff --git a/arch/alpha/include/uapi/asm/signal.h b/arch/alpha/include/uapi/asm/signal.h > index 74c750bf1c1a..a69dd8d080a8 100644 > --- a/arch/alpha/include/uapi/asm/signal.h > +++ b/arch/alpha/include/uapi/asm/signal.h > @@ -60,20 +60,6 @@ typedef unsigned long sigset_t; > #define SIGRTMIN 32 > #define SIGRTMAX _NSIG > > -/* > - * SA_FLAGS values: > - * > - * SA_ONSTACK indicates that a registered stack_t will be used. > - * SA_RESTART flag to get restarting signals (which were the default long ago) > - * SA_NOCLDSTOP flag to turn off SIGCHLD when children stop. > - * SA_RESETHAND clears the handler when the signal is delivered. > - * SA_NOCLDWAIT flag on SIGCHLD to inhibit zombies. > - * SA_NODEFER prevents the current signal from being masked in the handler. > - * > - * SA_ONESHOT and SA_NOMASK are the historical Linux names for the Single > - * Unix names RESETHAND and NODEFER respectively. > - */ > - > #define SA_ONSTACK 0x00000001 > #define SA_RESTART 0x00000002 > #define SA_NOCLDSTOP 0x00000004 > diff --git a/arch/arm/include/uapi/asm/signal.h b/arch/arm/include/uapi/asm/signal.h > index 9b4185ba4f8a..7727f0984d26 100644 > --- a/arch/arm/include/uapi/asm/signal.h > +++ b/arch/arm/include/uapi/asm/signal.h > @@ -60,33 +60,11 @@ typedef unsigned long sigset_t; > #define SIGSWI 32 > > /* > - * SA_FLAGS values: > - * > - * SA_NOCLDSTOP flag to turn off SIGCHLD when children stop. > - * SA_NOCLDWAIT flag on SIGCHLD to inhibit zombies. > - * SA_SIGINFO deliver the signal with SIGINFO structs > - * SA_THIRTYTWO delivers the signal in 32-bit mode, even if the task > - * is running in 26-bit. > - * SA_ONSTACK allows alternate signal stacks (see sigaltstack(2)). > - * SA_RESTART flag to get restarting signals (which were the default long ago) > - * SA_NODEFER prevents the current signal from being masked in the handler. > - * SA_RESETHAND clears the handler when the signal is delivered. > - * > - * SA_ONESHOT and SA_NOMASK are the historical Linux names for the Single > - * Unix names RESETHAND and NODEFER respectively. > + * SA_THIRTYTWO historically meant deliver the signal in 32-bit mode, even if > + * the task is running in 26-bit. But since the kernel no longer supports > + * 26-bit mode, the flag has no effect. > */ > -#define SA_NOCLDSTOP 0x00000001 > -#define SA_NOCLDWAIT 0x00000002 > -#define SA_SIGINFO 0x00000004 > #define SA_THIRTYTWO 0x02000000 Can we add a placeholder for this in the common header? We don't want people accidentally defining a new generic flag that clashes with this. > -#define SA_RESTORER 0x04000000 > -#define SA_ONSTACK 0x08000000 > -#define SA_RESTART 0x10000000 > -#define SA_NODEFER 0x40000000 > -#define SA_RESETHAND 0x80000000 > - > -#define SA_NOMASK SA_NODEFER > -#define SA_ONESHOT SA_RESETHAND > > #define MINSIGSTKSZ 2048 > #define SIGSTKSZ 8192 [...] Otherwise, looks like a sensible cleanup. Cheers ---Dave _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel