From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paolo Bonzini Subject: Re: [PATCH v2] KVM: x86: Check for host supported fields in shadow vmcs Date: Tue, 22 Apr 2014 15:13:46 -0400 Message-ID: <5356BF6A.2070801@redhat.com> References: <5355E222.7010607@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org, Marcelo Tosatti , Gleb Natapov , linux-kernel@vger.kernel.org To: Bandan Das Return-path: In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org Il 22/04/2014 12:25, Bandan Das ha scritto: >>> >> + if (j < i) >>> >> + shadow_read_write_fields[j] = >>> >> + shadow_read_write_fields[i]; >>> >> + j++; >> > >> > ... you need to respin anyway because the j++ is wrong. It should be >> > inside the "if". If you prefer, you can put it in the lhs of the > j++ outside the "if" looks right to me. Can you please explain why > you think it shouldn't be that way ? > The way you wrote it, j will always be equal to i. Paolo