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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <1416351627-360-1-git-send-email-tom.huynh@freescale.com>
Date:	Tue, 18 Nov 2014 17:00:27 -0600
From:	Tom Huynh <tom.huynh@...escale.com>
To:	<mingo@...hat.com>, <acme@...nel.org>, <namhyung@...nel.org>,
	<jolsa@...nel.org>
CC:	<a.p.zijlstra@...llo.nl>, <paulus@...ba.org>,
	<kim.phillips@...escale.com>, <linux-kernel@...r.kernel.org>,
	Tom Huynh <tom.huynh@...escale.com>
Subject: [PATCH] perf hist browser: change print format from lu to llu to fit u64 type

nr_events in tools/perf/ui/browsers/hists.c is of type u64, thus it should
be printed as %llu instead of %lu. The print format %lu causes perf report
to show 0 event count when running with 32-bit userspace without 
redirection. This patch fixes that problem.

Signed-off-by: Tom Huynh <tom.huynh@...escale.com>
---
 tools/perf/ui/browsers/hists.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
index cfb976b..49b2471 100644
--- a/tools/perf/ui/browsers/hists.c
+++ b/tools/perf/ui/browsers/hists.c
@@ -1254,7 +1254,7 @@ static int hists__browser_title(struct hists *hists,
 
 	nr_samples = convert_unit(nr_samples, &unit);
 	printed = scnprintf(bf, size,
-			   "Samples: %lu%c of event '%s', Event count (approx.): %lu",
+			   "Samples: %lu%c of event '%s', Event count (approx.): %llu",
 			   nr_samples, unit, ev_name, nr_events);
 
 
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ