mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-09 10:34:58 -06:00
s390x/kvm: run guest triggered resets on the target vcpu thread
Currently, load_normal_reset() and modified_clear_reset() as triggered by a guest vcpu will initiate cpu resets on the current vcpu thread for all cpus. The reset should happen on the individual vcpu thread instead, so let's use run_on_cpu() for this. This avoids calls to synchronize_rcu() in the kernel. Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Acked-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Jens Freimann <jfrei@linux.vnet.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
This commit is contained in:
parent
8b3030114a
commit
85ca3371f6
2 changed files with 23 additions and 22 deletions
|
@ -353,6 +353,21 @@ static inline hwaddr decode_basedisp_s(CPUS390XState *env, uint32_t ipb)
|
|||
/* Base/displacement are at the same locations. */
|
||||
#define decode_basedisp_rs decode_basedisp_s
|
||||
|
||||
/* helper functions for run_on_cpu() */
|
||||
static inline void s390_do_cpu_reset(void *arg)
|
||||
{
|
||||
CPUState *cs = arg;
|
||||
S390CPUClass *scc = S390_CPU_GET_CLASS(cs);
|
||||
|
||||
scc->cpu_reset(cs);
|
||||
}
|
||||
static inline void s390_do_cpu_full_reset(void *arg)
|
||||
{
|
||||
CPUState *cs = arg;
|
||||
|
||||
cpu_reset(cs);
|
||||
}
|
||||
|
||||
void s390x_tod_timer(void *opaque);
|
||||
void s390x_cpu_timer(void *opaque);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue