Skip to content
Commit 44929bfa authored by Masahiro Yamada's avatar Masahiro Yamada
Browse files

kbuild: remove GCC's default -Wpacked-bitfield-compat flag



Commit 4a5838ad ("kbuild: Add extra gcc checks") added the
-Wpacked-bitfield-compat flag, but there is no need to add it
explicitly.

GCC manual says:
  "This warning is enabled by default. Use -Wno-packed-bitfield-compat
   to disable this warning."

The test code in the manual:

  struct foo
  {
    char a:4;
    char b:8;
  } __attribute__ ((packed));

... emits "note: offset of packed bit-field ‘b’ has changed in GCC 4.4"
without W=3.

Let's remove it, as it is a default with GCC.

Clang does not support this flag, so its removal will not affect Clang
builds.

Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
Reviewed-by: default avatarNathan Chancellor <nathan@kernel.org>
parent e2bad142
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment