Received: by 2002:ac0:da4c:0:0:0:0:0 with SMTP id a12csp742750imi; Thu, 21 Jul 2022 10:03:14 -0700 (PDT) X-Google-Smtp-Source: AGRyM1v7LWnVCU0dGVnHHPNnu+pDLuv6GSNdHKzdwPg2nHKlBAxB6DkKmmoOnaZ7lv831ZVdGoWJ X-Received: by 2002:a17:90b:4c4a:b0:1f1:f3d2:d3db with SMTP id np10-20020a17090b4c4a00b001f1f3d2d3dbmr12201241pjb.202.1658422993891; Thu, 21 Jul 2022 10:03:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1658422993; cv=none; d=google.com; s=arc-20160816; b=t6376blxV6b//3/da7IkARoBTk5Ha3QO1D7lVExwm+dMKPzMuku8xvbBxfSi8lm9t3 B9NmNhnyP2HdUxcmQJ0NN0N2gL6DLRxa9QDHv3W8b+WYdtzjk3RAbon/+Ar1kGjPDdoM 62ucXTIkyF+anFlwOUNAj5Z/HNS0eCUzm0mcFBLFcXZAVJEAnI9dY66COPANEujhTpPa JCobkO+SoMHRj5EOOemk3ajUE/sZtOduFuhzCR/MXZxK39C2iLUhyJ+Yfi8HzVrxIzST JKH4hiyzQlzSenYEVe8r/YoDLGWZfbDDt+p2dEjHB5nDZb7dFrC75WqIZ1BqxJPb7AmN 9U6Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=zvoOq7oOR3wU+68pP4QhTThXsOMtlR68j6zg+myY2cM=; b=PusZ/hIZtm1oBk6SJG5QiRYeewreD7/VvxOn2J6Yw3plE2pp/QKJbO0x5NRrSXmFar MUXTT6MyZrAkuueVqNKh6kr80h5JXVG7jxXGQ3sVYeT7u2cWXuvfkbG4PWERFV6HDfzS kn36YEhruxL83EY9A4+T1QFP2TYsv4ybsh+Qp0c+uFnx4x2HNBebfcgPwtWS798OLtwR hphYT6rc7ed85881ujT2BV+Kx3e8XtbP+dch+ajPGb/54RInAEoN7tEH41FQh1IPB1LE QHFOkv4ix9BVzn+Usw1UgmKbg/OnuRoK0KiFbBbWploFldKCavsRpt5nCXhJJGs3s4Px tImg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=alg1LsIT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y1-20020a634b01000000b00419dc0c2d71si2761789pga.115.2022.07.21.10.02.58; Thu, 21 Jul 2022 10:03:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=alg1LsIT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232525AbiGUQtK (ORCPT + 99 others); Thu, 21 Jul 2022 12:49:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53270 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232490AbiGUQtG (ORCPT ); Thu, 21 Jul 2022 12:49:06 -0400 Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2D42A8812E for ; Thu, 21 Jul 2022 09:49:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1658422146; x=1689958146; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=3bbPDMQI859gWFZ/CAYf4oPUAKhL1F/jX/zsW+laJyc=; b=alg1LsITR/aruPzXQ3nNqXLPLGvInDhSscy7fHm3Oj2+HtQAJ1bL2QVf eNTRlg5z6lioUUGQM3mVI8Q168VmxUIGC7i4TPXlXWkS0iFBuMfbU+Xm2 IXTIDX2uiAr+6Tbe+6giSa51VxfK/U0fD6IJIcgI0hadch91sMtVSlhJu 4YmX8MI88/j5tKnhP8Ro4UGoInzEDzgGxzcA9OldsmZxkwi/Pmy029OJO he5++AMQ+8QlflCyIa5pXzajBhHMbjTQ5NsN2Y+4trL5ikRw73SwasEdC zYn+kwUcSysI+cLgIN+RTtIfhi+co4GEzOl3wp6rTwcNaeRJkLqGWALDi Q==; X-IronPort-AV: E=McAfee;i="6400,9594,10415"; a="285866216" X-IronPort-AV: E=Sophos;i="5.93,183,1654585200"; d="scan'208";a="285866216" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Jul 2022 09:49:05 -0700 X-IronPort-AV: E=Sophos;i="5.93,183,1654585200"; d="scan'208";a="573816219" Received: from vasantgx-mobl.amr.corp.intel.com (HELO [10.212.244.191]) ([10.212.244.191]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Jul 2022 09:49:04 -0700 Message-ID: <214e24f0-5236-be8d-024a-da48737d854a@intel.com> Date: Thu, 21 Jul 2022 09:49:03 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: [PATCH v8 5/5] x86/tdx: Add Quote generation support Content-Language: en-US To: Sathyanarayanan Kuppuswamy , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org Cc: "H . Peter Anvin" , "Kirill A . Shutemov" , Tony Luck , Andi Kleen , Kai Huang , 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 References: <20220609025220.2615197-1-sathyanarayanan.kuppuswamy@linux.intel.com> <20220609025220.2615197-6-sathyanarayanan.kuppuswamy@linux.intel.com> From: Dave Hansen In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-5.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 7/21/22 09:42, Sathyanarayanan Kuppuswamy wrote: > On 7/21/22 9:08 AM, Dave Hansen wrote: >> On 6/8/22 19:52, Kuppuswamy Sathyanarayanan wrote: >>> For shared buffer allocation, alternatives like using the DMA API is >>> also considered. Although it simpler to use, it is not preferred because >>> dma_alloc_*() APIs require a valid bus device as argument, which would >>> need converting the attestation driver into a platform device driver. >>> This is unnecessary, and since the attestation driver does not do real >>> DMA, there is no need to use real DMA APIs. >> Let's actually try to walk through the requirements for the memory >> allocation here. >> >> 1. The guest kernel needs to allocate some guest physical memory >> for the attestation data buffer > Physically contiguous memory. Remind me how large the quote structures are.