Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp7111380rwd; Tue, 6 Jun 2023 06:34:45 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4XLWhs3Kd2JSLP6vc1Nb6KiOdMu9UJ3jxnvavC7YAV45kXv/4jPDX0DWijpt08he6GfJE8 X-Received: by 2002:a17:902:d48e:b0:1b1:b253:5428 with SMTP id c14-20020a170902d48e00b001b1b2535428mr1010903plg.58.1686058485055; Tue, 06 Jun 2023 06:34:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686058485; cv=none; d=google.com; s=arc-20160816; b=B4yCMZHxmY5wlZv/gW/Zu1VzIVPahC1KHVBsJ/vAF74tnp+TCs2xs3g1LVjefcYzow 5ruPSRuPtYIoh2rLL/kRwPywnuPcv4KLjynFZvqqfDXva+MJeYvL4jXb6OFjvXZJDmF/ vsxZFepU6x+FN2PM1DE0r6J6TDfCBFuiK17+678IEnVlsd4j5P9rzR8LRjLvYfJDhSe+ umzTbM4r/5ARUH3stT3pZV1QMrwIptoRlDoGDil9sc4vN52vedsrZrklpPErhJdp1UCG 9N1Xu9oz9D+TY4zzPZdLXMyvmxZXTkFWmIBedGwA+Ls6+ztQ7A6CBlLP+Coxrg6CNf2h TwGQ== 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=J5Tt2HQyw7iraJSLZ38PzCTmA1/lQ2j9+YEo5vK8a10=; b=QtEzpUUZOPrI8/frtoJyspt5kHSOFfJWbACG04c8uSqp3DhrKaVt5WRKluk2rbAaCq tQ0DTOstf7paEgDv3qN5vnGnXXHnxlUeQnkX/TPH2qiRVqaQgzRcbfk8SUZqcow+49+T cosDd/aSh8RlS9xUIXjaapsHTVuW4BxSWDkQ1I0RyhLnsH/Baz6CyHcIw5XHbqPtvQSP exvpQlGNjD644Av6O760lP50dNMaB5awvdbVV3pQxn9cnHJgRWYg7/o4h3ba1D3Pq371 xrkXXZ5Jfv7KF5dB4BKAXuY/jPGp+9OqpWmITT66dc0Zef+o8BOGWWaKHKkRAiXsWKqZ I3sA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=YjqwvsNr; 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 q13-20020a17090311cd00b0019ca7d69673si7393709plh.196.2023.06.06.06.34.32; Tue, 06 Jun 2023 06:34:45 -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=YjqwvsNr; 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 S238108AbjFFNRy (ORCPT + 99 others); Tue, 6 Jun 2023 09:17:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45690 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233726AbjFFNRw (ORCPT ); Tue, 6 Jun 2023 09:17:52 -0400 Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D7E2B12F for ; Tue, 6 Jun 2023 06:17:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1686057472; x=1717593472; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=Y9U03UbFJmeGdJSyWHL3e77sZWmfNJFmQ9rWfILYRNw=; b=YjqwvsNrGI89JxhOt6MaAly2KH3ZsIcj9bK1i07QpwGhFR/cR+Iwj6SN LLIo6RhrKFKj4MVttFAJEP4qzfSyjEClN5ZZ6JC60oq9nsmdV7xG2fPTM KhxAKawrQKlnFSqYMC6EbavYVACU6VymCfXbe6vUUXsb1rJrn2274sEmZ LodezFZtepMukwpKJgaaaPMoKunDb6JuqBQYbVNZO10jGAdwFp4mgFR7s Wpt29cllWPc0PrG4tCwwg36Gr25GxZUAm9eksyuWANWH8B6kpWHZgOahF fV4J8JHwKC1AMIymWwbOjhL+hnmzatmRXNPcDheELnXUsGgV/9KqOhMpP Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10732"; a="359984921" X-IronPort-AV: E=Sophos;i="6.00,221,1681196400"; d="scan'208";a="359984921" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Jun 2023 06:10:24 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10732"; a="1039168823" X-IronPort-AV: E=Sophos;i="6.00,221,1681196400"; d="scan'208";a="1039168823" Received: from kumarr2-mobl1.amr.corp.intel.com (HELO [10.212.218.68]) ([10.212.218.68]) by fmsmga005-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Jun 2023 06:10:24 -0700 Message-ID: Date: Tue, 6 Jun 2023 06:10:23 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Firefox/102.0 Thunderbird/102.11.0 Subject: Re: [PATCH] x86/tdx: Explicitly include in Content-Language: en-US To: Kai Huang , linux-kernel@vger.kernel.org Cc: Dave Hansen , "Kirill A . Shutemov" , Isaku Yamahata References: <20230606034000.380270-1-kai.huang@intel.com> From: Sathyanarayanan Kuppuswamy In-Reply-To: <20230606034000.380270-1-kai.huang@intel.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,NICE_REPLY_A,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 6/5/23 8:40 PM, Kai Huang wrote: > Currently, in tdx_kvm_hypercall() simply returns -ENODEV > when TDX guest isn't enabled in the Kconfig w/o having Maybe you can explicitly say "CONFIG_INTEL_TDX_GUEST is not enabled" > header explicitly included. Although the current code doesn't have > build error, in general it is a good practice to explicitly include the > header to make sure any future patch which uses won't get > build error due to error code not being defined. Otherwise, it looks fine. Reviewed-by: Kuppuswamy Sathyanarayanan > > Fixes: cfb8ec7a31f2 ("x86/tdx: Wire up KVM hypercalls") > Suggested-by: Dave Hansen > Cc: Kuppuswamy Sathyanarayanan > Cc: Kirill A. Shutemov > Cc: Dave Hansen > Cc: Isaku Yamahata > Signed-off-by: Kai Huang > --- > arch/x86/include/asm/tdx.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/arch/x86/include/asm/tdx.h b/arch/x86/include/asm/tdx.h > index 28d889c9aa16..0f303c9abee8 100644 > --- a/arch/x86/include/asm/tdx.h > +++ b/arch/x86/include/asm/tdx.h > @@ -5,6 +5,7 @@ > > #include > #include > +#include > #include > #include > > > base-commit: 122333d6bd229af279cdb35d1b874b71b3b9ccfb -- Sathyanarayanan Kuppuswamy Linux Kernel Developer