Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754365AbaDVD3t (ORCPT ); Mon, 21 Apr 2014 23:29:49 -0400 Received: from mail-yk0-f176.google.com ([209.85.160.176]:57103 "EHLO mail-yk0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751280AbaDVD3q (ORCPT ); Mon, 21 Apr 2014 23:29:46 -0400 Message-ID: <5355E222.7010607@redhat.com> Date: Mon, 21 Apr 2014 23:29:38 -0400 From: Paolo Bonzini User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: Bandan Das , kvm@vger.kernel.org CC: Marcelo Tosatti , Gleb Natapov , linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] KVM: x86: Check for host supported fields in shadow vmcs References: In-Reply-To: X-Enigmail-Version: 1.6 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Il 21/04/2014 15:20, Bandan Das ha scritto: > + for (i = j = 0; i < max_shadow_read_write_fields; i++) { > + Extra empty line. Not a big deal, but... > + switch (shadow_read_write_fields[i]) { > + case GUEST_BNDCFGS: > + if (!vmx_mpx_supported()) > + continue; > + break; > + default: > + break; > + } > + > + 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 assignment, otherwise a separate statement is fine by me too. Paolo -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/