From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Kiszka Subject: Re: nmi is broken? Date: Tue, 03 May 2011 17:01:15 +0200 Message-ID: <4DC018BB.5040003@siemens.com> References: <87sjtbe7fz.fsf@devron.myhome.or.jp> <877hak1t1s.fsf@devron.myhome.or.jp> <4DB3C6D3.9040703@redhat.com> <4DB42EC3.3090002@web.de> <4DBFCE25.2060603@redhat.com> <4DBFDAE1.3030104@siemens.com> <4DC003BF.9060204@redhat.com> <4DC0114B.3080907@siemens.com> <4DC0131D.5090407@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: OGAWA Hirofumi , "kvm@vger.kernel.org" To: Avi Kivity Return-path: Received: from goliath.siemens.de ([192.35.17.28]:21907 "EHLO goliath.siemens.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752411Ab1ECPBY (ORCPT ); Tue, 3 May 2011 11:01:24 -0400 In-Reply-To: <4DC0131D.5090407@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On 2011-05-03 16:37, Avi Kivity wrote: > On 05/03/2011 05:29 PM, Jan Kiszka wrote: >> On 2011-05-03 15:31, Avi Kivity wrote: >>> On 05/03/2011 01:37 PM, Jan Kiszka wrote: >>>>> >>>>> Yes. Unfortunately that is very vendor and model specific. The >>>>> architectural PMU is supported, but that is only available on Intel. >>>> >>>> Is it supposed to have any practical value already? I did not yet find a >>>> magic -cpu switch to let Linux detect anything, not to speak of perf or >>>> watchdog support. >>> >>> On the guest side it is supported for the watchdog >>> (arch/x86/kernel/cpu/perfctr-watchdog.c, look for >>> X86_FEATURE_ARCH_PERFMON). It's also mentioned in perf_event_intel.c, >>> but I don't know if it will work without the other PMU features being >>> present. >> >> I've tested with some SUSE 2.6.38 guest kernel, and it complained like >> this: >> >> (-cpu kvm64) >> Performance Events: unsupported Netburst CPU model 6 no PMU driver, software events only. >> NMI watchdog disabled (cpu0): hardware events not enabled >> > > Sorry, I meant to write, but forgot, that on the host side it is > completely unsupported. It shouldn't be too hard to use perf_events to > emulate the architectural PMU. Once we do that we can expose the > architectural pmu bit and the guest will use it. Oh, and I already thought I would have missed some thrilling KVM patches... Jan -- Siemens AG, Corporate Technology, CT T DE IT 1 Corporate Competence Center Embedded Linux