From: Stratos Psomadakis <psomas@cslab.ece.ntua.gr>
To: linuxppc-dev@lists.ozlabs.org
Cc: schwab@linux-m68k.org, linux-kernel@vger.kernel.org
Subject: [RESEND PATCH 1/2] ppc: Fix compiler warning in ptrace.c [-Wno-array-bounds]
Date: Sat, 7 May 2011 18:54:34 +0300 [thread overview]
Message-ID: <1304783674-3977-1-git-send-email-psomas@cslab.ece.ntua.gr> (raw)
In-Reply-To: <m2oc3eh744.fsf@igel.home>
The trick used to bypass the thread_struct fpr array in order to access the
struct fpscr, in arch/powerpc/kernel/ptrace.c, can trigger an "array subscript
is above array bounds [-Werror=array-bounds]" warning.
Add -Wno-array-bounds to CFLAGS_ptrace.o, in arch/powerpc/kernel/Makefile to
slience this warning.
Signed-off-by: Stratos Psomadakis <psomas@ece.ntua.gr>
---
arch/powerpc/kernel/Makefile | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/powerpc/kernel/Makefile b/arch/powerpc/kernel/Makefile
index 3bb2a3e..92b1002 100644
--- a/arch/powerpc/kernel/Makefile
+++ b/arch/powerpc/kernel/Makefile
@@ -2,7 +2,7 @@
# Makefile for the linux kernel.
#
-CFLAGS_ptrace.o += -DUTS_MACHINE='"$(UTS_MACHINE)"'
+CFLAGS_ptrace.o += -DUTS_MACHINE='"$(UTS_MACHINE)"' $(call cc-option, -Wno-array-bounds)
subdir-ccflags-$(CONFIG_PPC_WERROR) := -Werror
--
1.5.6.5
next prev parent reply other threads:[~2011-05-07 15:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-07 14:11 [PATCH 0/2] ppc/cleaup: Fix compiler warnings Stratos Psomadakis
2011-05-07 14:11 ` [PATCH 1/2] ppc: Fix compiler warning in ptrace.c [-Wno-array-bounds] Stratos Psomadakis
2011-05-07 15:18 ` Andreas Schwab
2011-05-07 15:54 ` Stratos Psomadakis [this message]
2011-05-07 15:57 ` Stratos Psomadakis
2011-05-07 14:11 ` [PATCH 2/2] ppc64: Fix compiler warning in pgtable-ppc64.h [-Wunused-but-set-variable] Stratos Psomadakis
2011-05-08 20:02 ` [PATCH 0/2] ppc/cleaup: Fix compiler warnings Stratos Psomadakis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1304783674-3977-1-git-send-email-psomas@cslab.ece.ntua.gr \
--to=psomas@cslab.ece.ntua.gr \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=schwab@linux-m68k.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).