All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shyam Sundar S K <Shyam-sundar.S-k@amd.com>
To: "Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>,
	"Mario Limonciello" <mario.limonciello@amd.com>
Cc: Hans de Goede <hansg@kernel.org>,
	platform-driver-x86@vger.kernel.org, Patil.Reddy@amd.com,
	lizhi.hou@amd.com, VinitKumar Shukla <VinitKumar.Shukla@amd.com>
Subject: Re: [PATCH v2 5/5] accel/amdxdna: Provide real-time NPU power estimate via AMD PMF
Date: Tue, 18 Nov 2025 22:16:29 +0530	[thread overview]
Message-ID: <bb72ff10-b9e0-47a6-8985-a68efcf204ae@amd.com> (raw)
In-Reply-To: <09397827-4233-77d6-ab17-dfe0ae5f1cfe@linux.intel.com>



On 11/18/2025 21:31, Ilpo Järvinen wrote:
> On Tue, 18 Nov 2025, Ilpo Järvinen wrote:
> 
>> On Fri, 14 Nov 2025, Mario Limonciello wrote:
>>> On 11/13/2025 1:33 AM, Shyam Sundar S K wrote:
>>>> On 11/12/2025 23:33, Mario Limonciello wrote:
>>>>> On 11/11/25 12:37 AM, Shyam Sundar S K wrote:
>>>>>> From: VinitKumar Shukla <VinitKumar.Shukla@amd.com>
>>>>>>
>>>>>> Add aie2_smu_get_power_estimate() to obtain NPU power readings from the
>>>>>> AMD PMF driver. This xdna interface enables user space to reflect
>>>>>> current
>>>>>> workload power consumption in real time.
>>>>>
>>>>> But.. it doesn't.  It just adds a new function that could potentially
>>>>> do this job.  The actual gluing it to userspace in some way to use
>>>>> this function will be another patch.
>>>>
>>>> For now, yes.. that's right. XDNA team will add more support on it
>>>> that goes via the accel tree. But this patch is meant to have a
>>>> minimal change on the xdna side so that there is a  consumer of the
>>>> pmf symbol that is getting exported to the kernel.
>>>>
>>>> So, there is more support coming on the way. If you think, its worth
>>>> to rephrase the commit?
>>>
>>> Yes; that other support isn't happening this kernel cycle.  So the commit
>>> message should be accurate to what it's actually doing (laying ground work).
>>
>> To me it looks this and patch 4 should be submitted with the actual user 
>> instead of trying to justify things with far in the future changes. I've 
>> no problem with creating immutable branch if necessary when multiple trees 
>> are involved.
> 
> In case it wasn't obvious, I'm fine with taking patches 1-3 in earlier.
> 

The context for this series is that the XDNA driver needs
power-related information, which is only available from the PMF
driver. We’re providing that information via an exported symbol.

Patch 4 exports the data and patch 5 begins consuming it. The goal is
to establish the channel through which power-related information can flow.

Creating an immutable branch is a reasonable idea, but in this case
all further PMF-side work stops after this patch. The subsequent
activity is primarily on the XDNA side — for example, passing the
power data into the XRT environment via IOCTLs. If both trees had
active development or large, simultaneous changes, an immutable branch
would make sense, but given the current situation it doesn’t seem
worth the added complexity.

The XDNA changes are distributed and will be implemented gradually;
they depend on this exported power information from PMF. So my
proposal is for PMF to export the information now with minimal changes
on the XDNA side, and land that upstream. The XDNA team can then build
on top of the exported interface, and their changes can be submitted
via the misc-drm tree.

Ilpo, does this approach work for you?

Thanks,
Shyam

  reply	other threads:[~2025-11-18 16:46 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-11  6:37 [PATCH v2 0/5] PMF NPU metrics cleanup, command flag cleanup, and amdxdna integration Shyam Sundar S K
2025-11-11  6:37 ` [PATCH v2 1/5] platform/x86/amd/pmf: Rename IPU metrics fields to NPU for consistency Shyam Sundar S K
2025-11-18 15:36   ` Ilpo Järvinen
2025-11-11  6:37 ` [PATCH v2 2/5] platform/x86/amd/pmf: Use explicit SET_CMD/GET_CMD flags in amd_pmf_send_cmd() Shyam Sundar S K
2025-11-18 15:41   ` Ilpo Järvinen
2025-11-18 17:03     ` Shyam Sundar S K
2025-11-18 17:08       ` Ilpo Järvinen
2025-11-11  6:37 ` [PATCH v2 3/5] platform/x86/amd/pmf: replace magic table id with METRICS_TABLE_ID Shyam Sundar S K
2025-11-18 15:44   ` Ilpo Järvinen
2025-11-11  6:37 ` [PATCH v2 4/5] platform/x86/amd/pmf: Introduce new interface to export NPU metrics Shyam Sundar S K
2025-11-18 15:54   ` Ilpo Järvinen
2025-11-11  6:37 ` [PATCH v2 5/5] accel/amdxdna: Provide real-time NPU power estimate via AMD PMF Shyam Sundar S K
2025-11-12 18:03   ` Mario Limonciello
2025-11-13  7:33     ` Shyam Sundar S K
2025-11-14 16:56       ` Mario Limonciello
2025-11-18 15:59         ` Ilpo Järvinen
2025-11-18 16:01           ` Ilpo Järvinen
2025-11-18 16:46             ` Shyam Sundar S K [this message]
2025-11-19 12:44               ` Ilpo Järvinen
2025-11-20 10:55                 ` Shyam Sundar S K
2025-11-12 17:21 ` [PATCH v2 0/5] PMF NPU metrics cleanup, command flag cleanup, and amdxdna integration Mario Limonciello
2025-11-13  7:37   ` Shyam Sundar S K

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=bb72ff10-b9e0-47a6-8985-a68efcf204ae@amd.com \
    --to=shyam-sundar.s-k@amd.com \
    --cc=Patil.Reddy@amd.com \
    --cc=VinitKumar.Shukla@amd.com \
    --cc=hansg@kernel.org \
    --cc=ilpo.jarvinen@linux.intel.com \
    --cc=lizhi.hou@amd.com \
    --cc=mario.limonciello@amd.com \
    --cc=platform-driver-x86@vger.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.