Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1304875 > unrolled thread
| Started by | Brian Norris <computersforpeace@gmail.com> |
|---|---|
| First post | 2016-01-08 19:40 +0100 |
| Last post | 2016-01-12 13:40 +0100 |
| Articles | 4 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH v2 1/2] cxl: fix build for GCC 4.6.x Brian Norris <computersforpeace@gmail.com> - 2016-01-08 19:40 +0100
[PATCH v2 2/2] cxl: use -Werror only with CONFIG_PPC_WERROR Brian Norris <computersforpeace@gmail.com> - 2016-01-08 19:40 +0100
Re: [v2,2/2] cxl: use -Werror only with CONFIG_PPC_WERROR Michael Ellerman <mpe@ellerman.id.au> - 2016-01-12 13:40 +0100
Re: [v2,1/2] cxl: fix build for GCC 4.6.x Michael Ellerman <mpe@ellerman.id.au> - 2016-01-12 13:40 +0100
| From | Brian Norris <computersforpeace@gmail.com> |
|---|---|
| Date | 2016-01-08 19:40 +0100 |
| Subject | [PATCH v2 1/2] cxl: fix build for GCC 4.6.x |
| Message-ID | <qOK78-2eA-3@gated-at.bofh.it> |
GCC 4.6.3 does not support -Wno-unused-const-variable. Instead, use the
kbuild infrastructure that checks if this options exists.
Fixes: 2cd55c68c0a4 ("cxl: Fix build failure due to -Wunused-variable behaviour change")
Suggested-by: Michal Marek <mmarek@suse.com>
Suggested-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
---
v2: don't remove -Werror
drivers/misc/cxl/Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/misc/cxl/Makefile b/drivers/misc/cxl/Makefile
index 6982f603fadc..ab6f392d3504 100644
--- a/drivers/misc/cxl/Makefile
+++ b/drivers/misc/cxl/Makefile
@@ -1,4 +1,4 @@
-ccflags-y := -Werror -Wno-unused-const-variable
+ccflags-y := -Werror $(call cc-disable-warning, unused-const-variable)
cxl-y += main.o file.o irq.o fault.o native.o
cxl-y += context.o sysfs.o debugfs.o pci.o trace.o
--
2.6.0.rc2.230.g3dd15c0
[toc] | [next] | [standalone]
| From | Brian Norris <computersforpeace@gmail.com> |
|---|---|
| Date | 2016-01-08 19:40 +0100 |
| Subject | [PATCH v2 2/2] cxl: use -Werror only with CONFIG_PPC_WERROR |
| Message-ID | <qOK78-2eA-1@gated-at.bofh.it> |
| In reply to | #1304875 |
Some developers really like to have -Werror enabled for their code, as
it helps to ensure warning free code. Others don't want -Werror, as it
(for example) can cause problems when newer (or older) compilers have
different sets of warnings, or new warnings can appear just when turning
up the warning level (e.g., make W=1 or W=2). Thus, it seems prudent to
have the use of -Werror be configurable.
It so happens that cxl is only built on PowerPC, and PowerPC already
has a nice set of Kconfig options for this, under CONFIG_PPC_WERROR. So
let's use that, and the world is a happy place again! (Note that
PPC_WERROR defaults to =y, so the common case compile should still be
enforcing -Werror.)
Fixes: d3d73f4b38a8 ("cxl: Compile with -Werror")
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
---
v2: new in v2
drivers/misc/cxl/Makefile | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/misc/cxl/Makefile b/drivers/misc/cxl/Makefile
index ab6f392d3504..be2ac5ce349f 100644
--- a/drivers/misc/cxl/Makefile
+++ b/drivers/misc/cxl/Makefile
@@ -1,4 +1,5 @@
-ccflags-y := -Werror $(call cc-disable-warning, unused-const-variable)
+ccflags-y := $(call cc-disable-warning, unused-const-variable)
+ccflags-$(CONFIG_PPC_WERROR) += -Werror
cxl-y += main.o file.o irq.o fault.o native.o
cxl-y += context.o sysfs.o debugfs.o pci.o trace.o
--
2.6.0.rc2.230.g3dd15c0
[toc] | [prev] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-01-12 13:40 +0100 |
| Subject | Re: [v2,2/2] cxl: use -Werror only with CONFIG_PPC_WERROR |
| Message-ID | <qQ6oX-Sx-39@gated-at.bofh.it> |
| In reply to | #1304876 |
On Fri, 2016-08-01 at 18:30:10 UTC, Brian Norris wrote:
> Some developers really like to have -Werror enabled for their code, as
> it helps to ensure warning free code. Others don't want -Werror, as it
> (for example) can cause problems when newer (or older) compilers have
> different sets of warnings, or new warnings can appear just when turning
> up the warning level (e.g., make W=1 or W=2). Thus, it seems prudent to
> have the use of -Werror be configurable.
>
> It so happens that cxl is only built on PowerPC, and PowerPC already
> has a nice set of Kconfig options for this, under CONFIG_PPC_WERROR. So
> let's use that, and the world is a happy place again! (Note that
> PPC_WERROR defaults to =y, so the common case compile should still be
> enforcing -Werror.)
>
> Fixes: d3d73f4b38a8 ("cxl: Compile with -Werror")
> Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Applied to powerpc next, thanks.
https://git.kernel.org/powerpc/c/57f7c3932516b9f7908d9b0a24
cheers
[toc] | [prev] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-01-12 13:40 +0100 |
| Subject | Re: [v2,1/2] cxl: fix build for GCC 4.6.x |
| Message-ID | <qQ6oX-Sx-29@gated-at.bofh.it> |
| In reply to | #1304875 |
On Fri, 2016-08-01 at 18:30:09 UTC, Brian Norris wrote:
> GCC 4.6.3 does not support -Wno-unused-const-variable. Instead, use the
> kbuild infrastructure that checks if this options exists.
>
> Fixes: 2cd55c68c0a4 ("cxl: Fix build failure due to -Wunused-variable behaviour change")
> Suggested-by: Michal Marek <mmarek@suse.com>
> Suggested-by: Arnd Bergmann <arnd@arndb.de>
> Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Applied to powerpc next, thanks.
https://git.kernel.org/powerpc/c/aa09545589ceeff884421d8eb3
cheers
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web