Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7b39cafb authored by Ingo Molnar's avatar Ingo Molnar
Browse files

tools: Work around BITS_PER_LONG related build failure in objtool



The objtool build fails with the recent changes to the bits-per-long
headers:

  tools/include/linux/bitops.h:12:0: error: "BITS_PER_LONG" redefined [-Werror]

Which got introduced by:

  bb970707 tools: Copy the bitsperlong.h files from the kernel

Work it around for the time being.

Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
parent 68cf16c6
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -9,7 +9,9 @@
#define __WORDSIZE (__SIZEOF_LONG__ * 8)
#endif

#ifndef BITS_PER_LONG
# define BITS_PER_LONG __WORDSIZE
#endif

#define BIT_MASK(nr)		(1UL << ((nr) % BITS_PER_LONG))
#define BIT_WORD(nr)		((nr) / BITS_PER_LONG)