From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:57262) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SsXFs-0003R5-Ex for qemu-devel@nongnu.org; Sat, 21 Jul 2012 06:49:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SsXFr-0004pC-Kg for qemu-devel@nongnu.org; Sat, 21 Jul 2012 06:49:48 -0400 Received: from mail-bk0-f45.google.com ([209.85.214.45]:49794) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SsXFr-0004p6-Du for qemu-devel@nongnu.org; Sat, 21 Jul 2012 06:49:47 -0400 Received: by bkcji1 with SMTP id ji1so3458139bkc.4 for ; Sat, 21 Jul 2012 03:49:45 -0700 (PDT) Message-ID: <500A8969.1040300@gmail.com> Date: Sat, 21 Jul 2012 12:50:17 +0200 From: Sasha Levin MIME-Version: 1.0 References: <500A565A.8080403@cn.fujitsu.com> In-Reply-To: <500A565A.8080403@cn.fujitsu.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v7] kvm: notify host when the guest is panicked List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Wen Congyang Cc: Gleb Natapov , kvm list , Jan Kiszka , qemu-devel , "linux-kernel@vger.kernel.org" , Avi Kivity , KAMEZAWA Hiroyuki On 07/21/2012 09:12 AM, Wen Congyang wrote: > +#define KVM_PV_PORT (0x505UL) > + > #ifdef __KERNEL__ > #include > > @@ -221,6 +223,11 @@ static inline void kvm_disable_steal_time(void) > } > #endif > > +static inline unsigned int kvm_arch_pv_features(void) > +{ > + return inl(KVM_PV_PORT); > +} > + Why is this safe? I'm not sure you can just pick any ioport you'd like and use it.