From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42331) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b3fCd-0007DS-SJ for qemu-devel@nongnu.org; Fri, 20 May 2016 03:50:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b3fCc-0003wD-Nj for qemu-devel@nongnu.org; Fri, 20 May 2016 03:50:35 -0400 Received: from mail-wm0-x243.google.com ([2a00:1450:400c:c09::243]:33617) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b3fCc-0003w3-HO for qemu-devel@nongnu.org; Fri, 20 May 2016 03:50:34 -0400 Received: by mail-wm0-x243.google.com with SMTP id 67so3804100wmg.0 for ; Fri, 20 May 2016 00:50:34 -0700 (PDT) Sender: Paolo Bonzini References: <1463696116-31631-1-git-send-email-bsd@redhat.com> <1463696116-31631-5-git-send-email-bsd@redhat.com> From: Paolo Bonzini Message-ID: Date: Fri, 20 May 2016 09:50:31 +0200 MIME-Version: 1.0 In-Reply-To: <1463696116-31631-5-git-send-email-bsd@redhat.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 4/4] cpus: call the core nmi injection function List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Bandan Das , qemu-devel@nongnu.org Cc: aik@ozlabs.ru On 20/05/2016 00:15, Bandan Das wrote: > void qmp_inject_nmi(Error **errp) > { > -#if defined(TARGET_I386) > - CPUState *cs; > - > - CPU_FOREACH(cs) { > - X86CPU *cpu = X86_CPU(cs); > - > - if (!cpu->apic_state) { > - cpu_interrupt(cs, CPU_INTERRUPT_NMI); > - } else { > - apic_deliver_nmi(cpu->apic_state); > - } > - } > -#else > - nmi_monitor_handle(monitor_get_cpu_index(), errp); > -#endif > + inject_nmi(errp); This changes the first argument to nmi_monitor_handle in the !i386 case. It should just remove the #ifdef, which I think makes the third patch unnecessary. The first two patches are okay. Paolo