From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 70477 invoked by alias); 16 Dec 2018 20:06:59 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Received: (qmail 70366 invoked by uid 89); 16 Dec 2018 20:06:58 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-25.9 required=5.0 tests=BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,KAM_LAZY_DOMAIN_SECURITY autolearn=ham version=3.3.2 spammy=iff, act X-HELO: hall.aurel32.net Date: Sun, 16 Dec 2018 22:57:00 -0000 From: Aurelien Jarno To: Adhemerval Zanella Cc: libc-alpha@sourceware.org Subject: Re: [PATCH 1/5] m68k: Fix sigaction kernel definition (BZ #23960) Message-ID: <20181216200651.GA3039@aurel32.net> Mail-Followup-To: Adhemerval Zanella , libc-alpha@sourceware.org References: <20181211195554.3377-1-adhemerval.zanella@linaro.org> <87y38vlppm.fsf@igel.home> <55c8ffc0-c2af-4bc8-8377-3c3310213a83@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) X-SW-Source: 2018-12/txt/msg00534.txt.bz2 Hi, On 2018-12-12 16:52, Adhemerval Zanella wrote: > > > On 12/12/2018 08:41, Andreas Schwab wrote: > > On Dez 12 2018, Adhemerval Zanella wrote: > > > >> The m68k kernel does define SA_RESTORER on arch/m68k/include/asm/signal.h > >> (__ARCH_HAS_SA_RESTORER), > > > > These are not the same. The latter only tells to > > add the sa_restorer member, independent of SA_RESTORER (which m68k > > doesn't define). > > > >> but the only difference it makes for m68k is at flush_signal_handlers > >> where kernel sets the sa_restorer to NULL. So it indeed should be safe > >> to just use default kernel_sigaction.h (I don't see any signal test > >> issues). Updated patch below. > > > > This fails to add the sa_restorer member, causing the signal mask to be > > mishandled. > > > > Andreas. > > > > Updated patch below. > > -- > > [BZ #23960] > * sysdeps/unix/sysv/linux/kernel_sigaction.h (HAS_SA_RESTORER): > Define if SA_RESTORER is defined. > (kernel_sigaction): Define sa_restorer if HAS_SA_RESTORER is defined. > (SET_SA_RESTORER, RESET_SA_RESTORER): Define iff the macro are not > already defined. > * sysdeps/unix/sysv/linux/m68k/kernel_sigaction.h (SA_RESTORER, > kernel_sigaction, SET_SA_RESTORER, RESET_SA_RESTORER): Remove > definitions. > (HAS_SA_RESTORER): Define. > * sysdeps/unix/sysv/linux/sparc/kernel_sigaction.h (SA_RESTORER, > SET_SA_RESTORER, RESET_SA_RESTORER): Remove definition. > (HAS_SA_RESTORER): Define. > * sysdeps/unix/sysv/linux/nios2/kernel_sigaction.h: Include generic > kernel_sigaction after define SET_SA_RESTORER and RESET_SA_RESTORER. > * sysdeps/unix/sysv/linux/powerpc/kernel_sigaction.h: Likewise. > * sysdeps/unix/sysv/linux/s390/kernel_sigaction.h: Likewise. > * sysdeps/unix/sysv/linux/x86_64/sigaction.c: Likewise. [ snip ] > diff --git a/sysdeps/unix/sysv/linux/s390/kernel_sigaction.h b/sysdeps/unix/sysv/linux/s390/kernel_sigaction.h > index 7a6a2c4f29..14f44c200b 100644 > --- a/sysdeps/unix/sysv/linux/s390/kernel_sigaction.h > +++ b/sysdeps/unix/sysv/linux/s390/kernel_sigaction.h > @@ -30,3 +30,5 @@ struct kernel_sigaction > (kact)->sa_restorer = (act)->sa_restorer > #define RESET_SA_RESTORER(act, kact) \ > (act)->sa_restorer = (kact)->sa_restorer > + > +#include This is not correct, you should also remove struct kernel_sigaction from this file, like it was done in the initial version of the patchset (patch 5). Aurelien -- Aurelien Jarno GPG: 4096R/1DDD8C9B aurelien@aurel32.net http://www.aurel32.net