From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=56271 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q7Y4R-0007KE-FC for qemu-devel@nongnu.org; Wed, 06 Apr 2011 15:07:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q7Xxv-00016f-VP for qemu-devel@nongnu.org; Wed, 06 Apr 2011 15:00:33 -0400 Received: from mx1.redhat.com ([209.132.183.28]:27206) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q7Xxv-00016C-Mb for qemu-devel@nongnu.org; Wed, 06 Apr 2011 15:00:31 -0400 Date: Wed, 6 Apr 2011 16:00:20 -0300 From: Luiz Capitulino Subject: Re: [Qemu-devel] [PATCH 2/2 V7] qemu,qmp: add inject-nmi qmp command Message-ID: <20110406160020.373cb5a2@doriath> In-Reply-To: <4D9CAE4B.7080305@siemens.com> References: <4D74A8C9.2020408@cn.fujitsu.com> <4D74A974.6090509@cn.fujitsu.com> <20110404105949.GA30324@redhat.com> <4D99BF99.1040305@redhat.com> <4D99C22C.4070401@codemonkey.ws> <20110406144723.45333682@doriath> <4D9CAAF9.7000509@codemonkey.ws> <20110406150818.56707b9b@doriath> <4D9CAE4B.7080305@siemens.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jan Kiszka Cc: Lai Jiangshan , Jiangshan , kvm@vger.kernel.org, qemu-devel@nongnu.org, Markus Armbruster , Avi Kivity On Wed, 06 Apr 2011 20:17:47 +0200 Jan Kiszka wrote: > On 2011-04-06 20:08, Luiz Capitulino wrote: > > On Wed, 06 Apr 2011 13:03:37 -0500 > > Anthony Liguori wrote: > > > >> On 04/06/2011 12:47 PM, Luiz Capitulino wrote: > >>> On Mon, 04 Apr 2011 08:05:48 -0500 > >>> Anthony Liguori wrote: > >>> > >>>> On 04/04/2011 07:54 AM, Avi Kivity wrote: > >>>>> On 04/04/2011 01:59 PM, Daniel P. Berrange wrote: > >>>>>> Interesting that with HMP you need to specify a single CPU index, but > >>>>>> with QMP it is injecting to all CPUs at once. Is there any compelling > >>>>>> reason why we'd ever need the ability to only inject to a single CPU > >>>>>> from an app developer POV ? > >>>>> When a PC has an NMI button, it is (I presume) connected to all CPUs' > >>>>> LINT1 pin, which is often configured as an NMI input. So the all-cpu > >>>>> variant corresponds to real hardware, while the single-cpu variant > >>>>> doesn't. > >>>>> > >>>>> wrt the app developer POV, the only use I'm aware of is that you can > >>>>> configure Windows to dump core when the NMI button is pressed and thus > >>>>> debug driver problems. It's likely more reliable when sent to all cpus. > >>>> It either needs to be removed from HMP or added to QMP. HMP shouldn't > >>>> have more features than QMP (even if those features are non-sensible). > >>> Is anyone against changing HMP behavior to send it to all CPUs? > >> > >> Makes sense to me. > > > > So, Lai, in order to get this merged could you please do the following: > > > > 1. Address checkpath.pl errors > > > > 2. Change the HMP to use this implementation, which send the NMI > > to all CPUs > > HMP is currently x86-only, thus it's probably OK to model it after some > PC feature (though I don't know if there aren't NMI buttons with BP-only > wirings). But will the consolidate version be defined for all > architectures? We should avoid "exporting" x86-specific assumptions. Right, but honestly speaking, I don't know how this works for other arches. So, the best thing to do is to have a general design that can be used by any architecture. Of course that we can also add a new command later if needed.