From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932333AbcARJ3h (ORCPT ); Mon, 18 Jan 2016 04:29:37 -0500 Received: from mx1.redhat.com ([209.132.183.28]:46846 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932076AbcARJYp (ORCPT ); Mon, 18 Jan 2016 04:24:45 -0500 From: Jiri Olsa To: Arnaldo Carvalho de Melo Cc: lkml , David Ahern , Ingo Molnar , Namhyung Kim , Peter Zijlstra Subject: [PATCH 08/26] perf report: Move ui initialization ahead of sort setup Date: Mon, 18 Jan 2016 10:24:06 +0100 Message-Id: <1453109064-1026-9-git-send-email-jolsa@kernel.org> In-Reply-To: <1453109064-1026-1-git-send-email-jolsa@kernel.org> References: <1453109064-1026-1-git-send-email-jolsa@kernel.org> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The ui initialization changes hpp format callbacks, based on the used browser. Thus we need this init being processed before setup_sorting. Link: http://lkml.kernel.org/n/tip-8gngyjsfyua3dh3eifxgb980@git.kernel.org Signed-off-by: Jiri Olsa --- tools/perf/builtin-report.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/tools/perf/builtin-report.c b/tools/perf/builtin-report.c index 2fe654dd8d2b..0aa0fd3b4aa7 100644 --- a/tools/perf/builtin-report.c +++ b/tools/perf/builtin-report.c @@ -907,15 +907,6 @@ repeat: symbol_conf.cumulate_callchain = false; } - if (setup_sorting(session->evlist) < 0) { - if (sort_order) - parse_options_usage(report_usage, options, "s", 1); - if (field_order) - parse_options_usage(sort_order ? NULL : report_usage, - options, "F", 1); - goto error; - } - /* Force tty output for header output and per-thread stat. */ if (report.header || report.header_only || report.show_threads) use_browser = 0; @@ -925,6 +916,15 @@ repeat: else use_browser = 0; + if (setup_sorting(session->evlist) < 0) { + if (sort_order) + parse_options_usage(report_usage, options, "s", 1); + if (field_order) + parse_options_usage(sort_order ? NULL : report_usage, + options, "F", 1); + goto error; + } + if (report.header || report.header_only) { perf_session__fprintf_info(session, stdout, report.show_full_info); -- 2.4.3