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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (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 CEF99CD37BE for ; Mon, 11 May 2026 13:58:28 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 7E1C110E776; Mon, 11 May 2026 13:58:28 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="g6qUhORJ"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.13]) by gabe.freedesktop.org (Postfix) with ESMTPS id D866F10E782 for ; Mon, 11 May 2026 13:58:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1778507891; x=1810043891; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=aDWQncDRC7xcLfEeu+A5uVFmxui9IoNGq2eA7Dz6rBM=; b=g6qUhORJMDR8IbGFPXlagg1L+dfnBPXyi1XiEW69rW2Y6xWqKEcuht3l z+5UvfHHLPWjdXI9gMHC2NrkFF+sXT2AFSt/LBZxifj/8jVx2qm5qKPF7 pxb0QvWphshzWRf715Z7NED94QlJ7YJLx6LYtnyxVKHzQRLyprRgxE5eI nFyd9rw0kiwtuIQQI8ZVTc7TzlMnw+xyQwJSKJIuuxat79WBQSTFvJsPD /vKz7rn2YOAUQPOiFdqPyXDrzqXll5LYadUhzMsBFDbVjGdHU69/zhrcs TFPGyv0/VBA0unpL77yqULouSYXVi13rT5FvEQ0+5HUvB3q2sIwUWEoko A==; X-CSE-ConnectionGUID: BXU24x3yR/eWDBhXWMiuuQ== X-CSE-MsgGUID: EfIraGG2RgGbthA/s40/dQ== X-IronPort-AV: E=McAfee;i="6800,10657,11783"; a="81957738" X-IronPort-AV: E=Sophos;i="6.23,229,1770624000"; d="scan'208";a="81957738" Received: from orviesa004.jf.intel.com ([10.64.159.144]) by fmvoesa107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 May 2026 06:58:11 -0700 X-CSE-ConnectionGUID: 0C81nTtBSlCW83aX/gwljA== X-CSE-MsgGUID: IoVx8JP4TVKOdIaplRhWQg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.23,229,1770624000"; d="scan'208";a="241817542" Received: from varungup-desk.iind.intel.com ([10.190.238.71]) by orviesa004-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 May 2026 06:58:09 -0700 From: Varun Gupta To: igt-dev@lists.freedesktop.org Cc: arvind.yadav@intel.com, himal.prasad.ghimiray@intel.com, nishit.sharma@intel.com Subject: [PATCH i-g-t v3 1/4] tests/intel/xe_madvise: Generalize metadata and group purgeable subtests Date: Mon, 11 May 2026 19:27:34 +0530 Message-ID: <20260511135752.119868-2-varun.gupta@intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260511135752.119868-1-varun.gupta@intel.com> References: <20260511135752.119868-1-varun.gupta@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: igt-dev@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development mailing list for IGT GPU Tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" Generalize the test file description and functionality tags from purgeable-only to cover upcoming atomic madvise subtests. Wrap existing purgeable subtests in igt_subtest_group with a dedicated fixture so the purgeable capability check does not gate future non-purgeable subtests. Reviewed-by: Nishit Sharma Signed-off-by: Varun Gupta --- tests/intel/xe_madvise.c | 94 +++++++++++++++++++++------------------- 1 file changed, 49 insertions(+), 45 deletions(-) diff --git a/tests/intel/xe_madvise.c b/tests/intel/xe_madvise.c index e9bf55ff5..e79cafbff 100644 --- a/tests/intel/xe_madvise.c +++ b/tests/intel/xe_madvise.c @@ -4,11 +4,11 @@ */ /** - * TEST: Validate purgeable BO madvise functionality + * TEST: Validate madvise functionality * Category: Core * Mega feature: General Core features * Sub-category: Memory management tests - * Functionality: madvise, purgeable + * Functionality: madvise, purgeable, atomic */ #include "igt.h" @@ -776,51 +776,55 @@ int igt_main() igt_fixture() { fd = drm_open_driver(DRIVER_XE); xe_device_get(fd); - igt_require_f(xe_has_purgeable_support(fd), - "Kernel does not support purgeable buffer objects\n"); } - igt_subtest("dontneed-before-mmap") - xe_for_each_engine(fd, hwe) { - test_dontneed_before_mmap(fd); - break; - } - - igt_subtest("purged-mmap-blocked") - xe_for_each_engine(fd, hwe) { - test_purged_mmap_blocked(fd); - break; - } - - igt_subtest("dontneed-after-mmap") - xe_for_each_engine(fd, hwe) { - test_dontneed_after_mmap(fd); - break; - } - - igt_subtest("dontneed-before-exec") - xe_for_each_engine(fd, hwe) { - test_dontneed_before_exec(fd, hwe); - break; - } - - igt_subtest("dontneed-after-exec") - xe_for_each_engine(fd, hwe) { - test_dontneed_after_exec(fd, hwe); - break; - } - - igt_subtest("per-vma-tracking") - xe_for_each_engine(fd, hwe) { - test_per_vma_tracking(fd); - break; - } - - igt_subtest("per-vma-protection") - xe_for_each_engine(fd, hwe) { - test_per_vma_protection(fd, hwe); - break; - } + igt_subtest_group() { + igt_fixture() + igt_require_f(xe_has_purgeable_support(fd), + "Kernel does not support purgeable buffer objects\n"); + + igt_subtest("dontneed-before-mmap") + xe_for_each_engine(fd, hwe) { + test_dontneed_before_mmap(fd); + break; + } + + igt_subtest("purged-mmap-blocked") + xe_for_each_engine(fd, hwe) { + test_purged_mmap_blocked(fd); + break; + } + + igt_subtest("dontneed-after-mmap") + xe_for_each_engine(fd, hwe) { + test_dontneed_after_mmap(fd); + break; + } + + igt_subtest("dontneed-before-exec") + xe_for_each_engine(fd, hwe) { + test_dontneed_before_exec(fd, hwe); + break; + } + + igt_subtest("dontneed-after-exec") + xe_for_each_engine(fd, hwe) { + test_dontneed_after_exec(fd, hwe); + break; + } + + igt_subtest("per-vma-tracking") + xe_for_each_engine(fd, hwe) { + test_per_vma_tracking(fd); + break; + } + + igt_subtest("per-vma-protection") + xe_for_each_engine(fd, hwe) { + test_per_vma_protection(fd, hwe); + break; + } + } igt_fixture() { xe_device_put(fd); -- 2.43.0