On 04.12.19 15:59, Cornelia Huck wrote: > On Tue, 3 Dec 2019 08:28:11 -0500 > Janosch Frank <fran...@linux.ibm.com> wrote: > >> Up to now we only had an ioctl to reset vcpu data QEMU couldn't reach >> for the initial reset, and that was also called for the clear >> reset. To be architecture compliant, we also need to clear local >> interrupts on a normal reset. > > Do we also need to do something like that for tcg? David? >
So, we have /* Fields up to this point are not cleared by initial CPU reset */ struct {} start_initial_reset_fields; [...] int pending_int uint16_t external_call_addr; DECLARE_BITMAP(emergency_signals, S390_MAX_CPUS); [...] /* Fields up to this point are cleared by a CPU reset */ struct {} end_reset_fields; This means, local interrupts will be cleared by everything that zeroes "start_initial_reset_fields->end_reset_fields" So, they will get cleared by S390_CPU_RESET_INITIAL only if I am not wrong. In order to clear them on S390_CPU_RESET_NORMAL, we have to manually set them to zero. (we really should wrap TCG-only fields by ifdefs) -- Thanks, David / dhildenb