[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150407115915.GE11983@kernel.org>
Date: Tue, 7 Apr 2015 08:59:15 -0300
From: Arnaldo Carvalho de Melo <acme@...nel.org>
To: He Kuang <hekuang@...wei.com>
Cc: a.p.zijlstra@...llo.nl, mingo@...hat.com, jolsa@...nel.org,
wangnan0@...wei.com, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] perf evlist: Fix inverted logic in perf_mmap__empty
Em Tue, Apr 07, 2015 at 05:31:10PM +0800, He Kuang escreveu:
> perf_evlist__mmap_consume() uses perf_mmap__empty() to judge whether
> perf_mmap is empty and can be released. But the result is inverted so
> fix it.
> diff --git a/tools/perf/util/evlist.c b/tools/perf/util/evlist.c
> @@ -695,7 +695,7 @@ union perf_event *perf_evlist__mmap_read(struct perf_evlist *evlist, int idx)
>
> static bool perf_mmap__empty(struct perf_mmap *md)
> {
> - return perf_mmap__read_head(md) != md->prev;
> + return perf_mmap__read_head(md) == md->prev;
> }
>
> static void perf_evlist__mmap_get(struct perf_evlist *evlist, int idx)
Argh, thanks, good spotting, applying...
- Arnaldo
--
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