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 0E008C433F5 for ; Tue, 10 May 2022 01:40:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234300AbiEJBoK (ORCPT ); Mon, 9 May 2022 21:44:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38630 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230407AbiEJBoH (ORCPT ); Mon, 9 May 2022 21:44:07 -0400 Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E42DD2BB1B for ; Mon, 9 May 2022 18:40:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1652146811; x=1683682811; h=message-id:subject:from:to:cc:date:in-reply-to: references:mime-version:content-transfer-encoding; bh=DR3wN2x6Pr5dYK0lRzAW/+NtoVTIzkGo2sj/9c7Y7Ek=; b=Mq6yP3K7I5ZWSgzLH2Z0By77/thfOZqdfsb4Y2of4k86MuwGmHRZrR/i gm/nwKAEYovMvUZA/hlcgG2dgmORiIAsUczHO6b29pRFeazTPu4Q5Wp5j e16ui/0Tb+lbx4HQcjT7F0FobHd6kXqK17HrVlyrZwX0ILfepwef6lGq+ 3O8KtAtar+6ioirOtbnzjiUdkMPMXD0LSPjdOOOSoKDqk+4wSObdFegJl GR4zDUwY09pLtK/pVjqqxv667D15KSvd+Xw6jR9fAHLvoNBSCGJWL+SEc JEUriaOnLr+qv2Dio5ZPVo08LRTNWJWAypIiLPCQJfNlNrV7MW4lQ7KYE Q==; X-IronPort-AV: E=McAfee;i="6400,9594,10342"; a="266814670" X-IronPort-AV: E=Sophos;i="5.91,213,1647327600"; d="scan'208";a="266814670" Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 May 2022 18:40:11 -0700 X-IronPort-AV: E=Sophos;i="5.91,213,1647327600"; d="scan'208";a="813744001" Received: from abehrenx-mobl1.amr.corp.intel.com (HELO khuang2-desk.gar.corp.intel.com) ([10.254.1.104]) by fmsmga006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 May 2022 18:40:07 -0700 Message-ID: <7cadc7777238a50dec4c18119e1c68fd3c5cfe96.camel@intel.com> Subject: Re: [PATCH v5 3/3] x86/tdx: Add Quote generation support From: Kai Huang To: "Kirill A. Shutemov" Cc: "Kirill A. Shutemov" , Dave Hansen , Sathyanarayanan Kuppuswamy , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, "H . Peter Anvin" , Tony Luck , Andi Kleen , Wander Lairson Costa , Isaku Yamahata , marcelo.cerri@canonical.com, tim.gardner@canonical.com, khalid.elmously@canonical.com, philip.cox@canonical.com, linux-kernel@vger.kernel.org Date: Tue, 10 May 2022 13:40:05 +1200 In-Reply-To: <20220510013038.ggubvsrwf7pyoamk@box.shutemov.name> References: <40ccd0f0-35a1-5aa7-9e51-25ab196d79e5@linux.intel.com> <2ed5c9cc316950a5a47ee714715b7980f358a140.camel@intel.com> <20220507004236.5p5dyksftge7wwr3@black.fi.intel.com> <45d184273f1950320843f6696eb3071f7d354fd3.camel@intel.com> <20220509120927.7rg6v5pyc3f4pxsh@box.shutemov.name> <75d4755c9a376df2e98a267e10e60da3bd178b17.camel@intel.com> <20220510013038.ggubvsrwf7pyoamk@box.shutemov.name> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.42.4 (3.42.4-1.fc35) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2022-05-10 at 04:30 +0300, Kirill A. Shutemov wrote: > On Tue, May 10, 2022 at 11:54:12AM +1200, Kai Huang wrote: > > On Mon, 2022-05-09 at 15:09 +0300, Kirill A. Shutemov wrote: > > > On Mon, May 09, 2022 at 03:37:22PM +1200, Kai Huang wrote: > > > > On Sat, 2022-05-07 at 03:42 +0300, Kirill A. Shutemov wrote: > > > > > On Fri, May 06, 2022 at 12:11:03PM +1200, Kai Huang wrote: > > > > > > Kirill, what's your opinion? > > > > > > > > > > I said before that I think DMA API is the right tool here. > > > > > > > > > > Speculation about future of DMA in TDX is irrelevant here. If semantics > > > > > change we will need to re-evaluate all users. VirtIO uses DMA API and it > > > > > is conceptually the same use-case: communicate with the host. > > > > > > > > Virtio is designed for device driver to use, so it's fine to use DMA API. And > > > > real DMA can happen to the virtio DMA buffers. Attestation doesn't have such > > > > assumption. > > > > > > Whether attestation driver uses struct device is implementation detail. > > > I don't see what is you point. > > > > No real DMA is involved in attestation. > > As with VirtIO. So what? > No real DMA can happen to virtio buffer. Consider DPDK which uses virtio + vhost-user. But I don't want to argue anymore about this topic. :) -- Thanks, -Kai