From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 59A50C433EF for ; Mon, 20 Sep 2021 12:05:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 47C0D6109E for ; Mon, 20 Sep 2021 12:05:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234896AbhITMHL (ORCPT ); Mon, 20 Sep 2021 08:07:11 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:52873 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229848AbhITMHI (ORCPT ); Mon, 20 Sep 2021 08:07:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1632139541; 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: in-reply-to:in-reply-to:references:references; bh=q8wAH/IsmVnI2ydhQ1BFoaOBGT1C6T31sGkkhWrMszg=; b=E5O5IYb3E/Ra/xlxED0QOc8QrPeCDxCsIi9ztHhZjYBOh6ejFUGPudbBXxiS/wHIdenNep qIFlUvG5zJwA+fqK3RXonYrssqDunAdP9q4HaYuW0GkV6Qxp86eISEvTcccX4DFIPFEpFG Kuo6tHq2RiDnvU1gHyMflYXobeoveWY= Received: from mail-wr1-f72.google.com (mail-wr1-f72.google.com [209.85.221.72]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-209-Fc3RLvhNMf6k5SkzQmI0zg-1; Mon, 20 Sep 2021 08:05:40 -0400 X-MC-Unique: Fc3RLvhNMf6k5SkzQmI0zg-1 Received: by mail-wr1-f72.google.com with SMTP id c15-20020a5d4ccf000000b0015dff622f39so5874623wrt.21 for ; Mon, 20 Sep 2021 05:05:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:to:cc:references:from:subject:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=q8wAH/IsmVnI2ydhQ1BFoaOBGT1C6T31sGkkhWrMszg=; b=sNakbQ6fbNlvwR/OEG6jzYqLz2i91KdfOx+o3k57ZlRELKmYSWYnv1JON5M59lMLbQ xCG9fMROo6mwhvFAZ2KvWFEx/1UAFO4sTZqHLw8nXX1ZtaMyCaKo3NaUdMufil7ERpp0 7awbPc9gE8fLuszcbYbd0/Fj0enG2+0U2MRi7jl6rFCK8dcX439BvuQylmLl732nz2Oz zpLIM2DmPMc1gWOYC8FsCYQBxQuCsTRrKn10B9NBiBS3bdbZAHQXXavj8lA6hRi+C7Y3 TMkHebXQWvWAQT+BJChF1K7zRPDKVERfncy6KqVCW8hRYkBvhvWNSM/6DT8O/7ZCbQWs E/Pw== X-Gm-Message-State: AOAM530XDQ2kbZPS59nqG8ckwQ4YwVGlCaWF4nlNDorbWYLos2n5hmoW LaG72eXIzRPYN4MbSIBTv//R8jWRF/aNRRb8AH8k+r79ehe9ekPVqBaYHEdtRIsc4V9HUG4zS3Q YWcIhxFd96q4iBVE4b7YvkpU5 X-Received: by 2002:a5d:4608:: with SMTP id t8mr28038950wrq.136.1632139538951; Mon, 20 Sep 2021 05:05:38 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz64XIPtY2fM12srCDcTMCwDqENNrjhBUdJzYmop3FKDPBAPZx+uh9ah7Isb2beeBqNbwRMJw== X-Received: by 2002:a5d:4608:: with SMTP id t8mr28038880wrq.136.1632139538580; Mon, 20 Sep 2021 05:05:38 -0700 (PDT) Received: from ?IPv6:2001:b07:6468:f312:c8dd:75d4:99ab:290a? ([2001:b07:6468:f312:c8dd:75d4:99ab:290a]) by smtp.gmail.com with ESMTPSA id l15sm19128605wme.42.2021.09.20.05.05.27 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 20 Sep 2021 05:05:37 -0700 (PDT) To: Peter Zijlstra , Sean Christopherson Cc: Ingo Molnar , Arnaldo Carvalho de Melo , Will Deacon , Mark Rutland , Catalin Marinas , Marc Zyngier , Guo Ren , Nick Hu , Greentime Hu , Vincent Chen , Paul Walmsley , Palmer Dabbelt , Albert Ou , Thomas Gleixner , Borislav Petkov , x86@kernel.org, Boris Ostrovsky , Juergen Gross , Alexander Shishkin , Jiri Olsa , Namhyung Kim , James Morse , Alexandru Elisei , Suzuki K Poulose , "H. Peter Anvin" , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Joerg Roedel , Stefano Stabellini , linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.cs.columbia.edu, linux-csky@vger.kernel.org, linux-riscv@lists.infradead.org, kvm@vger.kernel.org, xen-devel@lists.xenproject.org, Artem Kashkanov , Like Xu , Zhu Lingshan References: <20210828003558.713983-1-seanjc@google.com> <20210828201336.GD4353@worktop.programming.kicks-ass.net> From: Paolo Bonzini Subject: Re: [PATCH v2 00/13] perf: KVM: Fix, optimize, and clean up callbacks Message-ID: <662e93f9-e858-689d-d203-742731ecad2c@redhat.com> Date: Mon, 20 Sep 2021 14:05:25 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 17/09/21 09:28, Peter Zijlstra wrote: >> In theory, I like the idea of burying intel_pt inside x86 (and even in >> Intel+VMX code for the most part), but the actual implementation is a >> bit gross. Because of the whole "KVM can be a module" thing, > > ARGH!! we should really fix that. I've heard other archs have made much > better choices here. I think that's only ARM, and even then it is only because of limitations of the hardware which mostly apply only if VHE is not in use. If anything, it's ARM that should support module build in VHE mode (Linux would still need to know whether it will be running at EL1 or EL2, but KVM's functionality is as self-contained as on x86 in the VHE case). Paolo