Received: by 2002:a05:6520:2586:b029:fa:41f3:c225 with SMTP id u6csp22333lky; Wed, 9 Jun 2021 14:45:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxtJ2MlEi/EUC3MjLnxGal3W77wbgX/9dyZTjlPX+ZgS9z76dETN+7rniMXIulNygzWD2RI X-Received: by 2002:a05:6402:4cf:: with SMTP id n15mr1478657edw.162.1623275106920; Wed, 09 Jun 2021 14:45:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623275106; cv=none; d=google.com; s=arc-20160816; b=XNb6hDdY5INttD8lUbvvncvLVyMupvvwU6Xd3HRndZEyhU5fYDeHH/05fD85y36VW4 Ak8RVB/lZdQJ0XEe8AoFWKLil38GR/j3V/A7z+X6kqjcx6PPD7n56divZkoQJ7KdEWb3 Y9/t4ZvbKL6g7LoMq+TcbZLDfugetRVAMYLc6UDLjVWwu7RMPr5HAmpgFg19nNIYEZUP 5th+w1vLAFwFsbhO0V9L99wAEklvY3e8t+brYXJ3Cda7JNuM8CbDvC8WbqMaEbNtS1AR WLXH+lIrTpyOh2aWm6TEHoFkcmISH3k3+ZskaKXyyFiP9SJia2zIM4/8EFmNxS9psVdb dybw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:ironport-sdr:ironport-sdr; bh=8usC4nSuiCZjJ1JXLD590UO7oWQYkJoqoUsFpKeyKwc=; b=MFR7PWLLzSEAxBvz56vjsPrQ7WYHLp0cbDhOp/S7fITrXm3vLHgDe2s9kBvuEk/ZrE feNOGt/5zg66ZCcrhMu301x9HM5THqQlRARgr2N7GtPxcbkG3ijO6XPSKlbX4jo0ETFU Ff3UUW0jB67HaWzNXIBJGJGmHK88Lm4lzNiEbYDbCvz4iayTq3Jxxstwh0Y6SMlNWwPA lhk/SBCK31frNbapN/LD9CCzTcKHBvEcRRd4FnbsnYFqSalbF9HNTXjKWZYuPXm+1t1E YM9HLiPkURw7ceV2godqqLfWD/gg85DDn4WrfTx5GScS/xwujGE9/g3mkb67DYwKvtVL A21A== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m4si725359edq.47.2021.06.09.14.44.43; Wed, 09 Jun 2021 14:45:06 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229638AbhFIVog (ORCPT + 99 others); Wed, 9 Jun 2021 17:44:36 -0400 Received: from mga11.intel.com ([192.55.52.93]:60077 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229517AbhFIVof (ORCPT ); Wed, 9 Jun 2021 17:44:35 -0400 IronPort-SDR: ykykX7IhucxrJmkwCZ1qFC+TUKKZfEKh0QcIRPAUZuzjkzRX7voEGYc3MEDG/6AbhrIMmoWMeg hvsTgnCvkNCg== X-IronPort-AV: E=McAfee;i="6200,9189,10010"; a="202150765" X-IronPort-AV: E=Sophos;i="5.83,261,1616482800"; d="scan'208";a="202150765" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Jun 2021 14:42:40 -0700 IronPort-SDR: 8lJ90QieKXiF2nbXI6rgmJp7jaYGkh6iProettwo8D0QW/OZGUiG7AnZpqIEB4lekubnI6zmHn Vcvq3MyAXtyw== X-IronPort-AV: E=Sophos;i="5.83,261,1616482800"; d="scan'208";a="402579860" Received: from davidhok-mobl3.amr.corp.intel.com (HELO skuppusw-mobl5.amr.corp.intel.com) ([10.209.9.9]) by orsmga003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Jun 2021 14:42:39 -0700 Subject: Re: [RFC v2-fix-v5 1/1] x86: Skip WBINVD instruction for VM guest To: Dan Williams , Dave Hansen Cc: Peter Zijlstra , Andy Lutomirski , Tony Luck , Andi Kleen , Kirill Shutemov , Kuppuswamy Sathyanarayanan , Raj Ashok , Sean Christopherson , Linux Kernel Mailing List References: <973add45-9fd2-7abc-3a97-96a26c263ea0@linux.intel.com> <20210609194926.1949859-1-sathyanarayanan.kuppuswamy@linux.intel.com> <7c06b567-9a65-8c7c-6046-3dcb32d4bb15@intel.com> From: "Kuppuswamy, Sathyanarayanan" Message-ID: <2184400d-856e-ed4c-b23d-77b7dfd72658@linux.intel.com> Date: Wed, 9 Jun 2021 14:42:37 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/9/21 2:38 PM, Dan Williams wrote: >> In TDX guests, these WBINVD operations cause #VE exceptions. For debug, >> it would be ideal for the #VE handler to be able to WARN() when an >> unexpected WBINVD occurs. (<--- problem #2) > ...but it doesn't WARN() it triggers unhandled #VE, unless I missed > another patch that precedes this that turns it into a WARN()? If a > code path expects WBINVD for correct operation and the guest can't > execute that sounds fatal, not a WARN to me. Yes. It is not WARN. It is a fatal unhandled exception. > -- Sathyanarayanan Kuppuswamy Linux Kernel Developer