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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0E531C71153 for ; Mon, 11 Sep 2023 00:10:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231511AbjIKAKS (ORCPT ); Sun, 10 Sep 2023 20:10:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47174 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229453AbjIKAKQ (ORCPT ); Sun, 10 Sep 2023 20:10:16 -0400 Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.43]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 566B018B for ; Sun, 10 Sep 2023 17:10:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1694391012; x=1725927012; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=rs2RXPgE6FibMswDpiAFeGDRmtHImZ+Q9AaGonFjS3M=; b=VRgSQjMgZwxFbEd4gy5haaeXQGLYZ55sb6G8xyMO/dQRF2WpWYbHImiA 8JSM2zAsCFn7xJQnc9GGYY9QcU98BcfUbwiiBvKGmgj9COb9MrGMM8R4u KqqZ5OZi7mtqtuEouxOYaK7vt+CPeNTX78cLZZwmaENWUY0iW1ll+t8pH uMbw6zcay+HQSEkFYLOud44WPzmczKn9/W8OEIq8Q2NdwSSOIxsmikQhs hnA/4e451WX0VdVAnTp6DShg8ILcqv/lCelM2a07u2QyGz4mkRQizOteQ zrJ2zOP2K7wNen2B13SwkujHAvJkk06qd3vOVKyE6ORTR5Jg0BcROwAZ9 g==; X-IronPort-AV: E=McAfee;i="6600,9927,10829"; a="464332745" X-IronPort-AV: E=Sophos;i="6.02,243,1688454000"; d="scan'208";a="464332745" Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 Sep 2023 17:10:11 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10829"; a="813180999" X-IronPort-AV: E=Sophos;i="6.02,243,1688454000"; d="scan'208";a="813180999" Received: from rmanijac-mobl.amr.corp.intel.com (HELO [10.209.66.44]) ([10.209.66.44]) by fmsmga004-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 Sep 2023 17:10:11 -0700 Message-ID: <2371c186-ccd4-48c7-b302-e289adb30dec@linux.intel.com> Date: Sun, 10 Sep 2023 17:10:10 -0700 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v1] virt: tdx-guest: Add Quote generation support using TSM_REPORTS Content-Language: en-US To: Dan Williams , "Huang, Kai" , "tglx@linutronix.de" , "mingo@redhat.com" , "bp@alien8.de" , "dave.hansen@linux.intel.com" Cc: "Yu, Guorui" , "qinkun@apache.org" , "wander@redhat.com" , "hpa@zytor.com" , "linux-kernel@vger.kernel.org" , "kirill.shutemov@linux.intel.com" , "Aktas, Erdem" , "Luck, Tony" , "linux-coco@lists.linux.dev" , "dionnaglaze@google.com" , "x86@kernel.org" References: <20230907025405.2310931-1-sathyanarayanan.kuppuswamy@linux.intel.com> <64fb499862936_7318294a0@dwillia2-mobl3.amr.corp.intel.com.notmuch> From: Kuppuswamy Sathyanarayanan In-Reply-To: <64fb499862936_7318294a0@dwillia2-mobl3.amr.corp.intel.com.notmuch> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 9/8/2023 9:19 AM, Dan Williams wrote: >>> Changes since previous version: >>> * Used ConfigFS interface instead of IOCTL interface. >>> * Used polling model for Quote generation and dropped the event notification IRQ support. >> Can you elaborate why the notification IRQ is dropped? > Because it was a pile of hacks and non-idiomatic complexity. It can come > back when / if driver code can treat it like a typical interrupt. Currently, the VMM assumes that the vCPU that executes the TDG.VP.VMCALL hypercall as the target vCPU for event notification IRQ. To satisfy this assumption, the guest driver that uses this hypercall/IRQ had to include CPU/IRQ affinity related code changes. This adds unnecessary complication to the guest driver code without any real ARCH need or benefit. So we want to modify the GHCI ABI to let TD guest pass the target CPU as an argument. With this change, we can hide the IRQ related configuration in the IRQ chip code and let the guest driver treat the event notification IRQ as a regular interrupt. -- Sathyanarayanan Kuppuswamy Linux Kernel Developer