Selaa lähdekoodia

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 <mmarek@suse.com>
Suggested-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Brian Norris 9 vuotta sitten
vanhempi
commit
aa09545589
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1 1
      drivers/misc/cxl/Makefile

+ 1 - 1
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				+= main.o file.o irq.o fault.o native.o
 cxl-y				+= context.o sysfs.o debugfs.o pci.o trace.o
 cxl-y				+= context.o sysfs.o debugfs.o pci.o trace.o