[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3bf7f52c-80e2-470a-9225-36077a37d7d0@intel.com>
Date: Wed, 5 Nov 2025 16:09:28 -0800
From: Reinette Chatre <reinette.chatre@...el.com>
To: "Luck, Tony" <tony.luck@...el.com>, Dave Martin <Dave.Martin@....com>
CC: Fenghua Yu <fenghuay@...dia.com>, Maciej Wieczor-Retman
<maciej.wieczor-retman@...el.com>, Peter Newman <peternewman@...gle.com>,
James Morse <james.morse@....com>, Babu Moger <babu.moger@....com>, "Drew
Fustini" <dfustini@...libre.com>, Chen Yu <yu.c.chen@...el.com>,
<x86@...nel.org>, <linux-kernel@...r.kernel.org>, <patches@...ts.linux.dev>
Subject: Re: [PATCH v13 12/32] x86,fs/resctrl: Support binary fixed point
event counters
Hi Dave and Tony,
On 11/5/25 3:31 PM, Luck, Tony wrote:
> On Wed, Nov 05, 2025 at 02:42:18PM +0000, Dave Martin wrote:
>> On Wed, Oct 29, 2025 at 09:20:55AM -0700, Tony Luck wrote:
...
>>> diff --git a/fs/resctrl/internal.h b/fs/resctrl/internal.h
>>> index 40b76eaa33d0..f5189b6771a0 100644
>>> --- a/fs/resctrl/internal.h
>>> +++ b/fs/resctrl/internal.h
>>> @@ -62,6 +62,9 @@ static inline struct rdt_fs_context *rdt_fc2context(struct fs_context *fc)
>>> * Only valid if @evtid is an MBM event.
>>> * @configurable: true if the event is configurable
>>> * @any_cpu: true if the event can be read from any CPU
>>> + * @is_floating_point: event values are displayed in floating point format
>>
>> Nit: Maybe rebrand this as is_fixed_point, or is_fractional, or similar?
>>
>> The print syntax is just a decimal fraction, and the hardware
>> representation is fixed-point. Nothing floats.
>
> You are right. I can change from is_floating_point to is_fixed_point.
>
This is a fs property though, not hardware, and highlights that the value is displayed in
floating point format which is the closest resctrl has to establish a "contract" with user
space on what format user space can expect when reading the data as backed with a
matching update to resctrl.rst for the events that have this hardcoded by the fs.
Whether an architecture uses fixed point format or some other mechanism to determine the
value eventually exposed to user space is unique to the architecture.
Reinette
Powered by blists - more mailing lists