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 6B801FF885A for ; Tue, 28 Apr 2026 04:51:29 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 1B46510E2C4; Tue, 28 Apr 2026 04:51:29 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="nCqC3OhZ"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.19]) by gabe.freedesktop.org (Postfix) with ESMTPS id AB79D10E29C for ; Tue, 28 Apr 2026 04:47:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1777351634; x=1808887634; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=Y0SY0Jv/iQ4hC+xtASPy/hv7QsHoACffrOheS7jJ3+E=; b=nCqC3OhZltGzvWBaeTV5yMW4cKOMrPo0YeGnuc4DmYS5BXfGYlk5s1TR 9tdxS7vR9NSgrgtrbULGmsee9l23r07dsZOnxHdbrByRvvsdiF3WwKIme JOOlrG+g+ybMsNQxKiCSsOdz7WwOqQLasJNUcg8EdKqCDIGOiIknmPTb8 skZUrRv4AVNwPUL5oQvHEUID5tdJqLwWKlweVId8fOp1FglZrWoeW0xmP Fmfolu5JVBmxK4exjjmOelEB9cV6wHWrc7YTTiwUPUw+T8cfns6U3RO14 wkEfnpU3tsmLRONjghRQOz69OwuRVrYC7kE6KFK8FJ34bMAJGzw3D3rbI Q==; X-CSE-ConnectionGUID: Pi/lfntjTsaFCkLcI1MTzA== X-CSE-MsgGUID: GWF8AGHASbWioyFImqPEhA== X-IronPort-AV: E=McAfee;i="6800,10657,11769"; a="78167805" X-IronPort-AV: E=Sophos;i="6.23,203,1770624000"; d="scan'208";a="78167805" Received: from orviesa008.jf.intel.com ([10.64.159.148]) by orvoesa111.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Apr 2026 21:47:14 -0700 X-CSE-ConnectionGUID: uXNtQjLASfOR1L/xxupMkg== X-CSE-MsgGUID: WLrwcrq/S3i0fvvxbA6Ggw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.23,203,1770624000"; d="scan'208";a="233706615" Received: from bilal-nuc7i7bnh.iind.intel.com ([10.190.239.45]) by orviesa008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Apr 2026 21:47:13 -0700 From: Mohammed Bilal To: igt-dev@lists.freedesktop.org Cc: kunal1.joshi@intel.com, Louis Chauvet , Luca Ceresoli , Kory Maincent Subject: [PATCH i-g-t v1 08/25] lib/monitor_edids: Add helper to print all available EDID names Date: Tue, 28 Apr 2026 10:16:17 +0530 Message-ID: <20260428044644.257001-9-mohammed.bilal@intel.com> X-Mailer: git-send-email 2.48.1 In-Reply-To: <20260428044644.257001-1-mohammed.bilal@intel.com> References: <20260428044644.257001-1-mohammed.bilal@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" From: Louis Chauvet During the unigraf configuration, it may be required to know the list of supported EDID names, so add an helper to print them. Reviewed-by: Luca Ceresoli Reviewed-by: Kory Maincent Signed-off-by: Louis Chauvet --- lib/monitor_edids/monitor_edids_helper.c | 17 +++++++++++++++++ lib/monitor_edids/monitor_edids_helper.h | 2 ++ 2 files changed, 19 insertions(+) diff --git a/lib/monitor_edids/monitor_edids_helper.c b/lib/monitor_edids/monitor_edids_helper.c index 01feb34a5..34ae6be9d 100644 --- a/lib/monitor_edids/monitor_edids_helper.c +++ b/lib/monitor_edids/monitor_edids_helper.c @@ -200,3 +200,20 @@ struct edid *get_edid_by_name(const char *name) return NULL; } + + +/* + * list_edid_names: + * @level: Log level to write the names on + * + * Print all the EDID available in igt. + */ +void list_edid_names(enum igt_log_level level) +{ + for (int i = 0; i < ARRAY_SIZE(ALL_EDIDS); i++) { + for (int j = 0; j < ALL_EDIDS[i].list_size; j++) { + igt_log(IGT_LOG_DOMAIN, level, " - \"%s\"\n", + ALL_EDIDS[i].edid_list[j].name); + } + } +} diff --git a/lib/monitor_edids/monitor_edids_helper.h b/lib/monitor_edids/monitor_edids_helper.h index 6d9e3fc89..7ae0fd40c 100644 --- a/lib/monitor_edids/monitor_edids_helper.h +++ b/lib/monitor_edids/monitor_edids_helper.h @@ -15,6 +15,7 @@ #include #include +#include "igt_core.h" #include "igt_chamelium.h" /* Max Length can be increased as needed, when new EDIDs are added. */ @@ -35,5 +36,6 @@ void free_chamelium_edid_from_monitor_edid(struct chamelium_edid *edid); struct edid *edid_from_monitor_edid(const monitor_edid *monitor_edid); struct monitor_edid *get_edids_for_connector_type(uint32_t type, size_t *count, bool four_k); struct edid *get_edid_by_name(const char *name); +void list_edid_names(enum igt_log_level level); #endif /* TESTS_CHAMELIUM_MONITOR_EDIDS_MONITOR_EDIDS_HELPER_H_ */ -- 2.48.1