mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Namhyung Kim <namhyung@kernel.org>
To: peterz@infradead.org, acme@redhat.com, irogers@google.com,
	Junhao He <hejunhao3@huawei.com>
Cc: jonathan.cameron@huawei.com, yangyicong@huawei.com,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org, linuxarm@huawei.com,
	prime.zeng@hisilicon.com, adrian.hunter@intel.com,
	alexander.shishkin@linux.intel.com, cuigaosheng1@huawei.com,
	mingo@redhat.com, james.clark@arm.com,
	renyu.zj@linux.alibaba.com, jolsa@kernel.org,
	john.g.garry@oracle.com, kjain@linux.ibm.com,
	kan.liang@linux.intel.com, mark.rutland@arm.com,
	ravi.bangoria@amd.com, robh@kernel.org,
	linux-perf-users@vger.kernel.org
Subject: Re: [PATCH] perf pmus: Fixes always false when compare duplicates aliases
Date: Tue, 25 Jun 2024 21:01:46 -0700	[thread overview]
Message-ID: <171937447098.2860644.3823008923122929164.b4-ty@kernel.org> (raw)
In-Reply-To: <20240614094318.11607-1-hejunhao3@huawei.com>

On Fri, 14 Jun 2024 17:43:18 +0800, Junhao He wrote:

> In the previous loop, all the members in the aliases[j-1] have been freed
> and set to NULL. But in this loop, the function pmu_alias_is_duplicate()
> compares the aliases[j] with the aliases[j-1] that has already been
> disposed, so the function will always return false and duplicate aliases
> will never be discarded.
> 
> If we find duplicate aliases, it skips the zfree aliases[j], which is
> accompanied by a memory leak.
> 
> [...]

Applied to perf-tools-next, thanks!

Best regards,
Namhyung

      reply	other threads:[~2024-06-26  4:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-14  9:43 Junhao He
2024-06-26  4:01 ` Namhyung Kim [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=171937447098.2860644.3823008923122929164.b4-ty@kernel.org \
    --to=namhyung@kernel.org \
    --cc=acme@redhat.com \
    --cc=adrian.hunter@intel.com \
    --cc=alexander.shishkin@linux.intel.com \
    --cc=cuigaosheng1@huawei.com \
    --cc=hejunhao3@huawei.com \
    --cc=irogers@google.com \
    --cc=james.clark@arm.com \
    --cc=john.g.garry@oracle.com \
    --cc=jolsa@kernel.org \
    --cc=jonathan.cameron@huawei.com \
    --cc=kan.liang@linux.intel.com \
    --cc=kjain@linux.ibm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=linuxarm@huawei.com \
    --cc=mark.rutland@arm.com \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=prime.zeng@hisilicon.com \
    --cc=ravi.bangoria@amd.com \
    --cc=renyu.zj@linux.alibaba.com \
    --cc=robh@kernel.org \
    --cc=yangyicong@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®