[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20220424090727.97865-1-wanjiabing@vivo.com>
Date: Sun, 24 Apr 2022 17:07:27 +0800
From: Wan Jiabing <wanjiabing@...o.com>
To: Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>,
Arnaldo Carvalho de Melo <acme@...nel.org>,
Mark Rutland <mark.rutland@....com>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Jiri Olsa <jolsa@...nel.org>,
Namhyung Kim <namhyung@...nel.org>,
linux-perf-users@...r.kernel.org, linux-kernel@...r.kernel.org
Cc: kael_w@...h.net, Wan Jiabing <wanjiabing@...o.com>
Subject: [PATCH] perf sched: simplify if-if to if-else
Use if and else instead of if(A) and if (!A).
Signed-off-by: Wan Jiabing <wanjiabing@...o.com>
---
tools/perf/builtin-sched.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/tools/perf/builtin-sched.c b/tools/perf/builtin-sched.c
index 646bd938927a..66f8e9318123 100644
--- a/tools/perf/builtin-sched.c
+++ b/tools/perf/builtin-sched.c
@@ -3070,8 +3070,7 @@ static int perf_sched__timehist(struct perf_sched *sched)
/* summary_only implies summary option, but don't overwrite summary if set */
if (sched->summary_only)
sched->summary = sched->summary_only;
-
- if (!sched->summary_only)
+ else
timehist_header(sched);
err = perf_session__process_events(session);
--
2.35.1
Powered by blists - more mailing lists