qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [RFC PATCH v5 22/31] timer: introduce new QEMU_CLOCK_VI


From: Pavel Dovgaluk
Subject: Re: [Qemu-devel] [RFC PATCH v5 22/31] timer: introduce new QEMU_CLOCK_VIRTUAL_RT clock
Date: Fri, 28 Nov 2014 10:52:53 +0300

> From: Paolo Bonzini [mailto:address@hidden
> On 27/11/2014 10:11, Pavel Dovgaluk wrote:
> > When POLL interrupt request is processed by x86_cpu_exec_interrupt 
> > function, as it were
> before,
> > everything is ok, because I ensure that these calls occur at the same 
> > moments in
> record/replay.
> 
> Does this partial revert work?

This one is better because I can place synchronization point for replay here.

Pavel Dovgalyuk

> 
> Paolo
> 
> diff --git a/cpu-exec.c b/cpu-exec.c
> index 3913de0..c976095 100644
> --- a/cpu-exec.c
> +++ b/cpu-exec.c
> @@ -331,6 +331,12 @@ int cpu_exec(CPUArchState *env)
>      volatile bool have_tb_lock = false;
> 
>      if (cpu->halted) {
> +#ifdef TARGET_I386
> +        if (cpu->interrupt_request & CPU_INTERRUPT_POLL) {
> +            apic_poll_irq(x86_cpu->apic_state);
> +            cpu_reset_interrupt(cpu, CPU_INTERRUPT_POLL);
> +        }
> +#endif
>          if (!cpu_has_work(cpu)) {
>              return EXCP_HALTED;
>          }
> diff --git a/target-i386/cpu.c b/target-i386/cpu.c
> index e9df33e..3f13dfe 100644
> --- a/target-i386/cpu.c
> +++ b/target-i386/cpu.c
> @@ -2912,14 +2912,8 @@ static bool x86_cpu_has_work(CPUState *cs)
>      X86CPU *cpu = X86_CPU(cs);
>      CPUX86State *env = &cpu->env;
> 
> -#if !defined(CONFIG_USER_ONLY)
> -    if (cs->interrupt_request & CPU_INTERRUPT_POLL) {
> -        apic_poll_irq(cpu->apic_state);
> -        cpu_reset_interrupt(cs, CPU_INTERRUPT_POLL);
> -    }
> -#endif
> -
> -    return ((cs->interrupt_request & CPU_INTERRUPT_HARD) &&
> +    return ((cs->interrupt_request & (CPU_INTERRUPT_HARD |
> +                                      CPU_INTERRUPT_POLL)) &&
>              (env->eflags & IF_MASK)) ||
>             (cs->interrupt_request & (CPU_INTERRUPT_NMI |
>                                       CPU_INTERRUPT_INIT |




reply via email to

[Prev in Thread] Current Thread [Next in Thread]