From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gleb Natapov Subject: Re: Q: What is the struct kvm srcu protecting? Date: Sun, 5 May 2013 10:37:54 +0300 Message-ID: <20130505073754.GG22125@redhat.com> References: <5182AEFC.9070703@gmail.com> <20130503014836.GB8741@amt.cnet> <20130503105101.GE17141@redhat.com> <5183F205.40006@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Marcelo Tosatti , kvm@vger.kernel.org, Sanjay Lal To: David Daney Return-path: Received: from mx1.redhat.com ([209.132.183.28]:62103 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751417Ab3EEHiC (ORCPT ); Sun, 5 May 2013 03:38:02 -0400 Content-Disposition: inline In-Reply-To: <5183F205.40006@gmail.com> Sender: kvm-owner@vger.kernel.org List-ID: On Fri, May 03, 2013 at 10:21:09AM -0700, David Daney wrote: > On 05/03/2013 03:51 AM, Gleb Natapov wrote: > >Hi David, > > > >On Thu, May 02, 2013 at 10:48:36PM -0300, Marcelo Tosatti wrote: > >>On Thu, May 02, 2013 at 11:22:52AM -0700, David Daney wrote: > >>>Hi, > >>> > >>>I am working on the MIPS KVM port, and am trying to figure out under > >>>which circumstances do I need to srcu_read_lock()/srcu_read_unlock() > >>>the kvm->srcu. > >> > >Is your work somehow related to the work of Sanjay Lal that can be found > >here: https://git.linux-mips.org/?p=ralf/upstream-sfr.git;a=summary? > > > > It is related in that a single asm/uaip/kvm.h must be shared between > the implementations. It differs in that it is based on the MIPS-VZ > hardware virtualization feature, where as Sanjay's code is a pure > software solution. > > If possible some code might be shared between the two, but it may > end up looking somewhat like the x86 implementation where there are > separate VMX and SVM implementations. > Sanjay code already has such design and the reason he gave for it was upcoming HW virtualization support. -- Gleb.