From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41113) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b3nJM-0005gf-IE for qemu-devel@nongnu.org; Fri, 20 May 2016 12:30:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b3nJI-0002Lu-At for qemu-devel@nongnu.org; Fri, 20 May 2016 12:30:03 -0400 Received: from mx1.redhat.com ([209.132.183.28]:47527) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b3nJI-0002Lp-52 for qemu-devel@nongnu.org; Fri, 20 May 2016 12:30:00 -0400 From: Bandan Das References: <1463696116-31631-1-git-send-email-bsd@redhat.com> <1463696116-31631-5-git-send-email-bsd@redhat.com> <09450c5c-f7e9-a71f-0416-92e7bf97ad99@redhat.com> Date: Fri, 20 May 2016 12:29:58 -0400 In-Reply-To: <09450c5c-f7e9-a71f-0416-92e7bf97ad99@redhat.com> (Paolo Bonzini's message of "Fri, 20 May 2016 09:50:27 +0200") Message-ID: MIME-Version: 1.0 Content-Type: text/plain 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: Paolo Bonzini Cc: qemu-devel@nongnu.org, aik@ozlabs.ru Paolo Bonzini writes: > 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. Thanks for the review, I have sent a v2. > Paolo