linux-perf-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH -next] perf kwork top: Simplify bool conversion
@ 2023-09-15  6:38 Yang Li
  2023-09-21 18:49 ` Namhyung Kim
  0 siblings, 1 reply; 2+ messages in thread
From: Yang Li @ 2023-09-15  6:38 UTC (permalink / raw)
  To: peterz, mingo, acme, mark.rutland, alexander.shishkin, jolsa,
	namhyung, irogers, adrian.hunter
  Cc: linux-perf-users, linux-kernel, bpf, Yang Li

./tools/perf/util/bpf_kwork_top.c:120:53-58: WARNING: conversion to bool not needed here

Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
---
 tools/perf/util/bpf_kwork_top.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/perf/util/bpf_kwork_top.c b/tools/perf/util/bpf_kwork_top.c
index 1a607b94f44d..035e02272790 100644
--- a/tools/perf/util/bpf_kwork_top.c
+++ b/tools/perf/util/bpf_kwork_top.c
@@ -117,7 +117,7 @@ kwork_class_bpf_supported_list[KWORK_CLASS_MAX] = {
 
 static bool valid_kwork_class_type(enum kwork_class_type type)
 {
-	return type >= 0 && type < KWORK_CLASS_MAX ? true : false;
+	return type >= 0 && type < KWORK_CLASS_MAX;
 }
 
 static int setup_filters(struct perf_kwork *kwork)
-- 
2.20.1.7.g153144c


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH -next] perf kwork top: Simplify bool conversion
  2023-09-15  6:38 [PATCH -next] perf kwork top: Simplify bool conversion Yang Li
@ 2023-09-21 18:49 ` Namhyung Kim
  0 siblings, 0 replies; 2+ messages in thread
From: Namhyung Kim @ 2023-09-21 18:49 UTC (permalink / raw)
  To: Yang Li
  Cc: peterz, mingo, acme, mark.rutland, alexander.shishkin, jolsa,
	irogers, adrian.hunter, linux-perf-users, linux-kernel, bpf

On Thu, Sep 14, 2023 at 11:38 PM Yang Li <yang.lee@linux.alibaba.com> wrote:
>
> ./tools/perf/util/bpf_kwork_top.c:120:53-58: WARNING: conversion to bool not needed here
>
> Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>

Applied to perf-tools-next, thanks!

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-09-21 18:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-15  6:38 [PATCH -next] perf kwork top: Simplify bool conversion Yang Li
2023-09-21 18:49 ` Namhyung Kim

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).