Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp19275692rwd; Wed, 28 Jun 2023 07:20:02 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7nhWNk7JvD7cFCphKBvxL0FzVoYcWQzmtLROQ15HudURBGnVwZH6PEY3fd0XC2YmQhO79U X-Received: by 2002:a17:907:7e9c:b0:991:37d2:c9f0 with SMTP id qb28-20020a1709077e9c00b0099137d2c9f0mr9145163ejc.68.1687962002307; Wed, 28 Jun 2023 07:20:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687962002; cv=none; d=google.com; s=arc-20160816; b=AxoG4VI0+DlEpyzojUEzPz4gHoNuU6jGKjgwxLtscOPhPsgam9jHpXgwNeah0707ES nmDfLv7E1xQs7B9wI9NCAF3FM7qrV9CphIt9m+27w7P3XbgOCTN/vc6IfepHpzb/OS+I 6xu4DHBDk4jop4cQBUZiEoB1KU4/q2QcMmRpRcItohy31dBDfpBR3TB+GXh0+hHY3RZG EQfUT/LUU3LnpMjGBs5+G0bbiqX+p0wVckjNmIp0AHvgxVmP9YGtOEM4eWKxAr4YA1vH 2vtIEULesVTtr55hAxdqIExTXIi6GT7FXU60X6DntSOa3G0SeahgmKWD7pvQNTvHcZv2 AGxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=5EcaSelTELk66D9yc9EYTzF87nomzYvNvPRV8mwi9rc=; fh=J+tAcrUWMfKfAQtqVbrwcZxyy6a1S2hUqiWhIWyDv7Y=; b=aYDIEg//Uf2bDb2+1LX9wCK3fJU/JF9wUpi5YTgs6WN7V0Zj1V4809V7J6rbkrkgTz klKk2sJ8F0AF9dLYdl/dyXmoy3hIdsvdtWhJmOT2veJ3pF7AYAkXYfT7+hDmAKUQSpR1 s9b/YPQwZQuebc3CvEVOsdjrzlbKMbQWXmQBEWFkTNvIfufeItiTu17THGocGu7avkVD gu3HrJEqYYGLbrqTckYGQxFNy5El7ff0OpifRVk8IwjExTwAuznbLWc0KP087SyQ0Ecs sLXMz6z1QsdgCcWIR4wHtjZ6v4Fb/JPp65E0RQ20zfUjhoSHUQ+KRtPHW561BlNERb6t 5Gew== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=W7LN9a17; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ja19-20020a170907989300b0098638cd77b2si5718756ejc.199.2023.06.28.07.19.37; Wed, 28 Jun 2023 07:20:02 -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=@infradead.org header.s=casper.20170209 header.b=W7LN9a17; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231893AbjF1Nzi (ORCPT + 99 others); Wed, 28 Jun 2023 09:55:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50800 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232432AbjF1Nz0 (ORCPT ); Wed, 28 Jun 2023 09:55:26 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3C817269D; Wed, 28 Jun 2023 06:55:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=5EcaSelTELk66D9yc9EYTzF87nomzYvNvPRV8mwi9rc=; b=W7LN9a17V1DnA+F/c3rpfgeTL+ s9C6KEt2zXeQToktpw0ehyIxpP8abSG8JjAcd9hEC4JaLD6uOF28ErTho1dbkT4FRasYilW+/pm9O GaSsh2got/8M5YCpEVHSaY8H+lWAe3N63tWBp/2z5fY+mKdxDssIuFK9qmNpu5ecE8L8odGjryrT2 WFMy4Jdp3EFl1ebmWQlv+E01ibKRG2NMOpr2uJVr3ZFgoClliTEpNwjhVxW7ODFQiIbaDbxY22PqA J7KGeNLv4kkiMfDRCqctgMKvjGcSccUdAk74NE+Z8nefaHQ2rvGphUe/z+LAwqyo4NVN1faZP7an5 N4GwLRXQ==; Received: from j130084.upc-j.chello.nl ([24.132.130.84] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1qEVcz-003psp-FM; Wed, 28 Jun 2023 13:54:37 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 5214B30005E; Wed, 28 Jun 2023 15:54:36 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 316902424518F; Wed, 28 Jun 2023 15:54:36 +0200 (CEST) Date: Wed, 28 Jun 2023 15:54:36 +0200 From: Peter Zijlstra To: Kai Huang Cc: linux-kernel@vger.kernel.org, kvm@vger.kernel.org, linux-mm@kvack.org, x86@kernel.org, dave.hansen@intel.com, kirill.shutemov@linux.intel.com, tony.luck@intel.com, tglx@linutronix.de, bp@alien8.de, mingo@redhat.com, hpa@zytor.com, seanjc@google.com, pbonzini@redhat.com, david@redhat.com, dan.j.williams@intel.com, rafael.j.wysocki@intel.com, ashok.raj@intel.com, reinette.chatre@intel.com, len.brown@intel.com, ak@linux.intel.com, isaku.yamahata@intel.com, ying.huang@intel.com, chao.gao@intel.com, sathyanarayanan.kuppuswamy@linux.intel.com, nik.borisov@suse.com, bagasdotme@gmail.com, sagis@google.com, imammedo@redhat.com Subject: Re: [PATCH v12 05/22] x86/virt/tdx: Add SEAMCALL infrastructure Message-ID: <20230628135436.GC2439977@hirez.programming.kicks-ass.net> References: <20230628125813.GA2438817@hirez.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230628125813.GA2438817@hirez.programming.kicks-ass.net> X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED 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 Wed, Jun 28, 2023 at 02:58:13PM +0200, Peter Zijlstra wrote: > Can someone explain to me why __tdx_hypercall() is sane (per the above) > but then we grew __tdx_module_call() as an absolute abomination and are > apparently using that for seam too? That is, why do we have two different TDCALL wrappers? Makes no sense.