Skip to content

Commit be9c94c

Browse files
committed
Merge branch 'for-next/vdso' into for-next/core
* for-next/vdso: arm64: vdso32: Respect -Werror from kbuild arm64: vdso32: Stop suppressing warnings
2 parents 4e4e36d + 281817d commit be9c94c

1 file changed

Lines changed: 1 addition & 12 deletions

File tree

arch/arm64/kernel/vdso32/Makefile

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,6 @@ endif
2121

2222
cc32-option = $(call try-run,\
2323
$(CC_COMPAT) $(1) -c -x c /dev/null -o "$$TMP",$(1),$(2))
24-
cc32-disable-warning = $(call try-run,\
25-
$(CC_COMPAT) -W$(strip $(1)) -c -x c /dev/null -o "$$TMP",-Wno-$(strip $(1)))
2624

2725
# We cannot use the global flags to compile the vDSO files, the main reason
2826
# being that the 32-bit compiler may be older than the main (64-bit) compiler
@@ -63,6 +61,7 @@ VDSO_CFLAGS += -DENABLE_COMPAT_VDSO=1
6361
# KBUILD_CFLAGS from top-level Makefile
6462
VDSO_CFLAGS += -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs \
6563
-fno-strict-aliasing -fno-common \
64+
$(filter -Werror,$(KBUILD_CPPFLAGS)) \
6665
-Werror-implicit-function-declaration \
6766
-Wno-format-security \
6867
-std=gnu11
@@ -74,16 +73,6 @@ VDSO_CFLAGS += $(call cc32-option,-Werror=strict-prototypes)
7473
VDSO_CFLAGS += -Werror=date-time
7574
VDSO_CFLAGS += $(call cc32-option,-Werror=incompatible-pointer-types)
7675

77-
# The 32-bit compiler does not provide 128-bit integers, which are used in
78-
# some headers that are indirectly included from the vDSO code.
79-
# This hack makes the compiler happy and should trigger a warning/error if
80-
# variables of such type are referenced.
81-
VDSO_CFLAGS += -D__uint128_t='void*'
82-
# Silence some warnings coming from headers that operate on long's
83-
# (on GCC 4.8 or older, there is unfortunately no way to silence this warning)
84-
VDSO_CFLAGS += $(call cc32-disable-warning,shift-count-overflow)
85-
VDSO_CFLAGS += -Wno-int-to-pointer-cast
86-
8776
# Compile as THUMB2 or ARM. Unwinding via frame-pointers in THUMB2 is
8877
# unreliable.
8978
ifeq ($(CONFIG_THUMB2_COMPAT_VDSO), y)

0 commit comments

Comments
 (0)