lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <tip-85r40c5hhv6jnmph77l1hgsr@git.kernel.org>
Date:	Sat, 23 Apr 2016 06:00:36 -0700
From:	tip-bot for Arnaldo Carvalho de Melo <tipbot@...or.com>
To:	linux-tip-commits@...r.kernel.org
Cc:	mingo@...nel.org, wangnan0@...wei.com, milian.wolff@...b.com,
	hpa@...or.com, adrian.hunter@...el.com, acme@...hat.com,
	jolsa@...nel.org, linux-kernel@...r.kernel.org, tglx@...utronix.de,
	namhyung@...nel.org, dsahern@...il.com
Subject: [tip:perf/core] perf trace: Fix build when DWARF unwind isn't
 available

Commit-ID:  ccd62a896ffe3dbd60f3b7570a2b74e4fe030ed6
Gitweb:     http://git.kernel.org/tip/ccd62a896ffe3dbd60f3b7570a2b74e4fe030ed6
Author:     Arnaldo Carvalho de Melo <acme@...hat.com>
AuthorDate: Sat, 16 Apr 2016 09:36:32 -0300
Committer:  Arnaldo Carvalho de Melo <acme@...hat.com>
CommitDate: Sat, 16 Apr 2016 09:44:28 -0300

perf trace: Fix build when DWARF unwind isn't available

The variable is initialized and then conditionally set to a different
value, but not used when DWARF unwinding is not available, bummer, write
1000 times: "Run make -C tools/perf build-test"...

  builtin-trace.c: In function ‘cmd_trace’:
  builtin-trace.c:3112:6: error: variable ‘max_stack_user_set’ set but not
  used [-Werror=unused-but-set-variable]
    bool max_stack_user_set = true;
        ^
  cc1: all warnings being treated as err

Fix it by marking it as __maybe_unused.

Cc: Adrian Hunter <adrian.hunter@...el.com>
Cc: David Ahern <dsahern@...il.com>
Cc: Jiri Olsa <jolsa@...nel.org>
Cc: Milian Wolff <milian.wolff@...b.com>
Cc: Namhyung Kim <namhyung@...nel.org>
Cc: Wang Nan <wangnan0@...wei.com>
Fixes: 056149932602 ("perf trace: Make --(min,max}-stack imply "--call-graph dwarf"")
Link: http://lkml.kernel.org/n/tip-85r40c5hhv6jnmph77l1hgsr@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@...hat.com>
---
 tools/perf/builtin-trace.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
index 026ec0c..0e3c1ce 100644
--- a/tools/perf/builtin-trace.c
+++ b/tools/perf/builtin-trace.c
@@ -3109,7 +3109,7 @@ int cmd_trace(int argc, const char **argv, const char *prefix __maybe_unused)
 			"per thread proc mmap processing timeout in ms"),
 	OPT_END()
 	};
-	bool max_stack_user_set = true;
+	bool __maybe_unused max_stack_user_set = true;
 	bool mmap_pages_user_set = true;
 	const char * const trace_subcommands[] = { "record", NULL };
 	int err;

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ