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 lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 54522CA5FED for ; Fri, 9 Oct 2026 09:08:39 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xF6aE-0005O0-0H; Fri, 09 Oct 2026 05:08:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xF6a8-0005NH-3Q for qemu-devel@nongnu.org; Fri, 09 Oct 2026 05:08:00 -0400 Received: from mgamail.intel.com ([198.175.65.15]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xF6a6-0000h3-C2 for qemu-devel@nongnu.org; Fri, 09 Oct 2026 05:07:59 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1791536879; x=1823072879; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=f12rT1oVsQxui4wfBXUQ2DFK71TtMXEqUn4sY43FYLI=; b=XU/x0AHD1y+TN4DP9+wy7rEd45RartW2XKQVJ6CRSh9I+rkCOuOpf/dI LQOXlBwoEiNfMzR6ACHX+F4ly/4rw1RDl1ak/LiecfqxY9L20tHL/rQa+ yNyFfRGWtI/j3hk/lhNMLjPxN6winsIhbXzQBR0B4d9hc39LMf4nDouM1 VG1R5VnDMbNZbZAmnpqfGxm2PQ0vqyuIyhHp6/gcXow0agj8Fvf98aCqF T+BepYaSH/ZsGt10FnmirrT6Gxx6i3ngcocMYL+oJwUQRkH5MJLt3cS+K XHdOYiqWP19REAmAdj4Qb9eGJoohYQl9tMJzhWplhOICusaW7qvpg5CJN g==; X-CSE-ConnectionGUID: /A8CHGQjR6qjFsWsyhc3bw== X-CSE-MsgGUID: 9uqOSs45S8amwUHYWtmaAA== X-IronPort-AV: E=McAfee;i="6800,10657,11929"; a="328499" X-IronPort-AV: E=Sophos;i="6.27,148,1787036400"; d="scan'208";a="328499" Received: from fmviesa001.fm.intel.com ([10.60.135.141]) by orvoesa107.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Oct 2026 02:07:56 -0700 X-CSE-ConnectionGUID: zNAaui2rRoiO8B07FUosrw== X-CSE-MsgGUID: ZZGQUiE+SS6+90DbY77fjg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.27,148,1787036400"; d="scan'208";a="431376" Received: from unknown (HELO gnr-sp-2s-612.sh.intel.com) ([10.112.229.148]) by smtpauth.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Oct 2026 02:07:53 -0700 From: Zhenzhong Duan To: qemu-devel@nongnu.org Cc: alex@shazbot.org, clg@redhat.com, eric.auger@redhat.com, mst@redhat.com, jasowangio@gmail.com, jgg@nvidia.com, nicolinc@nvidia.com, skolothumtho@nvidia.com, joao.m.martins@oracle.com, clement.mathieu--drif@bull.com, kevin.tian@intel.com, yi.l.liu@intel.com, Zhenzhong Duan , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PATCH v8 1/6] intel_iommu_accel: Guard VTDAccelPASIDCacheEntry definition Date: Fri, 9 Oct 2026 17:07:31 +0800 Message-ID: <20261009090737.3930000-2-zhenzhong.duan@intel.com> X-Mailer: git-send-email 2.52.0 In-Reply-To: <20261009090737.3930000-1-zhenzhong.duan@intel.com> References: <20261009090737.3930000-1-zhenzhong.duan@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=198.175.65.15; envelope-from=zhenzhong.duan@intel.com; helo=mgamail.intel.com X-Spam_score_int: -45 X-Spam_score: -4.6 X-Spam_bar: ---- X-Spam_report: (-4.6 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.24, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Move the VTDAccelPASIDCacheEntry typedef structure inside the CONFIG_VTD_ACCEL ifdef block. When CONFIG_VTD_ACCEL is disabled, this structure is entirely unused throughout the code. Moving the layout under the existing preprocessor guard prevents exposing dead type definitions and ensures the header remains clean when building without VTD acceleration support. Suggested-by: Philippe Mathieu-Daudé Signed-off-by: Zhenzhong Duan Reviewed-by: Clement Mathieu--Drif Reviewed-by: Yi Liu --- hw/i386/intel_iommu_accel.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/i386/intel_iommu_accel.h b/hw/i386/intel_iommu_accel.h index 4a9003c92d..46c1a29409 100644 --- a/hw/i386/intel_iommu_accel.h +++ b/hw/i386/intel_iommu_accel.h @@ -12,6 +12,7 @@ #define HW_I386_INTEL_IOMMU_ACCEL_H #include CONFIG_DEVICES +#ifdef CONFIG_VTD_ACCEL typedef struct VTDAccelPASIDCacheEntry { VTDHostIOMMUDevice *vtd_hiod; VTDPASIDEntry pasid_entry; @@ -20,7 +21,6 @@ typedef struct VTDAccelPASIDCacheEntry { QLIST_ENTRY(VTDAccelPASIDCacheEntry) next; } VTDAccelPASIDCacheEntry; -#ifdef CONFIG_VTD_ACCEL bool vtd_check_hiod_accel(IntelIOMMUState *s, VTDHostIOMMUDevice *vtd_hiod, Error **errp); VTDHostIOMMUDevice *vtd_find_hiod_iommufd(VTDAddressSpace *as); -- 2.52.0