From: Brian Norris Date: Fri, 8 Jan 2016 18:30:09 +0000 (-0800) Subject: cxl: fix build for GCC 4.6.x X-Git-Tag: Ubuntu-snapdragon-4.4.0-1050.54~5777 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=2d4657e7d9c8bb8737ac4278829cc6a56ef6db44;p=mirror_ubuntu-artful-kernel.git cxl: fix build for GCC 4.6.x 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 Suggested-by: Arnd Bergmann Signed-off-by: Brian Norris Signed-off-by: Michael Ellerman (cherry picked from commit aa09545589ceeff884421d8eb38d04963190afbe) Signed-off-by: Tim Gardner --- 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