diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2019-05-01 11:05:41 -0700 |
---|---|---|
committer | Seung-Woo Kim <sw0312.kim@samsung.com> | 2019-12-30 11:10:52 +0900 |
commit | 691680fbd3d24d419e10bfc2d4ca8afc8a4df7f4 (patch) | |
tree | 82099c8096de9b91ba3f9d613da9548c9a040f15 | |
parent | eebf6ad4295e729603416ab8189470e22aadf4b0 (diff) | |
download | linux-artik7-691680fbd3d24d419e10bfc2d4ca8afc8a4df7f4.tar.gz linux-artik7-691680fbd3d24d419e10bfc2d4ca8afc8a4df7f4.tar.bz2 linux-artik7-691680fbd3d24d419e10bfc2d4ca8afc8a4df7f4.zip |
gcc-9: silence 'address-of-packed-member' warning
commit 6f303d60534c46aa1a239f29c321f95c83dda748 upstream.
We already did this for clang, but now gcc has that warning too. Yes,
yes, the address may be unaligned. And that's kind of the point.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
[sw0312.kim: cherry-pick from stable linux-4.4.y commit 9efccd7745a1 for gcc 9 build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I1a6ea66a5214bed3371e92686b00f870e5c678f0
-rw-r--r-- | Makefile | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -636,6 +636,7 @@ KBUILD_CFLAGS += $(call cc-disable-warning,frame-address,) KBUILD_CFLAGS += $(call cc-disable-warning, format-truncation) KBUILD_CFLAGS += $(call cc-disable-warning, format-overflow) KBUILD_CFLAGS += $(call cc-disable-warning, int-in-bool-context) +KBUILD_CFLAGS += $(call cc-disable-warning, address-of-packed-member) KBUILD_CFLAGS += $(call cc-disable-warning, attribute-alias) ifdef CONFIG_CC_OPTIMIZE_FOR_SIZE @@ -712,7 +713,6 @@ ifeq ($(cc-name),clang) KBUILD_CPPFLAGS += $(call cc-option,-Qunused-arguments,) KBUILD_CFLAGS += $(call cc-disable-warning, format-invalid-specifier) KBUILD_CFLAGS += $(call cc-disable-warning, gnu) -KBUILD_CFLAGS += $(call cc-disable-warning, address-of-packed-member) # Quiet clang warning: comparison of unsigned expression < 0 is always false KBUILD_CFLAGS += $(call cc-disable-warning, tautological-compare) # CLANG uses a _MergedGlobals as optimization, but this breaks modpost, as the |