Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp189290rdb; Tue, 5 Dec 2023 02:39:40 -0800 (PST) X-Google-Smtp-Source: AGHT+IGNaDavptq+eUbh46fGpnfXP4dsZiriu3BysppLLIkhe+80Sxu/5MbxrowH/YF6bK7y4qSo X-Received: by 2002:a05:6870:1602:b0:1fb:36b:59ed with SMTP id b2-20020a056870160200b001fb036b59edmr6466164oae.13.1701772780451; Tue, 05 Dec 2023 02:39:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701772780; cv=none; d=google.com; s=arc-20160816; b=xxolX7TjyThIhTMckW/SjkLTGGQfCubNfp8xTHDrlBbEVng1+KpC/DLNzgDCV0Am3P 0BmiL+adD2crh/0gMVgZ5lj6E8TOKW3bthPQiZN04mUXTbvpY17S19V41fSRRx++0+hN SKb41bhWBwyFyLRjYD0FgSYVCwbAJlSJk6igkF7CNbdtzyinVkHflMokwVxWTeZyf7BK z8E/5Jwo5smTdex1tuSOJZwlvBdo+nDpHQZFsS8dFqk1UChZALBfCaDCKfKd7oE4JwST d0Pfcl/AAzsmIANgmUAuOL49wWZF7nzamYAx/8U4aIbkF6l9MG8bf2vZpsZ0AjCoXy94 x6qg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=EsQ/ScQJftZQ38BrXkVofNWM2kNPQwbMRUJ0a1EdV7M=; fh=N2PMIgUB1WENx8VVMRFY1EHLciTqX2wQ6sXFWT4E2R4=; b=RrbTID78XR6CwgfM5HrFfQx6WLHf4oMGwf+n4yJ/EsakjUnUv134y66x0Wv9FyKZSP tchEn3nNbMI1wpWMKrRv0dOSx+GjDwNWhdiABlCfjrG/Y3SHKabetV1Oi63WnPcHVfZv eUWFgADxuqGrqaKO01bjeFJ61lt95vl+OQXoO2pfltvA0wYgZV+fQ92xSwtxXd2AZtVf Kv4fxp6csCOhYrn4EFX/6SnEzbS6kfZfK5saZ1NMSmP0KgUz6s/ulrvBJdO70jeDpH35 NjCwVlgIYK166IABBgG3Td7Acfu92d9FZ+jrjeTwi/l5hoB/l9fe/o7+E6L6ODmXs2aX tP5A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=OfReK5YH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id b7-20020a636707000000b005c65ee2abaesi5375970pgc.219.2023.12.05.02.39.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Dec 2023 02:39:40 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=OfReK5YH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 7D2EF80A417D; Tue, 5 Dec 2023 02:39:37 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346582AbjLEKin (ORCPT + 99 others); Tue, 5 Dec 2023 05:38:43 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46872 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235112AbjLEKia (ORCPT ); Tue, 5 Dec 2023 05:38:30 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7FB561711 for ; Tue, 5 Dec 2023 02:37:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1701772672; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=EsQ/ScQJftZQ38BrXkVofNWM2kNPQwbMRUJ0a1EdV7M=; b=OfReK5YHyAFRefDWG67UoOutdP/g7oSQWSlp0I+9YebKcCmX5ye0l5G5AaT0W4uKWzzUv1 OrwyTKiBYeQ2f0Q4BpXbJGdw8gqDB3PZ1/B7Am6JuY1Ex/V9PP6IgayxNvUFUrxuJz+bZu QDE9ZtUGUWC46g/v6YxnoS8JTGRvzoQ= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-280-QCBqOJBcMhinqUqTnoYdWA-1; Tue, 05 Dec 2023 05:37:49 -0500 X-MC-Unique: QCBqOJBcMhinqUqTnoYdWA-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.rdu2.redhat.com [10.11.54.8]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 0BF5283B825; Tue, 5 Dec 2023 10:37:49 +0000 (UTC) Received: from localhost.localdomain (unknown [10.45.225.152]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2241EC15968; Tue, 5 Dec 2023 10:37:45 +0000 (UTC) From: Maxim Levitsky To: kvm@vger.kernel.org Cc: Sean Christopherson , Dave Hansen , Ingo Molnar , x86@kernel.org, linux-kernel@vger.kernel.org, Paolo Bonzini , Borislav Petkov , Thomas Gleixner , "H. Peter Anvin" , Maxim Levitsky Subject: [PATCH v4 0/4] KVM: x86: tracepoint updates Date: Tue, 5 Dec 2023 12:37:41 +0200 Message-Id: <20231205103745.506724-1-mlevitsk@redhat.com> Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.8 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Tue, 05 Dec 2023 02:39:37 -0800 (PST) This patch series is intended to add some selected information=0D to the kvm tracepoints to make it easier to gather insights about=0D running nested guests.=0D =0D This patch series was developed together with a new x86 performance analysi= s tool=0D that I developed recently (https://gitlab.com/maximlevitsky/kvmon)=0D which aims to be a better kvm_stat, and allows you at glance=0D to see what is happening in a VM, including nesting.=0D =0D V4: addressed review feedback=0D =0D Best regards,=0D Maxim Levitsky=0D =0D Maxim Levitsky (4):=0D KVM: x86: refactor req_immediate_exit logic=0D KVM: x86: add more information to the kvm_entry tracepoint=0D KVM: x86: add information about pending requests to kvm_exit=0D tracepoint=0D KVM: x86: add new nested vmexit tracepoints=0D =0D arch/x86/include/asm/kvm-x86-ops.h | 2 +-=0D arch/x86/include/asm/kvm_host.h | 10 +--=0D arch/x86/kvm/svm/nested.c | 22 ++++++=0D arch/x86/kvm/svm/svm.c | 24 ++++++-=0D arch/x86/kvm/trace.h | 105 +++++++++++++++++++++++++++--=0D arch/x86/kvm/vmx/nested.c | 27 ++++++++=0D arch/x86/kvm/vmx/vmx.c | 30 +++++----=0D arch/x86/kvm/vmx/vmx.h | 2 -=0D arch/x86/kvm/x86.c | 34 +++++-----=0D 9 files changed, 209 insertions(+), 47 deletions(-)=0D =0D -- =0D 2.26.3=0D =0D