From: Peter Zijlstra <peterz@infradead.org>
To: Qi Liu <liuqi@hygon.cn>
Cc: mingo@redhat.com, namhyung@kernel.org,
alexander.shishkin@linux.intel.com, jolsa@kernel.org,
x86@kernel.org, linux-perf-users@vger.kernel.org,
linux-kernel@vger.kernel.org, lijing@hygon.cn,
Zhenglang Hu <huzhenglang@hygon.cn>
Subject: Re: [PATCH 1/3] perf/x86/amd/uncore: Add common PMU helper functions
Date: Wed, 1 Jul 2026 09:00:13 +0200 [thread overview]
Message-ID: <20260701070013.GJ48970@noisy.programming.kicks-ass.net> (raw)
In-Reply-To: <20260701034413.718872-2-liuqi@hygon.cn>
On Wed, Jul 01, 2026 at 03:44:11AM +0000, Qi Liu wrote:
> Add common helper functions for AMD-family uncore PMU handling.
>
> The helpers cover event initialization, counter allocation, counter
> read/update, event start/stop and per-CPU context management. These
> paths are not tied to a specific uncore unit and can be reused by
> drivers with a similar uncore PMU programming model.
>
> Signed-off-by: Qi Liu <liuqi@hygon.cn>
> Tested-by: Zhenglang Hu <huzhenglang@hygon.cn>
> +EXPORT_SYMBOL_GPL(uncore_common_set_update_interval);
> +EXPORT_SYMBOL_GPL(event_to_uncore_common_pmu);
> +EXPORT_SYMBOL_GPL(uncore_common_attr_group);
> +EXPORT_SYMBOL_GPL(uncore_common_start_hrtimer);
> +EXPORT_SYMBOL_GPL(uncore_common_read);
> +EXPORT_SYMBOL_GPL(uncore_common_start);
> +EXPORT_SYMBOL_GPL(uncore_common_stop);
> +EXPORT_SYMBOL_GPL(uncore_common_event_init);
> +EXPORT_SYMBOL_GPL(uncore_common_add);
> +EXPORT_SYMBOL_GPL(uncore_common_del);
> +EXPORT_SYMBOL_GPL(uncore_common_ctx_init);
> +EXPORT_SYMBOL_GPL(uncore_common_ctx_free);
> +EXPORT_SYMBOL_GPL(uncore_common_ctx_move);
I like the idea, but I don't particularly like the namespace.
'uncore_common' is too generic, there are a ton of uncore drivers, even
on x86 and these functions are specific to the AMD family. That is, they
aren't really common at all.
next prev parent reply other threads:[~2026-07-01 7:00 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-01 3:44 [PATCH 0/3] perf/x86/amd/uncore: Add common helpers and Hygon support Qi Liu
2026-07-01 3:44 ` [PATCH 1/3] perf/x86/amd/uncore: Add common PMU helper functions Qi Liu
2026-07-01 4:04 ` sashiko-bot
2026-07-01 7:00 ` Peter Zijlstra [this message]
2026-07-01 7:50 ` 答复: " Qi Liu
2026-07-01 7:51 ` Peter Zijlstra
2026-07-01 7:55 ` 答复: " Qi Liu
2026-07-01 3:44 ` [PATCH 2/3] perf/x86/amd/uncore: Convert AMD driver to common PMU helpers Qi Liu
2026-07-01 4:00 ` sashiko-bot
2026-07-01 3:44 ` [PATCH 3/3] perf/x86/amd/uncore: Add Hygon uncore PMU support Qi Liu
2026-07-01 3:56 ` sashiko-bot
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=20260701070013.GJ48970@noisy.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=alexander.shishkin@linux.intel.com \
--cc=huzhenglang@hygon.cn \
--cc=jolsa@kernel.org \
--cc=lijing@hygon.cn \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=liuqi@hygon.cn \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=x86@kernel.org \
/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