Message ID | 20190715134514.23782-2-kleber.souza@canonical.com |
---|---|
State | New |
Headers | show |
Series | Fix perf build with libnuma (LP: #1836585) | expand |
On 15.07.19 15:45, Kleber Sacilotto de Souza wrote: > BugLink: https://bugs.launchpad.net/bugs/1836585 > > This reverts commit 54cba3ec59aff68031074b50af358ad2fc9b183a. > > Commit "UBUNTU: SAUCE: perf/bench: Drop definition of BIT in numa.c" is > causing build failures on tools/perf/bench after stable upstream commit > "perf tools: No need to include bitops.h in util.h" removed the > inclusion of the header file where the BIT() macro is defined. This > causes perf build failures when libnuma is installed. > > Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com> Acked-by: Stefan Bader <stefan.bader@canonical.com> > --- > tools/perf/bench/numa.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/tools/perf/bench/numa.c b/tools/perf/bench/numa.c > index 17372bb7af84..df41deed0320 100644 > --- a/tools/perf/bench/numa.c > +++ b/tools/perf/bench/numa.c > @@ -724,6 +724,8 @@ static int parse_nodes_opt(const struct option *opt __maybe_unused, > return 0; > } > > +#define BIT(x) (1ul << x) > + > static inline uint32_t lfsr_32(uint32_t lfsr) > { > const uint32_t taps = BIT(1) | BIT(5) | BIT(6) | BIT(31); >
diff --git a/tools/perf/bench/numa.c b/tools/perf/bench/numa.c index 17372bb7af84..df41deed0320 100644 --- a/tools/perf/bench/numa.c +++ b/tools/perf/bench/numa.c @@ -724,6 +724,8 @@ static int parse_nodes_opt(const struct option *opt __maybe_unused, return 0; } +#define BIT(x) (1ul << x) + static inline uint32_t lfsr_32(uint32_t lfsr) { const uint32_t taps = BIT(1) | BIT(5) | BIT(6) | BIT(31);
BugLink: https://bugs.launchpad.net/bugs/1836585 This reverts commit 54cba3ec59aff68031074b50af358ad2fc9b183a. Commit "UBUNTU: SAUCE: perf/bench: Drop definition of BIT in numa.c" is causing build failures on tools/perf/bench after stable upstream commit "perf tools: No need to include bitops.h in util.h" removed the inclusion of the header file where the BIT() macro is defined. This causes perf build failures when libnuma is installed. Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com> --- tools/perf/bench/numa.c | 2 ++ 1 file changed, 2 insertions(+)