From patchwork Tue Feb 23 23:39:37 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nix X-Patchwork-Id: 11025 Received: (qmail 51680 invoked by alias); 23 Feb 2016 23:40:01 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 51583 invoked by uid 89); 23 Feb 2016 23:40:00 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=1.0 required=5.0 tests=AWL, BAYES_50, KAM_LAZY_DOMAIN_SECURITY, RP_MATCHES_RCVD autolearn=no version=3.3.2 spammy=UD:7.0.198.g6dd47b6, UD:2.7.0.198.g6dd47b6, sk:2.7.0.1, sk:2701 X-HELO: mail.esperi.org.uk From: Nix To: libc-alpha@sourceware.org Cc: carlos@redhat.com Subject: [PATCH 14/14] sparc: do not stack-protect the sigreturn handler. Date: Tue, 23 Feb 2016 23:39:37 +0000 Message-Id: <1456270777-9083-15-git-send-email-nix@esperi.org.uk> In-Reply-To: <1456270777-9083-1-git-send-email-nix@esperi.org.uk> References: <1456270777-9083-1-git-send-email-nix@esperi.org.uk> X-DCC-wuwien-Metrics: spindle 1290; Body=2 Fuz1=2 Fuz2=2 From: Nick Alcock This is called from the kernel and must not have a canary. v2: New. --- sysdeps/unix/sysv/linux/sparc/sparc32/Makefile | 7 +++++++ sysdeps/unix/sysv/linux/sparc/sparc64/Makefile | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/Makefile b/sysdeps/unix/sysv/linux/sparc/sparc32/Makefile index 21c7dc1..60fb6f6 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc32/Makefile +++ b/sysdeps/unix/sysv/linux/sparc/sparc32/Makefile @@ -26,3 +26,10 @@ ifeq ($(subdir),math) # Provide these routines here as well. libm-routines += multc3 divtc3 endif # math + +ifneq (,$(filter signal nptl,$(subdir))) +ifeq ($(have-ssp),yes) +# We must not stack-protect the sigreturn handler. +CFLAGS-sigaction.c += -fno-stack-protector +endif # have-ssp +endif # signal diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/Makefile b/sysdeps/unix/sysv/linux/sparc/sparc64/Makefile index 7ea433f..dada022 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc64/Makefile +++ b/sysdeps/unix/sysv/linux/sparc/sparc64/Makefile @@ -12,3 +12,10 @@ ifeq ($(subdir),nptl) CFLAGS-pause.c += -fexceptions CFLAGS-sigsuspend.c += -fexceptions endif + +ifneq (,$(filter signal nptl,$(subdir))) +ifeq ($(have-ssp),yes) +# We must not stack-protect the sigreturn handler. +CFLAGS-sigaction.c += -fno-stack-protector +endif # have-ssp +endif # signal