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=-13.3 required=3.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_IN_DEF_DKIM_WL autolearn=no 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 5C89EC47084 for ; Tue, 25 May 2021 00:16:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 398C661420 for ; Tue, 25 May 2021 00:16:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229837AbhEYARa (ORCPT ); Mon, 24 May 2021 20:17:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52548 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229724AbhEYAR3 (ORCPT ); Mon, 24 May 2021 20:17:29 -0400 Received: from mail-ot1-x32e.google.com (mail-ot1-x32e.google.com [IPv6:2607:f8b0:4864:20::32e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3F443C061574 for ; Mon, 24 May 2021 17:16:01 -0700 (PDT) Received: by mail-ot1-x32e.google.com with SMTP id 69-20020a9d0a4b0000b02902ed42f141e1so26933429otg.2 for ; Mon, 24 May 2021 17:16:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=1QLVvyqxVOa/mtzZxUM6jA3sXjNPTa5b5e6kLiT/T9U=; b=cRUPv9f8BvBWYi60DTkohK+SNsGnDVtcWSqmn5XqynRjNtg2NstnYwWGobFZJa2gIl LXy51yaGKBtDDJqs2c49YNtBzCiIRmVSTKItXAzIyUior671QWhIRoEQ++On4APsoPVP qD1hEeNb+jqODJkJHt/Xtkdk4r1/+VvzLwMmA0tIPQFIGoRkEY0caKNhwQjZUfFqEyLs ugp1mnIFb8lXqDEq6AMiMq0HTEnAfYICUW4sP9oaTFJf7PJyKjfvgYE6objvw385ACaL 084F+VMlOT5Hf6AkDuZNW+WH5lP+nXqR/vl1tnM7ewBh+lABFn4g9G9jNCR1tNNV5Ygu 2tKw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=1QLVvyqxVOa/mtzZxUM6jA3sXjNPTa5b5e6kLiT/T9U=; b=EVf8f24W0WUB0YXHfSVmxxd5atKbMFbwbwQzB1R691XOf14tMim+FevOK8E4U+xYU8 fsg6YZ9/xIMMnKKtK4AVEJ8DOplZo9poNy6wH1MgpesqDpLIa789N+7JSni63lwEysfK uAJE5Ifa3jNSIUpSE4Xq2DCSDrjkabu2HT/J+U4RzqwGT1yH7XVy3DufAKEzwW5/gL3N Z0VG55otcv2O+KxWSL82eOwcC3RNq6rOI2NsA1zMlDfJXLqFFuTRBH3/owgEb8+SN5ca /CAAKgG6lnDW0MX+cAUczgbAu992Bipv5entbNhPCzpOnbNErN8C6HMEn/woD54oVQHC D4zw== X-Gm-Message-State: AOAM532gFudwTs1nSnEuBfFZsas4ohjimRFB+jn/9PWv98EVEfWIFVDO eZKD5MS/5igliMzP3k54LyJDhH9P+fD0hb9JczP7Cw== X-Google-Smtp-Source: ABdhPJxYfaPRPvsbsdMA6+gait8XjTeknj+6xDfj123jodCoKcFiLuZkxAc9fCqPjT8noAp65fnaz5PinpQm3Y9D1p4= X-Received: by 2002:a9d:684e:: with SMTP id c14mr20959920oto.295.1621901760391; Mon, 24 May 2021 17:16:00 -0700 (PDT) MIME-Version: 1.0 References: <20210520230339.267445-1-jmattson@google.com> <20210520230339.267445-8-jmattson@google.com> In-Reply-To: From: Jim Mattson Date: Mon, 24 May 2021 17:15:49 -0700 Message-ID: Subject: Re: [PATCH 07/12] KVM: nVMX: Disable vmcs02 posted interrupts if vmcs12 PID isn't mappable To: Sean Christopherson Cc: kvm list , Paolo Bonzini Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org On Mon, May 24, 2021 at 5:11 PM Sean Christopherson wrote: > > Can we instead word it along the lines of: > > Defer the KVM_INTERNAL_EXIT until KVM actually attempts to consume the posted > interrupt descriptor on behalf of the vCPU. Note, KVM may process posted > interrupts when it architecturally should not. Bugs aside, userspace can at > least rely on KVM to not process posted interrupts if there is no (posted?) > interrupt activity whatsoever. How about: Defer the KVM_INTERNAL_EXIT until KVM tries to access the contents of the VMCS12 posted interrupt descriptor. (Note that KVM may do this when it should not, per the architectural specification.)