Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3844096pxj; Tue, 11 May 2021 13:11:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzJw37r/oaKha4kfSCFbwqfqbJVXUf6RPi5dykEg+1GDA6BtEP8KZOqY/IvE9pGKIdecJNS X-Received: by 2002:a05:6402:284:: with SMTP id l4mr39144732edv.299.1620763887373; Tue, 11 May 2021 13:11:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620763887; cv=none; d=google.com; s=arc-20160816; b=GrNFSC7syRgxT2NQfTSynnKUREE5ZFs4sU1sSrRF9vk5hiiFKtoTG0udH6y4ntv5mf sMYjEZLNyo0+Zd3r9tu1xnafV/lU4FpXrKfjkEGnwfzs7lmJyJP1P40ArZp4284D74k7 p4v/sijN1XOR884QWhf3CGMBftN2S61NcEZLB+Cx0yM7k1swycG8GXXKFULa/p8ODZmS WgOL3Tzw0qGYiNDHMV6RrsIBrVTFPMhd5aDLzBNx4COcvTXAhtm/fJxNnWGG+aKzMauV d62Jq/U/rQbS3CxOYos0gnIuYIS0/27EBcT0UAiOTh8LqaoUOIYaJlFzTDBJu2IOzvkH hFnw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=9hsJp/8M+c794Pqj/BGqU0TDUiLA1/EXUU62NU+MuI8=; b=DWTStdMB7gR+a6jFezXDRD/TB9vrz9ZxyQC/MpKT9TAqpJrYIiindESnij/Dx3ZO5m aff0Kfhio+fnQ1AYWpFK/4XVciNWca+0kQlobzdaixCaDb+xh28vKzlxhoBuknGhWp+h T0qgX5fxo2UeBC6CkALI9eUCJN3a9B6qI3OpyeAQqigtD8ub6tvIq8h3nkJeUhD54vU7 P8OGwq12O+lsAgL9XFh09xkagIRje3SmKTDXfvO2ftOsO0Oicx8vHDKAoQD/N0xLoOyL Q+sbfKLPmFbT5kXhhvgCEBzra0AwXljDTGgY5HjNEZI9+eqsBwQo3eatiPSKxPaA1VBH DNVw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=QWxVvsHJ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g26si12528659ejc.256.2021.05.11.13.11.01; Tue, 11 May 2021 13:11:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=QWxVvsHJ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229952AbhEKULR (ORCPT + 99 others); Tue, 11 May 2021 16:11:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42030 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229716AbhEKULQ (ORCPT ); Tue, 11 May 2021 16:11:16 -0400 Received: from mail-pl1-x635.google.com (mail-pl1-x635.google.com [IPv6:2607:f8b0:4864:20::635]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id ED42CC06174A for ; Tue, 11 May 2021 13:10:09 -0700 (PDT) Received: by mail-pl1-x635.google.com with SMTP id z18so7780074plg.8 for ; Tue, 11 May 2021 13:10:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=9hsJp/8M+c794Pqj/BGqU0TDUiLA1/EXUU62NU+MuI8=; b=QWxVvsHJmxi2i0/v0yvXGA/rYmebcRITSfU78PEVWzxzZQj5NH4W2zx4Ow2aldvIOZ RF+Pp01gjiTBsL4GN8iYTGXpT6Tk8/q5bZuVXfvEMLhACIa26lseUWufR0uXgI5csmYZ qPaYTvBEgra7SDs/9ygersTwFvS7PngkczxI2jgG8p5lKZFWvqGWB5EBUmZ7KdIZywut 7YKlRIiPop3urGUH1d28rki8FOxWFo1xJl/93w/+LUlRj7ZnFAX/x6i1e8t8bFnPZg9V sinN/l4I+RBvPQvUwtxvn/l4MRno77sXlDk/dibPowkeifpBrMli9ad0UZzE7+2l8L5s PjTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=9hsJp/8M+c794Pqj/BGqU0TDUiLA1/EXUU62NU+MuI8=; b=Z7FvAKs2eF4fW62XFAuVoJP+dWOh2UioMIY8t5xDfoEzsyfqoajqZ1mqGCimNJed+U D/ae0mLnTY64nN8uAWst2z5lZRhqNTOhzyXkx4iZRM3CLKABfTLiN47fmF1igC9SBxVi p/AFtV+hbh6ez+sxwANH3gAk3Kw4U5aj4CqUJc19jZsY1W7re1Rmg9A+A628TjS4lPFR Koz/QEpY0BNOceMsvGI+sW3P0CAFyJTo4V+92PZ5Ld7A6Rxalku3nVSDEFnOVtRelvpI vPbf9+2HCKPgPmFAEyhQs8KeTilBxsdJBnQ2UqB/PP+ntBVcGbtqfFZfSwHyVVIVA8cq aokg== X-Gm-Message-State: AOAM5309elMyUS/nHV9RTs7Cb/jlLebwjIHzTdM2wz3VEkVyD1l/bFPf w/X8jwDTenTxzq475AHNGuSUKg== X-Received: by 2002:a17:902:70c5:b029:ec:9a57:9cc8 with SMTP id l5-20020a17090270c5b02900ec9a579cc8mr31856628plt.73.1620763809212; Tue, 11 May 2021 13:10:09 -0700 (PDT) Received: from google.com (240.111.247.35.bc.googleusercontent.com. [35.247.111.240]) by smtp.gmail.com with ESMTPSA id s14sm1396567pjp.16.2021.05.11.13.10.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 May 2021 13:10:08 -0700 (PDT) Date: Tue, 11 May 2021 20:10:05 +0000 From: Sean Christopherson To: Maxim Levitsky Cc: Paolo Bonzini , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Joerg Roedel , kvm@vger.kernel.org, linux-kernel@vger.kernel.org, Xiaoyao Li , Reiji Watanabe Subject: Re: [PATCH 08/15] KVM: VMX: Configure list of user return MSRs at module init Message-ID: References: <20210504171734.1434054-1-seanjc@google.com> <20210504171734.1434054-9-seanjc@google.com> <9cf65a1d7b96c69077779d7a11777004d0bce6c9.camel@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <9cf65a1d7b96c69077779d7a11777004d0bce6c9.camel@redhat.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, May 11, 2021, Maxim Levitsky wrote: > On Mon, 2021-05-10 at 15:13 +0000, Sean Christopherson wrote: > > On Mon, May 10, 2021, Maxim Levitsky wrote: > > > On Tue, 2021-05-04 at 10:17 -0700, Sean Christopherson wrote: > > > > @@ -6929,18 +6942,10 @@ static int vmx_create_vcpu(struct kvm_vcpu *vcpu) > > > > goto free_vpid; > > > > } > > > > > > > > - BUILD_BUG_ON(ARRAY_SIZE(vmx_uret_msrs_list) != MAX_NR_USER_RETURN_MSRS); > > > > + for (i = 0; i < vmx_nr_uret_msrs; ++i) { > > > > + vmx->guest_uret_msrs[i].data = 0; > > > > > > > > - for (i = 0; i < ARRAY_SIZE(vmx_uret_msrs_list); ++i) { > > > > - u32 index = vmx_uret_msrs_list[i]; > > > > - int j = vmx->nr_uret_msrs; > > > > - > > > > - if (kvm_probe_user_return_msr(index)) > > > > - continue; > > > > - > > > > - vmx->guest_uret_msrs[j].slot = i; > > > I don't see anything initalizing the .slot after this patch. > > > Now this code is removed later which masks this bug, > > > but for the bisect sake, I think that this patch > > > should still be fixed. > > > > Egad, indeed it's broken. I'll retest the whole series to verify the other > > patches will bisect cleanly. > > > > Nice catch! > > > Thanks! Unfortunately this made it's way to Linus before I could fix my goof. Fingers crossed no one is unfortunate enough to land on this while bisecting...