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 C93FDC7EE24 for ; Tue, 6 Jun 2023 03:40:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233882AbjFFDk5 (ORCPT ); Mon, 5 Jun 2023 23:40:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46216 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233779AbjFFDkv (ORCPT ); Mon, 5 Jun 2023 23:40:51 -0400 Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 420631BF for ; Mon, 5 Jun 2023 20:40:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1686022843; x=1717558843; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=nFLHxFEm3u0GWuWSqbjdKs9lBf/QVQCUmYEP1/nyvz8=; b=RhZxegZjVvYuBejUROa+i0OlNqcGxd0XbFR0afRx6pKDpAbFPa7RQgkB WVhI6SjZqboOX6BgQHJQU9MrFdccNYF7TM42qhKzcYqwxYhtdi0wWUCuq F0cpDqBeJf5clGbBLxngePzWKhExdWDXKMtHmTwHpyaHnpr0pVeh+jgMQ S6px9niNCLjKJC5/pMjKrKyQDe2Zn1tHOueMP78hYTjEA7PzKCtCyKVh7 nF8iPBv8I23dN8hZ+fZuhrQgW9Z4I78wJj8TAo1qCMS2TFNdkHI3D9bGX f9MA9Hpyb//Ui1t8yjU5rGk8P9iiYba9kVupV8+e02cEWlFmcFOBJ+2gO w==; X-IronPort-AV: E=McAfee;i="6600,9927,10732"; a="341192090" X-IronPort-AV: E=Sophos;i="6.00,219,1681196400"; d="scan'208";a="341192090" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Jun 2023 20:40:25 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10732"; a="853237591" X-IronPort-AV: E=Sophos;i="6.00,219,1681196400"; d="scan'208";a="853237591" Received: from nataliai-mobl1.amr.corp.intel.com (HELO khuang2-desk.gar.corp.intel.com) ([10.209.159.2]) by fmsmga001-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Jun 2023 20:40:23 -0700 From: Kai Huang To: linux-kernel@vger.kernel.org Cc: Kai Huang , Dave Hansen , Kuppuswamy Sathyanarayanan , "Kirill A . Shutemov" , Isaku Yamahata Subject: [PATCH] x86/tdx: Explicitly include in Date: Tue, 6 Jun 2023 15:40:00 +1200 Message-Id: <20230606034000.380270-1-kai.huang@intel.com> X-Mailer: git-send-email 2.40.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Currently, in tdx_kvm_hypercall() simply returns -ENODEV when TDX guest isn't enabled in the Kconfig w/o having 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. 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 -- 2.40.1