[PATCH V2 3/4] irqchip/riscv-imsic: Move nr_guest_files to per-HART local config

Guo Ren guoren at kernel.org
Thu May 7 03:04:30 PDT 2026


On Wed, May 6, 2026 at 4:12 AM Thomas Gleixner <tglx at kernel.org> wrote:
>
> On Sat, Apr 25 2026 at 00:59, guoren at kernel.org wrote:
> > From: "Guo Ren (Alibaba DAMO Academy)" <guoren at kernel.org>
> >
> > With the recent KVM AIA per-HART HGEI conversion, the global
> > nr_guest_files is no longer appropriate. Different HARTs in
> > heterogeneous SoCs may have different numbers of guest interrupt
> > files.
> >
> > Move `nr_guest_files` from `struct imsic_global_config` to
> > `struct imsic_local_config`, and compute it per-CPU in
> > imsic_setup_state() based on the actual MMIO guest file region size.
> >
> > Update the related comment to reflect that KVM now uses the
> > per-HART value.
> >
> > This eliminates the last global assumption about guest files and
> > completes the per-HART conversion series for RISC-V AIA/IMSIC.
> >
> > Signed-off-by: Guo Ren (Alibaba DAMO Academy) <guoren at kernel.org>
>
> Assuming this goes through the risc-v tree:
>
> Acked-by: Thomas Gleixner <tglx at kernel.org>

Got it & Thx Thomas.

I think it'll go through the kvm-riscv tree because it's all about kvm
improvements.

-- 
Best Regards
 Guo Ren



More information about the linux-riscv mailing list