From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pg1-f197.google.com (mail-pg1-f197.google.com [209.85.215.197]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 226254398EB for ; Mon, 17 Aug 2026 13:49:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.215.197 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786974558; cv=none; b=l+4bgGpPtAWM1UvhtHNhbIX9SHgsHxBb1XJMmzSyvtw8fpezRT3Sw2Rgl72iuJPm16PSVvTdaQssccxDCi/2CagvlWSNPjc++cSQdrKJ5y5qwcLJ4+JGmimY1/IMPxBv7p4iUvC3jBzyqgVJE5NWMca2kuf1B8rB2UGik0HOTT4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786974558; c=relaxed/simple; bh=RnzOzGFK1YB2l72myPyapEsUaP3t6NWRMrFrNJEQl10=; h=Date:In-Reply-To:Mime-Version:References:Message-ID:Subject:From: To:Cc:Content-Type; b=XoXfFEdd1D4ObZRXut3DMN3mF2kgJkcx0DNGVkc1yUJgdTQqbwsCw1UimhPyhCkZaKKMXWXvmkBwB4WWC3WGDQysQZpPzhW/uQo0PpdfkIV7uRCb9aII8kH8x9a6doRrd39+QCMhLApUCj2Jl6ssHOEeQHo5Ybv7SLin3TXJOSI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--seanjc.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=HAL/nVvU; arc=none smtp.client-ip=209.85.215.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--seanjc.bounces.google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="HAL/nVvU" Received: by mail-pg1-f197.google.com with SMTP id 41be03b00d2f7-cb5cc1e13f8so2710024a12.3 for ; Mon, 17 Aug 2026 06:49:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20251104; t=1786974550; x=1787579350; darn=vger.kernel.org; h=content-type:cc:to:from:subject:message-id:references:mime-version :in-reply-to:date:from:to:cc:subject:date:message-id:reply-to :content-type; bh=v60n69Fh2rc5rSD04kHKtxhuZ7ZKSWjk5+HKb8IHNFo=; b=HAL/nVvUMPBivZ43UUd+giWW/Udfmu42kJfzKWefTb/oL1V0RNE2QcOGINIJjDV045 M01eWuJxvRyDWD3GGGsRqITOo/N42gcXbYOG3iaOcKZ/iFxj3jH5zzzfWZta0L8quFiF 1fiHLxjmGoz3LsdYHmBlig1NXBKwBmLsCPss5+aBJhD8lYjUGueyLgtebqPGUkJTkzlk SPusBB5qIl2JviFWe7RbV/Jxrn65kOCYqCGg444C/Vk9grzVeAjJ2UwLiCDLQrJOqD9c n4w8TDhlYBo7e1aEPPmNxoVNTpTH5UB0psnVteZWbJXtcq8slHT6HWy07bOCaN3++K27 rdDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786974550; x=1787579350; h=content-type:cc:to:from:subject:message-id:references:mime-version :in-reply-to:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=v60n69Fh2rc5rSD04kHKtxhuZ7ZKSWjk5+HKb8IHNFo=; b=E+kYRR+qWZxSN6UKYAGEqqOmXVrwon2ubiFqFClfY8cEZ6mwDL4iyY70WQ3PJKzo2M SJ7gXaZFkAx6no2eWzn/Ivq2pRcKhJQ3VA1EL3tYY6SHok0jsSBZ0Dg400eScmBTE7qB +9IwX2zsSZfxHkeB63v2CHt/V08RsuCppyRn1B/iRBEWYx0qfn24IqGyUUk0xSbdOijo UePhm5FwKl8B0P8JqqjXbTzIRZ/0kzu9qH4vJS9QvX8lA5OOtumIiBrkW47BM1SC9B9y /PiWdrWi0v3Xo7MCNBB1uKIkDlZ5eSZCq3p3QiM1tuxbPPT7M5Omi3jXgeS9JslM5rpW 7oww== X-Forwarded-Encrypted: i=1; AHgh+RoPGOeUAbNZUZVeyRBZebP9iZOj+86/d0q0KgzGXZbIJY3WqomjuVtuFkujR7dHSU2GYadsje7l0v2q57E=@vger.kernel.org X-Gm-Message-State: AOJu0YyKOirmUQg4GsfFM324ZXUrK2d4BUX2NPxIjcQxr7eg9WiCSWn8 56AGHHV9ahZV5XVSsUdb6E/Fi2Thp5peDafpn3Yf/dq3k0wn9R2BhwE++JyW6o5LX13DGdmE2Nn tVdFV1g== X-Received: from pgbfe12.prod.google.com ([2002:a05:6a02:288c:b0:cbe:dff5:6872]) (user=seanjc job=prod-delivery.src-stubby-dispatcher) by 2002:a05:6a21:6194:b0:3cc:3d08:da3e with SMTP id adf61e73a8af0-3ccda405874mr474615637.2.1786974549957; Mon, 17 Aug 2026 06:49:09 -0700 (PDT) Date: Mon, 17 Aug 2026 06:49:09 -0700 In-Reply-To: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20260814161129.2177118-1-seanjc@google.com> <20260814161129.2177118-2-seanjc@google.com> Message-ID: Subject: Re: [PATCH 1/3] KVM: VMX: Move the shared "IRQs off" exit handler(s) to common code From: Sean Christopherson To: Binbin Wu Cc: Paolo Bonzini , Kiryl Shutsemau , Rick Edgecombe , Dave Hansen , kvm@vger.kernel.org, x86@kernel.org, linux-coco@lists.linux.dev, linux-kernel@vger.kernel.org, Xiaoyao Li , Kai Huang , Yan Zhao Content-Type: text/plain; charset="us-ascii" On Mon, Aug 17, 2026, Binbin Wu wrote: > On 8/15/2026 12:11 AM, Sean Christopherson wrote: > > Move vmx_handle_exit_irqoff() and its helpers to common.h / main.c to > > capture that it's a common handler and to allow guarding against incorrectly > > using to_vmx(), and to allow for > ^ > It appears to have been abruptly truncated here? Ya, apparently I saw something shiny and forgot to get back to this. In hindsight, I probably should have spammed v2 right away given how egregious some of these goofs were, it probably would have been a net positive. Anyways, this is what I ended up with for a full changelog: KVM: VMX: Move the shared "IRQs off" exit handler(s) to common code Move vmx_handle_exit_irqoff() and its helpers to common.h / main.c to capture that it's a common handler and to allow guarding against incorrectly using to_vmx(). Opportunistically use a "vt" prefix instead of "vmx" to communicate that it's a shared handler. No functional change intended. > > Cc: Rick Edgecombe > > Cc: Xiaoyao Li > > Cc: Binbin Wu > > Cc: Kai Huang > > Cc: Yan Zhao > > Signed-off-by: Sean Christopherson > > [...] > > > + > > +static void vmx_handle_exit_irqoff(struct kvm_vcpu *vcpu) > > Since it's moved to the common code, is it better to rename it > to vt_handle_exit_irqoff()? Yeah, Sashiko pointed out that I was being dense as well.