Received: by 2002:a05:6358:e9c4:b0:b2:91dc:71ab with SMTP id hc4csp2163300rwb; Fri, 5 Aug 2022 14:42:13 -0700 (PDT) X-Google-Smtp-Source: AA6agR63NOd2L2jvJ1j86eRkxHiFIbUouZZZYBraXyh6Ehb0avzqh6GAk9u0ZzjKkVY64fxd6oEL X-Received: by 2002:a17:906:8a49:b0:730:b15e:f8d2 with SMTP id gx9-20020a1709068a4900b00730b15ef8d2mr6241578ejc.694.1659735733252; Fri, 05 Aug 2022 14:42:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659735733; cv=none; d=google.com; s=arc-20160816; b=Y11BuDCLQTelA63LIYJfhziOVIpCAM5pH8YnyCIlFfyZipSwP4iHFHyt/H0Lrz/gW9 eSlpegN9OeqcuTRFsaudUIPNFy3POum+qdpc9WGmco+ubcDVpUtra/bD2RmAK24b9aL2 VHH4Dgxdi0Mw0d98L6Uc/SKMJ+lBRigO5ly/3gTiX77XvPWmWWP40nEP0klmwSfynCqC nMGdQnHMhlIt2VQFlpNPy5hJk0Ukxcy+j5DXxxH/Hi6y8F8WXkUFo2xiGvzeazxXPTMv kYN5PpHQMRvhO5Ll/M5SwHQxIyjtnpRXfuaXWOgTzn/yD72q5wiSyxUi9CLqKmdxzdZa NjTA== 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=k6S+Ya99qcGGZRuNKIv8OoAaBrGds5laGdoIGIcoS50=; b=dSbaoAye9gp6wSn758zpEGPzv82r7GU19/AUcPTBW3vsxMbDlm69ceeORW5xlfompG GRPW38X9GQGhqHKpNNk4ZtFhAWaNt98r/ZKm8X1QrqxBh/H2eqD7koezkHz/Hjomyqyd aCHk/3efz5p4yEbg6pRokpbeII965rme6YeJ7AOmGaD4xpp2XgT02hYdCSUPfNNJ6xbS oB9CUalEm4HzNI0xqQ4RLfnn1NzmD6O1kUbTpTntyEsp9RDPXO5ao/KHyPpEvsZweJpn j4acTmJCw34oaXmIvYQ/swINNHhcP1FXcnyYBmQPIDn4fPIQ1EyVhVRq8isJKwbdrRD4 g+oA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=W8MCIZH5; 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 nd19-20020a170907629300b00726d06852aesi5085380ejc.36.2022.08.05.14.41.48; Fri, 05 Aug 2022 14:42: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=W8MCIZH5; 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 S237641AbiHEVfj (ORCPT + 99 others); Fri, 5 Aug 2022 17:35:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58452 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232791AbiHEVfi (ORCPT ); Fri, 5 Aug 2022 17:35:38 -0400 Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 63DAE1BEB1 for ; Fri, 5 Aug 2022 14:35:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1659735337; x=1691271337; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=NI2IRvyfOoWq4JSbf+Tm9Tq9Lq/erdU7EpivOdyuVNA=; b=W8MCIZH59tmrhS/IV7irU1Jzpuk1oqQTXbKDY8u21WFEDkW6k69cPUCL OdHhSwNegyibbs8tTKbb8vGXnwTBEcP3dWEl2He30nx5MU7Smrl1EhPy0 +ExZGGIDG1DE6+YpKNFld/U3UK+wI2jGKbMPyp8mynOHCy4KSQ0FtVr4Y qJ7m4aj1Oi0vc/9f1WVcM2ijpf8eBecU0qneRdXWjCcrNsnIvZxET1tlB zNI3lcGaY9y3cExgWyeMZ/91VIvj3HrE3s3jtRoncWGDj7g4jWCVfGBie +TbwE7ggd9VJOByXUBNi4cuS2NqbaaEEezRb3aG/dehkzaffmBXD8zsNI Q==; X-IronPort-AV: E=McAfee;i="6400,9594,10430"; a="277220814" X-IronPort-AV: E=Sophos;i="5.93,216,1654585200"; d="scan'208";a="277220814" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Aug 2022 14:35:36 -0700 X-IronPort-AV: E=Sophos;i="5.93,216,1654585200"; d="scan'208";a="931369220" Received: from shihhanw-mobl1.amr.corp.intel.com (HELO [10.212.148.224]) ([10.212.148.224]) by fmsmga005-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Aug 2022 14:35:35 -0700 Message-ID: <3075adc7-e02e-fcd4-44ef-c4228293f460@linux.intel.com> Date: Fri, 5 Aug 2022 14:35:35 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Firefox/91.0 Thunderbird/91.11.0 Subject: Re: [PATCH v10 1/2] x86/tdx: Add TDX Guest attestation interface driver Content-Language: en-US To: Wander Lairson Costa Cc: Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, "H . Peter Anvin" , "Kirill A . Shutemov" , Tony Luck , Andi Kleen , Kai Huang , Isaku Yamahata , marcelo.cerri@canonical.com, tim.gardner@canonical.com, khalid.elmously@canonical.com, philip.cox@canonical.com, linux-kernel@vger.kernel.org References: <20220804003323.1441376-1-sathyanarayanan.kuppuswamy@linux.intel.com> From: Sathyanarayanan Kuppuswamy In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.9 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_MED, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE 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 8/5/22 12:47 PM, Wander Lairson Costa wrote: > On Wed, Aug 03, 2022 at 05:33:22PM -0700, Kuppuswamy Sathyanarayanan wrote: >> +/** >> + * struct tdx_report_req: Get TDREPORT using REPORTDATA as input. >> + * >> + * @subtype : Subtype of TDREPORT (fixed as 0 by TDX Module >> + * specification, but added a parameter to handle >> + * future extension). >> + * @reportdata : User-defined REPORTDATA to be included into >> + * TDREPORT. Typically it can be some nonce >> + * provided by attestation service, so the >> + * generated TDREPORT can be uniquely verified. >> + * @rpd_len : Length of the REPORTDATA (fixed as 64 bytes by >> + * the TDX Module specification, but parameter is >> + * added to handle future extension). >> + * @tdreport : TDREPORT output from TDCALL[TDG.MR.REPORT]. >> + * @tdr_len : Length of the TDREPORT (fixed as 1024 bytes by >> + * the TDX Module specification, but a parameter >> + * is added to accommodate future extension). >> + * >> + * Used in TDX_CMD_GET_REPORT IOCTL request. >> + */ >> +struct tdx_report_req { >> + __u8 subtype; >> + __u64 reportdata; >> + __u32 rpd_len; >> + __u64 tdreport; >> + __u32 tdr_len; >> +}; > > Any reason why reportdata and tdreport aren't "void *"? It is the recommended way to pass the pointers. https://docs.kernel.org/driver-api/ioctl.html > >> + > -- Sathyanarayanan Kuppuswamy Linux Kernel Developer