Re: [kvm-unit-tests PATCH v3 3/4] s390x: add extint loop test

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

 



On Wed, 10 Aug 2022 14:29:27 +0200
Nico Boehr <nrb@xxxxxxxxxxxxx> wrote:

> Quoting Claudio Imbrenda (2022-08-10 12:08:22)
> > > diff --git a/s390x/panic-loop-extint.c b/s390x/panic-loop-extint.c
> > > new file mode 100644
> > > index 000000000000..d3a3f06d9a34
> > > --- /dev/null
> > > +++ b/s390x/panic-loop-extint.c  
> [...]
> > > +static void ext_int_handler(void)
> > > +{
> > > +     /*
> > > +      * return to ext_old_psw. This gives us the chance to print the return_fail
> > > +      * in case something goes wrong.
> > > +      */
> > > +     asm volatile (
> > > +             "lpswe %[ext_old_psw]\n"
> > > +             :
> > > +             : [ext_old_psw] "Q"(lowcore.ext_old_psw)
> > > +             : "memory"
> > > +     );
> > > +}  
> > 
> > why should ext_old_psw contain a good PSW? wouldn't it contain the
> > PSW at the time of the interrupt? (which in this case is the new PSW)  
> 
> That's right in case the interrupt loop occurs, it doesn't make much sense to return to ext_old_psw. But in this case lpswe will never be executed anyways.
> 
> > but this should never happen anyway, right?  
> 
> Exactly, this is just supposed to be a safety net in case the interrupt loop doesn't happen. If you want, we could remove it and just leave an empty function here. Then, we will just run into the kvm-unit-tests timeout and fail as well, but I prefer the fail fast.

just add a comment to explain that



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux