From: Drew Fustini <fustini@kernel.org>
To: yunhui cui <cuiyunhui@bytedance.com>
Cc: "Paul Walmsley" <pjw@kernel.org>,
"Palmer Dabbelt" <palmer@dabbelt.com>,
"Albert Ou" <aou@eecs.berkeley.edu>,
"Alexandre Ghiti" <alex@ghiti.fr>,
"Radim Krčmář" <rkrcmar@ventanamicro.com>,
"Samuel Holland" <samuel.holland@sifive.com>,
"Adrien Ricciardi" <aricciardi@baylibre.com>,
"Nicolas Pitre" <npitre@baylibre.com>,
"Kornel Dulęba" <mindal@semihalf.com>,
"Atish Patra" <atish.patra@linux.dev>,
"Atish Kumar Patra" <atishp@rivosinc.com>,
"Vasudevan Srinivasan" <vasu@rivosinc.com>,
"Ved Shanbhogue" <ved@rivosinc.com>,
"Chen Pei" <cp0613@linux.alibaba.com>,
"Liu Zhiwei" <zhiwei_liu@linux.alibaba.com>,
"Weiwei Li" <liwei1518@gmail.com>,
guo.wenjia23@zte.com.cn, liu.qingtao2@zte.com.cn,
"Reinette Chatre" <reinette.chatre@intel.com>,
"Tony Luck" <tony.luck@intel.com>,
"Babu Moger" <babu.moger@amd.com>,
"Peter Newman" <peternewman@google.com>,
"Fenghua Yu" <fenghua.yu@intel.com>,
"James Morse" <james.morse@arm.com>,
"Ben Horgan" <ben.horgan@arm.com>,
"Dave Martin" <Dave.Martin@arm.com>,
linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org,
x86@kernel.org, "Rob Herring" <robh@kernel.org>,
"Rafael J. Wysocki" <rafael@kernel.org>,
"Len Brown" <lenb@kernel.org>,
"Robert Moore" <robert.moore@intel.com>,
"Sunil V L" <sunilvl@ventanamicro.com>,
"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
"Conor Dooley" <conor+dt@kernel.org>,
"Paul Walmsley" <paul.walmsley@sifive.com>,
linux-acpi@vger.kernel.org, acpica-devel@lists.linux.dev,
devicetree@vger.kernel.org
Subject: Re: [External] [PATCH RFC v2 06/17] RISC-V: QoS: define CBQRI resctrl resources and domains
Date: Sat, 28 Mar 2026 22:58:28 -0700 [thread overview]
Message-ID: <aci_hDY4JB9zNTci@gen8> (raw)
In-Reply-To: <CAEEQ3w=zV1k+uea5D9tnO=O5X5LQUpyNVZi8V8TOANxXJQbg=w@mail.gmail.com>
On Thu, Mar 26, 2026 at 04:32:47PM +0800, yunhui cui wrote:
> Hi Drew,
>
> On Wed, Mar 25, 2026 at 2:49 PM Drew Fustini <fustini@kernel.org> wrote:
> >
> > On Wed, Mar 25, 2026 at 10:31:39AM +0800, yunhui cui wrote:
> > > Hi Drew,
> > >
> > > On Thu, Jan 29, 2026 at 4:28 AM Drew Fustini <fustini@kernel.org> wrote:
> > > >
> > > > Define data structures to encapsulate the resctrl resource
> > > > and domain structures.
> > > >
> > > > Co-developed-by: Adrien Ricciardi <aricciardi@baylibre.com>
> > > > Signed-off-by: Adrien Ricciardi <aricciardi@baylibre.com>
> > > > [fustini: rebased current upstream]
> > > > Signed-off-by: Drew Fustini <fustini@kernel.org>
> > > > ---
> > > > arch/riscv/kernel/qos/internal.h | 27 +++++++++++++++++++++++++++
> > > > 1 file changed, 27 insertions(+)
> > > >
> > > > diff --git a/arch/riscv/kernel/qos/internal.h b/arch/riscv/kernel/qos/internal.h
> > > > index ff2c7eff50be..c0402dd06cfa 100644
> > > > --- a/arch/riscv/kernel/qos/internal.h
> > > > +++ b/arch/riscv/kernel/qos/internal.h
> > > > @@ -65,6 +65,11 @@
> > > > #define CBQRI_BC_ALLOC_CTL_OP_READ_LIMIT 2
> > > > #define CBQRI_BC_ALLOC_CTL_STATUS_SUCCESS 1
> > > >
> > > > +int qos_resctrl_setup(void);
> > > > +void qos_resctrl_exit(void);
> > > > +int qos_resctrl_online_cpu(unsigned int cpu);
> > > > +int qos_resctrl_offline_cpu(unsigned int cpu);
> > > > +
> > > > /* Capacity Controller hardware capabilities */
> > > > struct riscv_cbqri_capacity_caps {
> > > > u16 ncblks; /* number of capacity blocks */
> > > > @@ -125,4 +130,26 @@ struct cbqri_controller {
> > > > bool mon_capable;
> > > > };
> > > >
> > > > +struct cbqri_resctrl_res {
> > > > + struct rdt_resource resctrl_res;
> > > > + struct cbqri_controller controller;
> > > > + u32 max_rcid;
> > > > + u32 max_mcid;
> > > > +};
> > > > +
> > > > +struct cbqri_resctrl_dom {
> > > > + struct rdt_domain_hdr resctrl_dom_hdr;
> > > > + struct rdt_ctrl_domain resctrl_ctrl_dom;
> > > > + struct rdt_mon_domain resctrl_mon_dom;
> > > > + u64 cbm;
> > > > + u64 rbwb;
> > > > + u64 *ctrl_val;
> > > > + struct cbqri_controller *hw_ctrl;
> > > > +};
> > > > +
> > >
> > > Can we trim down some fields? For example:
> > > struct cbqri_resctrl_res {
> > > struct rdt_resource resctrl_res;
> > > - struct cbqri_controller controller;
> > > u32 max_rcid;
> > > u32 max_mcid;
> > > };
> > >
> > > struct cbqri_resctrl_dom {
> > > - struct rdt_domain_hdr resctrl_dom_hdr;
> > > struct rdt_ctrl_domain resctrl_ctrl_dom;
> > > struct rdt_mon_domain resctrl_mon_dom;
> > > - u64 cbm;
> > > - u64 rbwb;
> > > u64 *ctrl_val;
> > > struct cbqri_controller *hw_ctrl;
> > > };
> >
> > Can you explain why you don't think these are needed??
>
> The functionality works well without those fields, feel free to try.
Thanks for pointing this out. I have removed them.
> Btw, when do you plan to send the next revision?
The current branch is based on 6.19 so I need to rebase. I have
addressesd most of the feedback so far except for tracking default
closid/rmid for a cpu. I am thinking I should send a new version as it
has been a long time and describe the open items that I have not solved
yet.
Thanks,
Drew
WARNING: multiple messages have this Message-ID (diff)
From: Drew Fustini <fustini@kernel.org>
To: yunhui cui <cuiyunhui@bytedance.com>
Cc: "Atish Patra" <atish.patra@linux.dev>,
"Adrien Ricciardi" <aricciardi@baylibre.com>,
"Atish Kumar Patra" <atishp@rivosinc.com>,
"Conor Dooley" <conor+dt@kernel.org>,
"Nicolas Pitre" <npitre@baylibre.com>,
devicetree@vger.kernel.org,
"Liu Zhiwei" <zhiwei_liu@linux.alibaba.com>,
guo.wenjia23@zte.com.cn, linux-riscv@lists.infradead.org,
"Rob Herring" <robh@kernel.org>,
"Peter Newman" <peternewman@google.com>,
x86@kernel.org, acpica-devel@lists.linux.dev,
"Robert Moore" <robert.moore@intel.com>,
liu.qingtao2@zte.com.cn, linux-acpi@vger.kernel.org,
"Ben Horgan" <ben.horgan@arm.com>,
"James Morse" <james.morse@arm.com>,
"Radim Krčmář" <rkrcmar@ventanamicro.com>,
"Dave Martin" <Dave.Martin@arm.com>,
"Len Brown" <lenb@kernel.org>,
"Fenghua Yu" <fenghua.yu@intel.com>,
"Chen Pei" <cp0613@linux.alibaba.com>,
"Albert Ou" <aou@eecs.berkeley.edu>,
"Kornel Dulęba" <mindal@semihalf.com>,
"Babu Moger" <babu.moger@amd.com>,
"Weiwei Li" <liwei1518@gmail.com>,
"Paul Walmsley" <paul.walmsley@sifive.com>,
"Ved Shanbhogue" <ved@rivosinc.com>,
"Reinette Chatre" <reinette.chatre@intel.com>,
"Vasudevan Srinivasan" <vasu@rivosinc.com>,
"Tony Luck" <tony.luck@intel.com>,
"Alexandre Ghiti" <alex@ghiti.fr>,
linux-kernel@vger.kernel.org,
"Samuel Holland" <samuel.holland@sifive.com>,
"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
"Palmer Dabbelt" <palmer@dabbelt.com>,
"Rafael J. Wysocki" <rafael@kernel.org>,
"Paul Walmsley" <pjw@kernel.org>
Subject: Re: [External] [PATCH RFC v2 06/17] RISC-V: QoS: define CBQRI resctrl resources and domains
Date: Sat, 28 Mar 2026 22:58:28 -0700 [thread overview]
Message-ID: <aci_hDY4JB9zNTci@gen8> (raw)
In-Reply-To: <CAEEQ3w=zV1k+uea5D9tnO=O5X5LQUpyNVZi8V8TOANxXJQbg=w@mail.gmail.com>
On Thu, Mar 26, 2026 at 04:32:47PM +0800, yunhui cui wrote:
> Hi Drew,
>
> On Wed, Mar 25, 2026 at 2:49 PM Drew Fustini <fustini@kernel.org> wrote:
> >
> > On Wed, Mar 25, 2026 at 10:31:39AM +0800, yunhui cui wrote:
> > > Hi Drew,
> > >
> > > On Thu, Jan 29, 2026 at 4:28 AM Drew Fustini <fustini@kernel.org> wrote:
> > > >
> > > > Define data structures to encapsulate the resctrl resource
> > > > and domain structures.
> > > >
> > > > Co-developed-by: Adrien Ricciardi <aricciardi@baylibre.com>
> > > > Signed-off-by: Adrien Ricciardi <aricciardi@baylibre.com>
> > > > [fustini: rebased current upstream]
> > > > Signed-off-by: Drew Fustini <fustini@kernel.org>
> > > > ---
> > > > arch/riscv/kernel/qos/internal.h | 27 +++++++++++++++++++++++++++
> > > > 1 file changed, 27 insertions(+)
> > > >
> > > > diff --git a/arch/riscv/kernel/qos/internal.h b/arch/riscv/kernel/qos/internal.h
> > > > index ff2c7eff50be..c0402dd06cfa 100644
> > > > --- a/arch/riscv/kernel/qos/internal.h
> > > > +++ b/arch/riscv/kernel/qos/internal.h
> > > > @@ -65,6 +65,11 @@
> > > > #define CBQRI_BC_ALLOC_CTL_OP_READ_LIMIT 2
> > > > #define CBQRI_BC_ALLOC_CTL_STATUS_SUCCESS 1
> > > >
> > > > +int qos_resctrl_setup(void);
> > > > +void qos_resctrl_exit(void);
> > > > +int qos_resctrl_online_cpu(unsigned int cpu);
> > > > +int qos_resctrl_offline_cpu(unsigned int cpu);
> > > > +
> > > > /* Capacity Controller hardware capabilities */
> > > > struct riscv_cbqri_capacity_caps {
> > > > u16 ncblks; /* number of capacity blocks */
> > > > @@ -125,4 +130,26 @@ struct cbqri_controller {
> > > > bool mon_capable;
> > > > };
> > > >
> > > > +struct cbqri_resctrl_res {
> > > > + struct rdt_resource resctrl_res;
> > > > + struct cbqri_controller controller;
> > > > + u32 max_rcid;
> > > > + u32 max_mcid;
> > > > +};
> > > > +
> > > > +struct cbqri_resctrl_dom {
> > > > + struct rdt_domain_hdr resctrl_dom_hdr;
> > > > + struct rdt_ctrl_domain resctrl_ctrl_dom;
> > > > + struct rdt_mon_domain resctrl_mon_dom;
> > > > + u64 cbm;
> > > > + u64 rbwb;
> > > > + u64 *ctrl_val;
> > > > + struct cbqri_controller *hw_ctrl;
> > > > +};
> > > > +
> > >
> > > Can we trim down some fields? For example:
> > > struct cbqri_resctrl_res {
> > > struct rdt_resource resctrl_res;
> > > - struct cbqri_controller controller;
> > > u32 max_rcid;
> > > u32 max_mcid;
> > > };
> > >
> > > struct cbqri_resctrl_dom {
> > > - struct rdt_domain_hdr resctrl_dom_hdr;
> > > struct rdt_ctrl_domain resctrl_ctrl_dom;
> > > struct rdt_mon_domain resctrl_mon_dom;
> > > - u64 cbm;
> > > - u64 rbwb;
> > > u64 *ctrl_val;
> > > struct cbqri_controller *hw_ctrl;
> > > };
> >
> > Can you explain why you don't think these are needed??
>
> The functionality works well without those fields, feel free to try.
Thanks for pointing this out. I have removed them.
> Btw, when do you plan to send the next revision?
The current branch is based on 6.19 so I need to rebase. I have
addressesd most of the feedback so far except for tracking default
closid/rmid for a cpu. I am thinking I should send a new version as it
has been a long time and describe the open items that I have not solved
yet.
Thanks,
Drew
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
next prev parent reply other threads:[~2026-03-29 5:58 UTC|newest]
Thread overview: 120+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-28 20:27 [PATCH RFC v2 00/17] RISC-V: QoS: add CBQRI resctrl interface Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 01/17] dt-bindings: riscv: Add Ssqosid extension description Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 02/17] RISC-V: Detect the Ssqosid extension Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 03/17] RISC-V: Add support for srmcfg CSR from Ssqosid ext Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-02-02 3:17 ` [External] " yunhui cui
2026-02-02 3:17 ` yunhui cui
2026-02-08 1:31 ` Drew Fustini
2026-02-08 1:31 ` Drew Fustini
2026-02-09 3:36 ` yunhui cui
2026-02-09 3:36 ` yunhui cui
2026-02-02 4:27 ` yunhui cui
2026-02-02 4:27 ` yunhui cui
2026-02-03 19:43 ` Drew Fustini
2026-02-03 19:43 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 04/17] RISC-V: QoS: define properties of CBQRI controllers Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 05/17] RISC-V: QoS: define CBQRI capacity and bandwidth capabilities Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-02-13 23:13 ` Reinette Chatre
2026-02-13 23:13 ` Reinette Chatre
2026-02-14 16:25 ` Drew Fustini
2026-02-14 16:25 ` Drew Fustini
2026-02-17 16:32 ` Reinette Chatre
2026-02-17 16:32 ` Reinette Chatre
2026-02-17 18:28 ` Drew Fustini
2026-02-17 18:28 ` Drew Fustini
2026-02-17 19:02 ` Reinette Chatre
2026-02-17 19:02 ` Reinette Chatre
2026-02-17 22:36 ` Drew Fustini
2026-02-17 22:36 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 06/17] RISC-V: QoS: define CBQRI resctrl resources and domains Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-02-13 23:15 ` Reinette Chatre
2026-02-13 23:15 ` Reinette Chatre
2026-02-14 16:34 ` Drew Fustini
2026-02-14 16:34 ` Drew Fustini
2026-03-25 2:31 ` [External] " yunhui cui
2026-03-25 2:31 ` yunhui cui
2026-03-25 6:49 ` Drew Fustini
2026-03-25 6:49 ` Drew Fustini
2026-03-26 8:32 ` yunhui cui
2026-03-26 8:32 ` yunhui cui
2026-03-29 5:58 ` Drew Fustini [this message]
2026-03-29 5:58 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 07/17] RISC-V: QoS: define prototypes for resctrl interface Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-02-13 23:21 ` Reinette Chatre
2026-02-13 23:21 ` Reinette Chatre
2026-01-28 20:27 ` [PATCH RFC v2 08/17] RISC-V: QoS: add resctrl interface for CBQRI controllers Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-02-02 4:12 ` [External] " yunhui cui
2026-02-02 4:12 ` yunhui cui
2026-02-20 19:54 ` Drew Fustini
2026-02-20 19:54 ` Drew Fustini
2026-02-09 7:20 ` Gong Shuai
2026-02-09 10:07 ` Gong Shuai
2026-02-09 14:16 ` Gong Shuai
2026-02-09 14:16 ` Gong Shuai
2026-02-11 0:57 ` Drew Fustini
2026-02-11 0:57 ` Drew Fustini
2026-02-13 23:30 ` Reinette Chatre
2026-02-13 23:30 ` Reinette Chatre
2026-02-18 21:49 ` Drew Fustini
2026-02-18 21:49 ` Drew Fustini
2026-02-18 23:18 ` Reinette Chatre
2026-02-18 23:18 ` Reinette Chatre
2026-03-25 2:09 ` [External] " yunhui cui
2026-03-25 2:09 ` yunhui cui
2026-03-25 6:37 ` Drew Fustini
2026-03-25 6:37 ` Drew Fustini
2026-03-29 10:27 ` guo.wenjia23
2026-03-29 10:27 ` guo.wenjia23
2026-03-31 17:48 ` Radim Krčmář
2026-03-31 17:48 ` Radim Krčmář
2026-04-02 2:44 ` Drew Fustini
2026-04-02 2:44 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 09/17] RISC-V: QoS: expose implementation to resctrl Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 10/17] RISC-V: QoS: add late_initcall to setup resctrl interface Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 11/17] RISC-V: QoS: add to build when CONFIG_RISCV_ISA_SSQOSID set Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 12/17] RISC-V: QoS: make CONFIG_RISCV_ISA_SSQOSID select resctrl Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 13/17] acpi: pptt: Add helper to find a cache from id Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-03-25 1:34 ` [External] " yunhui cui
2026-03-25 1:34 ` yunhui cui
2026-01-28 20:27 ` [PATCH RFC v2 14/17] include: acpi: actbl2: Add structs for RQSC table Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-01-28 20:31 ` Rafael J. Wysocki
2026-01-28 20:31 ` Rafael J. Wysocki
2026-01-28 20:44 ` Drew Fustini
2026-01-28 20:44 ` Drew Fustini
2026-01-28 20:50 ` Rafael J. Wysocki
2026-01-28 20:50 ` Rafael J. Wysocki
2026-03-25 1:43 ` [External] " yunhui cui
2026-03-25 1:43 ` yunhui cui
2026-03-25 7:09 ` Drew Fustini
2026-03-25 7:09 ` Drew Fustini
2026-03-25 1:48 ` yunhui cui
2026-03-25 1:48 ` yunhui cui
2026-03-25 7:14 ` Drew Fustini
2026-03-25 7:14 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 15/17] RISC-V: QoS: add Cache ID and Prox Dom to CBQRI controllers Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 16/17] acpi: riscv: Parse RISC-V Quality of Service Controller (RQSC) table Drew Fustini
2026-01-28 20:27 ` Drew Fustini
2026-02-02 11:08 ` [External] " yunhui cui
2026-02-02 11:08 ` yunhui cui
2026-02-03 20:00 ` Drew Fustini
2026-02-03 20:00 ` Drew Fustini
2026-02-14 4:48 ` Drew Fustini
2026-02-14 4:48 ` Drew Fustini
2026-01-28 20:27 ` [PATCH RFC v2 17/17] acpi: riscv: Add support for RISC-V Quality of Service Controller (RQSC) Drew Fustini
2026-01-28 20:27 ` Drew Fustini
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=aci_hDY4JB9zNTci@gen8 \
--to=fustini@kernel.org \
--cc=Dave.Martin@arm.com \
--cc=acpica-devel@lists.linux.dev \
--cc=alex@ghiti.fr \
--cc=aou@eecs.berkeley.edu \
--cc=aricciardi@baylibre.com \
--cc=atish.patra@linux.dev \
--cc=atishp@rivosinc.com \
--cc=babu.moger@amd.com \
--cc=ben.horgan@arm.com \
--cc=conor+dt@kernel.org \
--cc=cp0613@linux.alibaba.com \
--cc=cuiyunhui@bytedance.com \
--cc=devicetree@vger.kernel.org \
--cc=fenghua.yu@intel.com \
--cc=guo.wenjia23@zte.com.cn \
--cc=james.morse@arm.com \
--cc=krzk+dt@kernel.org \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=liu.qingtao2@zte.com.cn \
--cc=liwei1518@gmail.com \
--cc=mindal@semihalf.com \
--cc=npitre@baylibre.com \
--cc=palmer@dabbelt.com \
--cc=paul.walmsley@sifive.com \
--cc=peternewman@google.com \
--cc=pjw@kernel.org \
--cc=rafael@kernel.org \
--cc=reinette.chatre@intel.com \
--cc=rkrcmar@ventanamicro.com \
--cc=robert.moore@intel.com \
--cc=robh@kernel.org \
--cc=samuel.holland@sifive.com \
--cc=sunilvl@ventanamicro.com \
--cc=tony.luck@intel.com \
--cc=vasu@rivosinc.com \
--cc=ved@rivosinc.com \
--cc=x86@kernel.org \
--cc=zhiwei_liu@linux.alibaba.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 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.