[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3 028/114] hw/intc: use kvm_enabled() in APLIC AIA helpers





On Sat, Sep 26, 2026 at 5:35 PM Philippe Mathieu-Daudé <philmd@xxxxxxxxxxxxxxxx> wrote:
>
> On 23/9/26 15:15, Yonggang Luo wrote:
> > - Replace CONFIG_KVM ifdefs in riscv_use_emulated_aplic and
> >    riscv_aplic_set_kvm_msicfgaddr with kvm_enabled().
>
> Can you provide your S-o-b tag please?

Thanks, I forgot this, the following patches will attach S-o-b. This series is dropped as gmail limits me to send all the things.

>
> > ---
> >   hw/intc/riscv_aplic.c | 14 ++++++++------
> >   1 file changed, 8 insertions(+), 6 deletions(-)
> >
> > diff --git a/hw/intc/riscv_aplic.c b/hw/intc/riscv_aplic.c
> > index d8e25bfda14..03a0852b8b8 100644
> > --- a/hw/intc/riscv_aplic.c
> > +++ b/hw/intc/riscv_aplic.c
> > @@ -167,7 +167,10 @@ bool riscv_is_kvm_aia_aplic_imsic(bool msimode)
> >  
> >   bool riscv_use_emulated_aplic(bool msimode)
> >   {
> > -#ifdef CONFIG_KVM
> > +    if (!kvm_enabled()) {
> > +        return true;
> > +    }
> > +
> >       if (tcg_enabled()) {
> >           return true;
> >       }
> > @@ -177,21 +180,20 @@ bool riscv_use_emulated_aplic(bool msimode)
> >       }
> >  
> >       return kvm_kernel_irqchip_split();
> > -#else
> > -    return true;
> > -#endif
> >   }
> >  
> >   void riscv_aplic_set_kvm_msicfgaddr(RISCVAPLICState *aplic, hwaddr addr)
> >   {
> > -#ifdef CONFIG_KVM
> > +    if (!kvm_enabled()) {
> > +        return;
> > +    }
> > +
> >       if (riscv_use_emulated_aplic(aplic->msimode)) {
> >           addr >>= APLIC_xMSICFGADDR_PPN_SHIFT;
> >           aplic->kvm_msicfgaddr = extract64(addr, 0, 32);
> >           aplic->kvm_msicfgaddrH = extract64(addr, 32, 32) &
> >                                    APLIC_MMSICFGADDRH_VALID_MASK;
> >       }
> > -#endif
> >   }
> >  
> >   /*
>


--
         此致
礼
罗勇刚
Yours
    sincerely,
Yonggang Luo

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.