All of lore.kernel.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t v3 0/6] Add codename in device selection
@ 2022-07-14  4:17 Zbigniew Kempczyński
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 1/6] lib/igt_device_scan: Migrate pci assignment Zbigniew Kempczyński
                   ` (7 more replies)
  0 siblings, 8 replies; 12+ messages in thread
From: Zbigniew Kempczyński @ 2022-07-14  4:17 UTC (permalink / raw)
  To: igt-dev

Most important in this series is codename + discrete/integrated 
device selectors. Device simulation is far away from being perfect
and I won't insist for merging it - it was written to check some
artificial multi-gpu setups.

v2-v3: addressing review comments (Kamil)

Zbigniew Kempczyński (6):
  lib/igt_device_scan: Migrate pci assignment
  lib/igt_device_scan: Introduce codename for platform selection
  tools/lsgpu: Add codename switch (-c)
  lib/igt_device_scan: Align microseconds to six leading zeros
  lib/igt_device_scan: Add discrete/integrated pseudo-codenames
  lib/igt_device_scan: Simulate udev drm and pci device events

 lib/igt_device_scan.c          | 181 +++++++++++--
 lib/igt_device_scan.h          |   1 +
 lib/igt_device_scan_simulate.c | 450 +++++++++++++++++++++++++++++++++
 tools/lsgpu.c                  |   8 +-
 4 files changed, 623 insertions(+), 17 deletions(-)
 create mode 100644 lib/igt_device_scan_simulate.c

-- 
2.34.1

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [igt-dev] [PATCH i-g-t v3 1/6] lib/igt_device_scan: Migrate pci assignment
  2022-07-14  4:17 [igt-dev] [PATCH i-g-t v3 0/6] Add codename in device selection Zbigniew Kempczyński
@ 2022-07-14  4:17 ` Zbigniew Kempczyński
  2022-07-15 16:54   ` Kamil Konieczny
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 2/6] lib/igt_device_scan: Introduce codename for platform selection Zbigniew Kempczyński
                   ` (6 subsequent siblings)
  7 siblings, 1 reply; 12+ messages in thread
From: Zbigniew Kempczyński @ 2022-07-14  4:17 UTC (permalink / raw)
  To: igt-dev

Core function of scanning drm devices is scan_drm_devices(). It goes
over all drm subsystem devices acquiring pci (parent) device from udev
during dedicated call for drm device.

Extending device selection to multi-gpu setup requires access to such
machine or simulate udev calls (really replace current udev calls to
say linker to use static versions of overridden udev functions).

Change migrates some core pci assignment to place where new igt_device is
registered. It doesn't change code logic, only place where initialization
is done making my simulation code happy.

Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
---
 lib/igt_device_scan.c | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/lib/igt_device_scan.c b/lib/igt_device_scan.c
index 5d98381f06..83a488aa7c 100644
--- a/lib/igt_device_scan.c
+++ b/lib/igt_device_scan.c
@@ -513,6 +513,11 @@ static struct igt_device *igt_device_new_from_udev(struct udev_device *dev)
 	get_props(dev, idev);
 	get_attrs(dev, idev);
 
+	if (is_pci_subsystem(idev)) {
+		set_vendor_device(idev);
+		set_pci_slot_name(idev);
+	}
+
 	return idev;
 }
 
@@ -671,10 +676,6 @@ static void update_or_add_parent(struct udev_device *dev,
 	parent_idev = igt_device_find(subsystem, syspath);
 	if (!parent_idev) {
 		parent_idev = igt_device_new_from_udev(parent_dev);
-		if (is_pci_subsystem(parent_idev)) {
-			set_vendor_device(parent_idev);
-			set_pci_slot_name(parent_idev);
-		}
 		igt_list_add_tail(&parent_idev->link, &igt_devs.all);
 	}
 	devname = udev_device_get_devnode(dev);
@@ -804,8 +805,8 @@ static void scan_drm_devices(void)
 		path = udev_list_entry_get_name(dev_list_entry);
 		udev_dev = udev_device_new_from_syspath(udev, path);
 		idev = igt_device_new_from_udev(udev_dev);
-		update_or_add_parent(udev_dev, idev);
 		igt_list_add_tail(&idev->link, &igt_devs.all);
+		update_or_add_parent(udev_dev, idev);
 
 		udev_device_unref(udev_dev);
 	}
-- 
2.34.1

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [igt-dev] [PATCH i-g-t v3 2/6] lib/igt_device_scan: Introduce codename for platform selection
  2022-07-14  4:17 [igt-dev] [PATCH i-g-t v3 0/6] Add codename in device selection Zbigniew Kempczyński
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 1/6] lib/igt_device_scan: Migrate pci assignment Zbigniew Kempczyński
@ 2022-07-14  4:17 ` Zbigniew Kempczyński
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 3/6] tools/lsgpu: Add codename switch (-c) Zbigniew Kempczyński
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Zbigniew Kempczyński @ 2022-07-14  4:17 UTC (permalink / raw)
  To: igt-dev

Platform rare is defined by single pci device id. Adding platform group
selection will make device selection more convenient. Now instead using

pci:vendor=8086,device=0x1927
pci:vendor=intel,device=0x1927

we may pass:

pci:vendor=8086,device=skylake
pci:vendor=intel,device=skylake

Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Reviewed-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>
---
 lib/igt_device_scan.c | 91 ++++++++++++++++++++++++++++++++++++++-----
 lib/igt_device_scan.h |  1 +
 2 files changed, 82 insertions(+), 10 deletions(-)

diff --git a/lib/igt_device_scan.c b/lib/igt_device_scan.c
index 83a488aa7c..0ff49f96b7 100644
--- a/lib/igt_device_scan.c
+++ b/lib/igt_device_scan.c
@@ -85,13 +85,13 @@
  *
  * - pci: select device using PCI slot or vendor and device properties
  *   |[<!-- language="plain" -->
- *   pci:[vendor=%04x/name][,device=%04x][,card=%d] | [slot=%04x:%02x:%02x.%x]
+ *   pci:[vendor=%04x/name][,device=%04x/codename][,card=%d] | [slot=%04x:%02x:%02x.%x]
  *   ]|
  *
  *   Filter allows device selection using vendor (hex or name), device id
- *   (hex) and nth-card from all matches. For example if there are 4 PCI cards
- *   installed (let two cards have 1234 and other two 1235 device id, all of
- *   them of vendor Intel) you can select one using:
+ *   (hex or codename) and nth-card from all matches. For example if there
+ *   are 4 PCI cards installed (let two cards have 1234 and other two 1235
+ *   device id, all of them of vendor Intel) you can select one using:
  *
  *   |[<!-- language="plain" -->
  *   pci:vendor=Intel,device=1234,card=0
@@ -117,6 +117,12 @@
  *
  *   It selects the second one.
  *
+ *   We may use device codename instead of pci device id:
+ *
+ *   |[<!-- language="plain" -->
+ *   pci:vendor=8086,device=skylake
+ *   ]|
+ *
  *   Another possibility is to select device using a PCI slot:
  *
  *   |[<!-- language="plain" -->
@@ -131,7 +137,7 @@
  *
  * - sriov: select pf or vf
  *   |[<!-- language="plain" -->
- *   sriov:[vendor=%04x/name][,device=%04x][,card=%d][,pf=%d][,vf=%d]
+ *   sriov:[vendor=%04x/name][,device=%04x/codename][,card=%d][,pf=%d][,vf=%d]
  *   ]|
  *
  *   Filter extends pci selector to allow pf/vf selection:
@@ -205,6 +211,8 @@ struct igt_device {
 	char *pci_slot_name;
 	int gpu_index; /* For more than one GPU with same vendor and device. */
 
+	char *codename; /* For grouping by codename */
+
 	struct igt_list_head link;
 };
 
@@ -248,13 +256,30 @@ static char *devname_intel(uint16_t vendor, uint16_t device)
 	return s;
 }
 
+static char *codename_intel(uint16_t vendor, uint16_t device)
+{
+	const struct intel_device_info *info = intel_get_device_info(device);
+	char *codename = NULL;
+
+	if (info->codename) {
+		codename = strdup(info->codename);
+		igt_assert(codename);
+	}
+
+	if (!codename)
+		codename = devname_hex(vendor, device);
+
+	return codename;
+}
+
 static struct {
 	const char *name;
 	const char *vendor_id;
 	devname_fn devname;
+	devname_fn codename;
 } pci_vendor_mapping[] = {
-	{ "intel", "8086", devname_intel },
-	{ "amd", "1002", devname_hex },
+	{ "intel", "8086", devname_intel, codename_intel },
+	{ "amd", "1002", devname_hex, devname_hex },
 	{ NULL, },
 };
 
@@ -283,6 +308,20 @@ static devname_fn get_pci_vendor_device_fn(uint16_t vendor)
 	return devname_hex;
 }
 
+static devname_fn get_pci_vendor_device_codename_fn(uint16_t vendor)
+{
+	char vendorstr[5];
+
+	snprintf(vendorstr, sizeof(vendorstr), "%04x", vendor);
+
+	for (typeof(*pci_vendor_mapping) *vm = pci_vendor_mapping; vm->name; vm++) {
+		if (!strcasecmp(vendorstr, vm->vendor_id))
+			return vm->codename;
+	}
+
+	return devname_hex;
+}
+
 static void get_pci_vendor_device(const struct igt_device *dev,
 				  uint16_t *vendorp, uint16_t *devicep)
 {
@@ -305,6 +344,15 @@ static char *__pci_pretty_name(uint16_t vendor, uint16_t device, bool numeric)
 	return fn(vendor, device);
 }
 
+static char *__pci_codename(uint16_t vendor, uint16_t device)
+{
+	devname_fn fn;
+
+	fn = get_pci_vendor_device_codename_fn(vendor);
+
+	return fn(vendor, device);
+}
+
 /* Reading sysattr values can take time (even seconds),
  * we want to avoid reading such keys.
  */
@@ -514,8 +562,12 @@ static struct igt_device *igt_device_new_from_udev(struct udev_device *dev)
 	get_attrs(dev, idev);
 
 	if (is_pci_subsystem(idev)) {
+		uint16_t vendor, device;
+
 		set_vendor_device(idev);
 		set_pci_slot_name(idev);
+		get_pci_vendor_device(idev, &vendor, &device);
+		idev->codename = __pci_codename(vendor, device);
 	}
 
 	return idev;
@@ -558,6 +610,19 @@ static bool is_vendor_matched(struct igt_device *dev, const char *vendor)
 	return !strcasecmp(dev->vendor, vendor_id);
 }
 
+static bool is_device_matched(struct igt_device *dev, const char *device)
+{
+	if (!dev->device || !device)
+		return false;
+
+	/* First we compare device id, like 1926 */
+	if (!strcasecmp(dev->device, device))
+		return true;
+
+	/* Try codename */
+	return !strcasecmp(dev->codename, device);
+}
+
 static char *safe_strncpy(char *dst, const char *src, int n)
 {
 	char *s;
@@ -824,6 +889,7 @@ static void scan_drm_devices(void)
 
 static void igt_device_free(struct igt_device *dev)
 {
+	free(dev->codename);
 	free(dev->devnode);
 	free(dev->subsystem);
 	free(dev->syspath);
@@ -935,6 +1001,7 @@ igt_devs_print_simple(struct igt_list_head *view,
 			if (is_pci_subsystem(dev)) {
 				_pr_simple("vendor", dev->vendor);
 				_pr_simple("device", dev->device);
+				_pr_simple("codename", dev->codename);
 			}
 		}
 		printf("\n");
@@ -1022,7 +1089,10 @@ igt_devs_print_user(struct igt_list_head *view,
 			char *devname;
 
 			get_pci_vendor_device(pci_dev, &vendor, &device);
-			devname = __pci_pretty_name(vendor, device, fmt->numeric);
+			if (fmt->codename)
+				devname = __pci_codename(vendor, device);
+			else
+				devname = __pci_pretty_name(vendor, device, fmt->numeric);
 
 			__print_filter(filter, sizeof(filter), fmt, pci_dev,
 				       false);
@@ -1106,6 +1176,7 @@ igt_devs_print_detail(struct igt_list_head *view,
 		if (!is_drm_subsystem(dev)) {
 			_print_key_value("card device", dev->drm_card);
 			_print_key_value("render device", dev->drm_render);
+			_print_key_value("codename", dev->codename);
 		}
 
 		printf("\n[properties]\n");
@@ -1332,7 +1403,7 @@ static struct igt_list_head *filter_pci(const struct filter_class *fcls,
 			continue;
 
 		/* Skip if 'device' doesn't match */
-		if (filter->data.device && strcasecmp(filter->data.device, dev->device))
+		if (filter->data.device && !is_device_matched(dev, filter->data.device))
 			continue;
 
 		/* We get n-th card */
@@ -1412,7 +1483,7 @@ static struct igt_list_head *filter_sriov(const struct filter_class *fcls,
 			continue;
 
 		/* Skip if 'device' doesn't match */
-		if (filter->data.device && strcasecmp(filter->data.device, dev->device))
+		if (filter->data.device && !is_device_matched(dev, filter->data.device))
 			continue;
 
 		/* We get n-th card */
diff --git a/lib/igt_device_scan.h b/lib/igt_device_scan.h
index 5f583a0666..e6b0f1b90a 100644
--- a/lib/igt_device_scan.h
+++ b/lib/igt_device_scan.h
@@ -50,6 +50,7 @@ struct igt_devices_print_format {
 	enum igt_devices_print_type   type;
 	enum igt_devices_print_option option;
 	bool numeric;
+	bool codename;
 };
 
 #define INTEGRATED_I915_GPU_PCI_ID "0000:00:02.0"
-- 
2.34.1

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [igt-dev] [PATCH i-g-t v3 3/6] tools/lsgpu: Add codename switch (-c)
  2022-07-14  4:17 [igt-dev] [PATCH i-g-t v3 0/6] Add codename in device selection Zbigniew Kempczyński
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 1/6] lib/igt_device_scan: Migrate pci assignment Zbigniew Kempczyński
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 2/6] lib/igt_device_scan: Introduce codename for platform selection Zbigniew Kempczyński
@ 2022-07-14  4:17 ` Zbigniew Kempczyński
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 4/6] lib/igt_device_scan: Align microseconds to six leading zeros Zbigniew Kempczyński
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Zbigniew Kempczyński @ 2022-07-14  4:17 UTC (permalink / raw)
  To: igt-dev

Add -c switch which will change default (pretty) platform name to
codename only. It may be useful for writing device selection filter.

Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Reviewed-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>
---
 tools/lsgpu.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/tools/lsgpu.c b/tools/lsgpu.c
index 27e76f2616..da84e20505 100644
--- a/tools/lsgpu.c
+++ b/tools/lsgpu.c
@@ -73,6 +73,7 @@ enum {
 	OPT_PRINT_SIMPLE   = 's',
 	OPT_PRINT_DETAIL   = 'p',
 	OPT_NUMERIC        = 'n',
+	OPT_CODENAME       = 'c',
 	OPT_LIST_VENDORS   = 'v',
 	OPT_LIST_FILTERS   = 'l',
 	OPT_DEVICE         = 'd',
@@ -88,6 +89,7 @@ static const char *usage_str =
 	"usage: lsgpu [options]\n\n"
 	"Options:\n"
 	"  -n, --numeric               Print vendor/device as hex\n"
+	"  -c, --codename              Print codename instead pretty device name\n"
 	"  -s, --print-simple          Print simple (legacy) device details\n"
 	"  -p, --print-details         Print devices with details\n"
 	"  -v, --list-vendors          List recognized vendors\n"
@@ -163,6 +165,7 @@ int main(int argc, char *argv[])
 		{"sysfs",             no_argument,       NULL, 1},
 		{"pci",               no_argument,       NULL, 2},
 		{"numeric",           no_argument,       NULL, OPT_NUMERIC},
+		{"codename",          no_argument,       NULL, OPT_CODENAME},
 		{"print-simple",      no_argument,       NULL, OPT_PRINT_SIMPLE},
 		{"print-detail",      no_argument,       NULL, OPT_PRINT_DETAIL},
 		{"list-vendors",      no_argument,       NULL, OPT_LIST_VENDORS},
@@ -177,13 +180,16 @@ int main(int argc, char *argv[])
 			.type = IGT_PRINT_USER,
 	};
 
-	while ((c = getopt_long(argc, argv, "nspvld:h",
+	while ((c = getopt_long(argc, argv, "ncspvld:h",
 				long_options, &index)) != -1) {
 		switch(c) {
 
 		case OPT_NUMERIC:
 			fmt.numeric = true;
 			break;
+		case OPT_CODENAME:
+			fmt.codename = true;
+			break;
 		case OPT_PRINT_SIMPLE:
 			fmt.type = IGT_PRINT_SIMPLE;
 			break;
-- 
2.34.1

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [igt-dev] [PATCH i-g-t v3 4/6] lib/igt_device_scan: Align microseconds to six leading zeros
  2022-07-14  4:17 [igt-dev] [PATCH i-g-t v3 0/6] Add codename in device selection Zbigniew Kempczyński
                   ` (2 preceding siblings ...)
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 3/6] tools/lsgpu: Add codename switch (-c) Zbigniew Kempczyński
@ 2022-07-14  4:17 ` Zbigniew Kempczyński
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 5/6] lib/igt_device_scan: Add discrete/integrated pseudo-codenames Zbigniew Kempczyński
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Zbigniew Kempczyński @ 2022-07-14  4:17 UTC (permalink / raw)
  To: igt-dev

Previous format was not correct when DBG() was in use leading to
not properly aligned output.

Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Reviewed-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>
---
 lib/igt_device_scan.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/igt_device_scan.c b/lib/igt_device_scan.c
index 0ff49f96b7..23056894f1 100644
--- a/lib/igt_device_scan.c
+++ b/lib/igt_device_scan.c
@@ -34,6 +34,7 @@
 #include <libudev.h>
 #include <linux/limits.h>
 #include <sys/stat.h>
+#include <sys/time.h>
 #include <sys/types.h>
 
 /**
@@ -170,7 +171,7 @@
 { \
 	struct timeval tm; \
 	gettimeofday(&tm, NULL); \
-	printf("%10ld.%03ld: ", tm.tv_sec, tm.tv_usec); \
+	printf("%10ld.%06ld: ", tm.tv_sec, tm.tv_usec); \
 	printf(__VA_ARGS__); \
 }
 
-- 
2.34.1

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [igt-dev] [PATCH i-g-t v3 5/6] lib/igt_device_scan: Add discrete/integrated pseudo-codenames
  2022-07-14  4:17 [igt-dev] [PATCH i-g-t v3 0/6] Add codename in device selection Zbigniew Kempczyński
                   ` (3 preceding siblings ...)
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 4/6] lib/igt_device_scan: Align microseconds to six leading zeros Zbigniew Kempczyński
@ 2022-07-14  4:17 ` Zbigniew Kempczyński
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 6/6] lib/igt_device_scan: Simulate udev drm and pci device events Zbigniew Kempczyński
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Zbigniew Kempczyński @ 2022-07-14  4:17 UTC (permalink / raw)
  To: igt-dev

For simply selection where test should just run on dedicated card type
pci + sriov selectors can now use:

pci:vendor=8086,device=integrated
pci:vendor=intel,device=integrated

or

pci:vendor=8086,device=discrete
pci:vendor=intel,device=discrete

or (when there're more discrete cards)

pci:vendor=8086,device=discrete,card=n
pci:vendor=intel,device=discrete,card=n

Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Reviewed-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>
---
 lib/igt_device_scan.c | 75 +++++++++++++++++++++++++++++++++++++++++--
 1 file changed, 72 insertions(+), 3 deletions(-)

diff --git a/lib/igt_device_scan.c b/lib/igt_device_scan.c
index 23056894f1..aad7966764 100644
--- a/lib/igt_device_scan.c
+++ b/lib/igt_device_scan.c
@@ -118,12 +118,19 @@
  *
  *   It selects the second one.
  *
- *   We may use device codename instead of pci device id:
+ *   We may use device codename or pseudo-codename (integrated/discrete)
+ *   instead of pci device id:
  *
  *   |[<!-- language="plain" -->
  *   pci:vendor=8086,device=skylake
  *   ]|
  *
+ *   or
+ *
+ *   |[<!-- language="plain" -->
+ *   pci:vendor=8086,device=integrated
+ *   ]|
+ *
  *   Another possibility is to select device using a PCI slot:
  *
  *   |[<!-- language="plain" -->
@@ -179,6 +186,15 @@
 #define DBG(...) {}
 #endif
 
+enum dev_type {
+	DEVTYPE_ALL,
+	DEVTYPE_INTEGRATED,
+	DEVTYPE_DISCRETE,
+};
+
+#define STR_INTEGRATED "integrated"
+#define STR_DISCRETE "discrete"
+
 static inline bool strequal(const char *a, const char *b)
 {
 	if (a == NULL || b == NULL)
@@ -213,6 +229,7 @@ struct igt_device {
 	int gpu_index; /* For more than one GPU with same vendor and device. */
 
 	char *codename; /* For grouping by codename */
+	enum dev_type dev_type; /* For grouping by integrated/discrete */
 
 	struct igt_list_head link;
 };
@@ -225,6 +242,7 @@ static struct {
 } igt_devs;
 
 typedef char *(*devname_fn)(uint16_t, uint16_t);
+typedef enum dev_type (*devtype_fn)(uint16_t, uint16_t, const char *);
 
 static char *devname_hex(uint16_t vendor, uint16_t device)
 {
@@ -273,14 +291,35 @@ static char *codename_intel(uint16_t vendor, uint16_t device)
 	return codename;
 }
 
+static enum dev_type devtype_intel(uint16_t vendor, uint16_t device, const char *pci_slot)
+{
+	(void) vendor;
+	(void) device;
+
+	if (!strncmp(pci_slot, INTEGRATED_I915_GPU_PCI_ID, PCI_SLOT_NAME_SIZE))
+		return DEVTYPE_INTEGRATED;
+
+	return DEVTYPE_DISCRETE;
+}
+
+static enum dev_type devtype_all(uint16_t vendor, uint16_t device, const char *pci_slot)
+{
+	(void) vendor;
+	(void) device;
+	(void) pci_slot;
+
+	return DEVTYPE_ALL;
+}
+
 static struct {
 	const char *name;
 	const char *vendor_id;
 	devname_fn devname;
 	devname_fn codename;
+	devtype_fn devtype;
 } pci_vendor_mapping[] = {
-	{ "intel", "8086", devname_intel, codename_intel },
-	{ "amd", "1002", devname_hex, devname_hex },
+	{ "intel", "8086", devname_intel, codename_intel, devtype_intel },
+	{ "amd", "1002", devname_hex, devname_hex, devtype_all },
 	{ NULL, },
 };
 
@@ -323,6 +362,20 @@ static devname_fn get_pci_vendor_device_codename_fn(uint16_t vendor)
 	return devname_hex;
 }
 
+static devtype_fn get_pci_vendor_device_devtype_fn(uint16_t vendor)
+{
+	char vendorstr[5];
+
+	snprintf(vendorstr, sizeof(vendorstr), "%04x", vendor);
+
+	for (typeof(*pci_vendor_mapping) *vm = pci_vendor_mapping; vm->name; vm++) {
+		if (!strcasecmp(vendorstr, vm->vendor_id))
+			return vm->devtype;
+	}
+
+	return devtype_all;
+}
+
 static void get_pci_vendor_device(const struct igt_device *dev,
 				  uint16_t *vendorp, uint16_t *devicep)
 {
@@ -354,6 +407,15 @@ static char *__pci_codename(uint16_t vendor, uint16_t device)
 	return fn(vendor, device);
 }
 
+static enum dev_type __pci_devtype(uint16_t vendor, uint16_t device, const char *pci_slot)
+{
+	devtype_fn fn;
+
+	fn = get_pci_vendor_device_devtype_fn(vendor);
+
+	return fn(vendor, device, pci_slot);
+}
+
 /* Reading sysattr values can take time (even seconds),
  * we want to avoid reading such keys.
  */
@@ -569,6 +631,7 @@ static struct igt_device *igt_device_new_from_udev(struct udev_device *dev)
 		set_pci_slot_name(idev);
 		get_pci_vendor_device(idev, &vendor, &device);
 		idev->codename = __pci_codename(vendor, device);
+		idev->dev_type = __pci_devtype(vendor, device, idev->pci_slot_name);
 	}
 
 	return idev;
@@ -620,6 +683,12 @@ static bool is_device_matched(struct igt_device *dev, const char *device)
 	if (!strcasecmp(dev->device, device))
 		return true;
 
+	/* Try "integrated" and "discrete" */
+	if (dev->dev_type == DEVTYPE_INTEGRATED && !strcasecmp(device, STR_INTEGRATED))
+		return true;
+	else if (dev->dev_type == DEVTYPE_DISCRETE && !strcasecmp(device, STR_DISCRETE))
+		return true;
+
 	/* Try codename */
 	return !strcasecmp(dev->codename, device);
 }
-- 
2.34.1

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [igt-dev] [PATCH i-g-t v3 6/6] lib/igt_device_scan: Simulate udev drm and pci device events
  2022-07-14  4:17 [igt-dev] [PATCH i-g-t v3 0/6] Add codename in device selection Zbigniew Kempczyński
                   ` (4 preceding siblings ...)
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 5/6] lib/igt_device_scan: Add discrete/integrated pseudo-codenames Zbigniew Kempczyński
@ 2022-07-14  4:17 ` Zbigniew Kempczyński
  2022-07-15 16:52   ` Kamil Konieczny
  2022-07-14  4:55 ` [igt-dev] ✓ Fi.CI.BAT: success for Add codename in device selection (rev3) Patchwork
  2022-07-14  7:39 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
  7 siblings, 1 reply; 12+ messages in thread
From: Zbigniew Kempczyński @ 2022-07-14  4:17 UTC (permalink / raw)
  To: igt-dev

For all udev_*() calls used in device scan add its static counterparts.
Instead of transplanting real udev data structures (private ones) some
primitive replacement were added. Devices are added directly from code
- such implementation was a little bit faster than parsing some config
files (especially pci slot manipulation to provide some properties which
slightly differs).

Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
---
 lib/igt_device_scan.c          |   7 +
 lib/igt_device_scan_simulate.c | 450 +++++++++++++++++++++++++++++++++
 2 files changed, 457 insertions(+)
 create mode 100644 lib/igt_device_scan_simulate.c

diff --git a/lib/igt_device_scan.c b/lib/igt_device_scan.c
index aad7966764..f4e7659e42 100644
--- a/lib/igt_device_scan.c
+++ b/lib/igt_device_scan.c
@@ -904,6 +904,13 @@ static void index_pci_devices(void)
  * Function sorts all found devices to keep same order of bus devices
  * for providing predictable search.
  */
+
+#ifdef SIMULATE_UDEV_DEVICES
+
+#include "igt_device_scan_simulate.c"
+
+#endif
+
 static void scan_drm_devices(void)
 {
 	struct udev *udev;
diff --git a/lib/igt_device_scan_simulate.c b/lib/igt_device_scan_simulate.c
new file mode 100644
index 0000000000..5108f55924
--- /dev/null
+++ b/lib/igt_device_scan_simulate.c
@@ -0,0 +1,450 @@
+/*
+ * Example: Skylake
+1656514333.437262: --------------------
+1656514333.437263: SYSPATH: /sys/devices/pci0000:00/0000:00:02.0/drm/card0
+1656514333.437294: SUBSYSTEM: drm
+1656514333.437377: prop: CURRENT_TAGS, val: :seat:mutter-device-disable-kms-modifiers:master-of-seat:uaccess:
+1656514333.437378: prop: DEVLINKS, val: /dev/dri/by-path/pci-0000:00:02.0-card
+1656514333.437378: prop: DEVNAME, val: /dev/dri/card0
+1656514333.437379: prop: DEVPATH, val: /devices/pci0000:00/0000:00:02.0/drm/card0
+1656514333.437379: prop: DEVTYPE, val: drm_minor
+1656514333.437380: prop: ID_FOR_SEAT, val: drm-pci-0000_00_02_0
+1656514333.437380: prop: ID_PATH, val: pci-0000:00:02.0
+1656514333.437382: prop: ID_PATH_TAG, val: pci-0000_00_02_0
+1656514333.437383: prop: MAJOR, val: 226
+1656514333.437383: prop: MINOR, val: 0
+1656514333.437383: prop: SUBSYSTEM, val: drm
+1656514333.437384: prop: TAGS, val: :seat:mutter-device-disable-kms-modifiers:master-of-seat:uaccess:
+1656514333.437384: prop: USEC_INITIALIZED, val: 31377470
+1656514333.438273: attr: dev, val: 226:0
+1656406120.387751: attr: subsystem, val: drm
+
+1656514333.440217: --------------------
+1656514333.440217: parent: 0000:00:02.0
+1656514333.440223: subsystem: pci
+1656514333.440224: syspath: /sys/devices/pci0000:00/0000:00:02.0
+1656514333.440297: prop: DEVPATH, val: /devices/pci0000:00/0000:00:02.0
+1656514333.440298: prop: DRIVER, val: i915
+1656514333.440298: prop: ID_MODEL_FROM_DATABASE, val: Iris Graphics 540
+1656514333.440299: prop: ID_PCI_CLASS_FROM_DATABASE, val: Display controller
+1656514333.440299: prop: ID_PCI_INTERFACE_FROM_DATABASE, val: VGA controller
+1656514333.440300: prop: ID_PCI_SUBCLASS_FROM_DATABASE, val: VGA compatible controller
+1656514333.440300: prop: ID_VENDOR_FROM_DATABASE, val: Intel Corporation
+1656514333.440301: prop: MODALIAS, val: pci:v00008086d00001926sv00008086sd00002063bc03sc00i00
+1656514333.440302: prop: PCI_CLASS, val: 30000
+1656514333.440302: prop: PCI_ID, val: 8086:1926
+1656514333.440303: prop: PCI_SLOT_NAME, val: 0000:00:02.0
+1656514333.440303: prop: PCI_SUBSYS_ID, val: 8086:2063
+1656514333.440304: prop: SUBSYSTEM, val: pci
+1656514333.440304: prop: SWITCHEROO_CONTROL_PRODUCT_NAME, val: Iris(R) Graphics 540
+1656514333.440305: prop: SWITCHEROO_CONTROL_VENDOR_NAME, val: Intel(R)
+1656514333.440306: prop: USEC_INITIALIZED, val: 6111540
+1656514333.440692: attr: class, val: 0x030000
+1656514333.440750: attr: device, val: 0x1926
+1656514333.441116: attr: subsystem, val: pci
+1656514333.441130: attr: subsystem_device, val: 0x2063
+1656514333.441141: attr: subsystem_vendor, val: 0x8086
+1656514333.441162: attr: vendor, val: 0x8086
+
+1656514333.441271: --------------------
+1656514333.441272: SYSPATH: /sys/devices/pci0000:00/0000:00:02.0/drm/renderD128
+1656514333.441305: SUBSYSTEM: drm
+1656514333.441390: prop: CURRENT_TAGS, val: :seat:mutter-device-disable-kms-modifiers:uaccess:
+1656514333.441391: prop: DEVLINKS, val: /dev/dri/by-path/pci-0000:00:02.0-render
+1656514333.441391: prop: DEVNAME, val: /dev/dri/renderD128
+1656514333.441392: prop: DEVPATH, val: /devices/pci0000:00/0000:00:02.0/drm/renderD128
+1656514333.441392: prop: DEVTYPE, val: drm_minor
+1656514333.441393: prop: ID_FOR_SEAT, val: drm-pci-0000_00_02_0
+1656514333.441393: prop: ID_PATH, val: pci-0000:00:02.0
+1656514333.441395: prop: ID_PATH_TAG, val: pci-0000_00_02_0
+1656514333.441395: prop: MAJOR, val: 226
+1656514333.441396: prop: MINOR, val: 128
+1656514333.441396: prop: SUBSYSTEM, val: drm
+1656514333.441396: prop: TAGS, val: :seat:mutter-device-disable-kms-modifiers:uaccess:
+1656514333.441397: prop: USEC_INITIALIZED, val: 31377515
+1656514333.441525: attr: dev, val: 226:128
+1656514333.441657: attr: subsystem, val: drm
+*/
+
+enum entry_type {
+	TYPE_DEVICE,
+	TYPE_PROP,
+	TYPE_ATTR,
+};
+
+struct udev_list_entry {
+	enum entry_type entry_type;
+	int curr;
+} _entry_dev, _entry_prop, _entry_attr;
+
+struct keyval {
+	char key[NAME_MAX];
+	char val[NAME_MAX];
+};
+
+#define MAXDEVS 16
+#define MAXPROPS 16
+#define MAXATTRS 8
+struct udev_device {
+	struct udev_device *parent;
+	char syspath[NAME_MAX];
+	char devnode[NAME_MAX];
+	char subsystem[8];
+	struct keyval prop[MAXPROPS];
+	struct udev_list_entry *prop_head;
+	struct keyval attr[MAXATTRS];
+	struct udev_list_entry *attr_head;
+	int props;
+	int attrs;
+};
+
+struct udev {
+	struct udev_device *dev[MAXDEVS];
+} _udev;
+
+struct udev_enumerate {
+	struct udev *udev;
+} _udev_enumerate;
+
+static void print_udev_device(const struct udev_device *dev)
+{
+//#define DEBUG_SCAN_SIMULATE
+#ifdef DEBUG_SCAN_SIMULATE
+	int i;
+
+	printf("[%s]\n", dev->syspath);
+
+	printf("props:\n");
+	for (i = 0; i < dev->props; i++)
+		printf("   %s: %s\n", dev->prop[i].key, dev->prop[i].val);
+
+	printf("attrs:\n");
+	for (i = 0; i < dev->attrs; i++)
+		printf("   %s: %s\n", dev->attr[i].key, dev->attr[i].val);
+#endif
+}
+
+#define __ADD_PROP(_dev, _key, args...) do { \
+	struct keyval *kv; \
+	igt_assert(dev->props <= MAXPROPS); \
+	kv = &(dev)->prop[(dev)->props]; \
+	strncpy(kv->key, (_key), NAME_MAX); \
+	snprintf(kv->val, NAME_MAX, args); \
+	(dev)->props++; \
+	} while (0)
+
+#define __ADD_ATTR(_dev, _key, args...) do { \
+	struct keyval *kv; \
+	igt_assert(dev->attrs <= MAXATTRS); \
+	kv = &(dev)->attr[(dev)->attrs]; \
+	strncpy(kv->key, (_key), NAME_MAX); \
+	snprintf(kv->val, NAME_MAX, args); \
+	(dev)->attrs++; \
+	} while (0)
+
+static struct udev_device *
+create_pci_udev_device(struct udev *udev,
+		       const char *syspath, const char *bdf,
+		       uint16_t vendor, uint16_t device, uint16_t subsystem)
+{
+	struct udev_device *dev;
+	char bus[13];
+
+	igt_assert(strlen(bdf) == 12);
+
+	dev = calloc(1, sizeof(*dev));
+	igt_assert(dev);
+
+	dev->parent = dev;
+	snprintf(dev->syspath, NAME_MAX, "%s", syspath);
+	strncpy(dev->subsystem, "pci", 4);
+
+	/* avoid compiler warning when copying less than 12 */
+	strncpy(bus, bdf, 13);
+	bus[7] = '\0';
+
+	__ADD_PROP(dev, "DEVPATH", "/devices/pci%s/%s", bus, bdf);
+	__ADD_PROP(dev, "DRIVER", "i915");
+	__ADD_PROP(dev, "PCI_CLASS", "30000");
+	__ADD_PROP(dev, "PCI_ID", "%04x:%04x", vendor, device);
+	__ADD_PROP(dev, "PCI_SLOT_NAME", "%s", bdf);
+	__ADD_PROP(dev, "PCI_SUBSYS_ID", "%04x:%04x", vendor, subsystem);
+	__ADD_PROP(dev, "SUBSYSTEM", "pci");
+
+	__ADD_ATTR(dev, "class", "0x030000");
+	__ADD_ATTR(dev, "device", "0x%04x", device);
+	__ADD_ATTR(dev, "subsystem", "pci");
+	__ADD_ATTR(dev, "subsystem_device", "0x%04x", subsystem);
+	__ADD_ATTR(dev, "subsystem_vendor", "0x%04x", vendor);
+	__ADD_ATTR(dev, "vendor", "0x%04x", vendor);
+
+	return dev;
+}
+
+static struct udev_device *
+create_drm_udev_device(struct udev *udev, struct udev_device *parent,
+		       const char *syspath, const char *bdf, int card,
+		       int major, int minor)
+{
+	struct udev_device *dev;
+	const char *name = card < 128 ? "card" : "render";
+	const char *drmname = card < 128 ? "card" : "renderD";
+	char bus[13];
+
+	igt_assert(strlen(bdf) == 12);
+
+	dev = calloc(1, sizeof(*dev));
+	igt_assert(dev);
+
+	dev->parent = parent;
+	snprintf(dev->syspath, NAME_MAX, "%s", syspath);
+	strncpy(dev->subsystem, "drm", 4);
+	snprintf(dev->devnode, NAME_MAX, "/dev/dri/%s%d", drmname, card);
+
+	/* avoid compiler warning when copying less than 12 */
+	strncpy(bus, bdf, 13);
+	bus[7] = '\0';
+
+	__ADD_PROP(dev, "DEVLINKS", "/dev/dri/by-path/pci-%s-%s", bdf, name);
+	__ADD_PROP(dev, "DEVNAME", "/dev/dri/%s%d", drmname, card);
+	__ADD_PROP(dev, "DEVPATH", "/devices/pci%s/%s/drm/%s%d", bus, bdf,
+		   drmname, card);
+	__ADD_PROP(dev, "DEVTYPE", "drm_minor");
+	__ADD_PROP(dev, "ID_PATH", "pci-%s", bdf);
+	__ADD_PROP(dev, "MAJOR", "%d", major);
+	__ADD_PROP(dev, "MINOR", "%d", minor);
+	__ADD_PROP(dev, "SUBSYSTEM", "drm");
+
+	__ADD_ATTR(dev, "dev", "%d:%d", major, minor);
+	__ADD_ATTR(dev, "subsystem", "drm");
+
+	return dev;
+}
+
+static struct udev_device **add_intel_dev(struct udev *udev, struct udev_device **dev,
+					  const char *pci_slot, uint16_t pci_device)
+{
+	struct udev_device **parent;
+	char bd[13], path[NAME_MAX];
+	static int card;
+
+	strncpy(bd, pci_slot, 13);
+	bd[7] = 0;
+
+	parent = dev;
+
+	snprintf(path, NAME_MAX, "/sys/devices/pci%s/%s", bd, pci_slot);
+	*dev++ = create_pci_udev_device(udev, path, pci_slot,
+					0x8086, pci_device, 0x2063);
+
+	snprintf(path, NAME_MAX, "/sys/devices/pci%s/%s/drm/card%d",
+		 bd, pci_slot, card);
+	*dev++ = create_drm_udev_device(udev, *parent, path, pci_slot,
+					card, 226, card);
+
+	snprintf(path, NAME_MAX, "/sys/devices/pci%s/%s/drm/renderD%d",
+		 bd, pci_slot, card + 128);
+	*dev++ = create_drm_udev_device(udev, *parent, path, pci_slot,
+					card + 128, 226, card + 128);
+
+	card++;
+
+	return dev;
+}
+
+struct udev *udev_new(void)
+{
+	struct udev *udev = &_udev;
+	struct udev_device **dev = udev->dev;
+
+	memset(dev, 0, sizeof(_udev.dev));
+
+	dev = add_intel_dev(udev, dev, "0000:00:02.0", 0x1926); /* skl */
+	dev = add_intel_dev(udev, dev, "0000:01:00.0", 0x56a1); /* dg2 */
+	dev = add_intel_dev(udev, dev, "0000:02:02.1", 0x9a40); /* tgl */
+	dev = add_intel_dev(udev, dev, "0000:03:01.0", 0x56a0); /* dg2 */
+	dev = add_intel_dev(udev, dev, "0000:04:02.0", 0x56a2); /* dg2 */
+
+	dev = udev->dev;
+	while (*dev)
+		print_udev_device(*dev++);
+
+	return &_udev;
+}
+
+struct udev_enumerate *udev_enumerate_new(struct udev *udev)
+{
+	_udev_enumerate.udev = udev;
+
+	return &_udev_enumerate;
+}
+
+int udev_enumerate_add_match_subsystem(struct udev_enumerate *udev_enumerate,
+				       const char *subsystem)
+{
+	return 0;
+}
+
+int udev_enumerate_add_match_property(struct udev_enumerate *udev_enumerate,
+				      const char *property, const char *value)
+{
+	return 0;
+}
+
+int udev_enumerate_scan_devices(struct udev_enumerate *udev_enumerate)
+{
+	return 0;
+}
+
+struct udev_list_entry *
+udev_enumerate_get_list_entry(struct udev_enumerate *udev_enumerate)
+{
+
+	_entry_dev.entry_type = TYPE_DEVICE;
+	_entry_dev.curr = 0;
+
+	return &_entry_dev;
+}
+
+struct udev_list_entry *
+udev_list_entry_get_next(struct udev_list_entry *list_entry)
+{
+	int curr, currdev = _entry_dev.curr;
+
+	switch (list_entry->entry_type) {
+	case TYPE_DEVICE:
+		if (_udev.dev[++list_entry->curr])
+			return list_entry;
+		break;
+	case TYPE_PROP:
+		curr = ++list_entry->curr;
+		if (curr < _udev.dev[currdev]->props)
+			return list_entry;
+		break;
+	case TYPE_ATTR:
+		curr = ++list_entry->curr;
+		if (curr < _udev.dev[currdev]->attrs)
+			return list_entry;
+		break;
+	}
+
+	return NULL;
+}
+
+const char *udev_list_entry_get_name(struct udev_list_entry *list_entry)
+{
+	int curr, currdev = _entry_dev.curr;
+
+	switch (list_entry->entry_type) {
+	case TYPE_DEVICE:
+		return _udev.dev[list_entry->curr]->syspath;
+	case TYPE_PROP:
+		curr = _entry_prop.curr;
+		return _udev.dev[currdev]->prop[curr].key;
+	case TYPE_ATTR:
+		curr = _entry_attr.curr;
+		return _udev.dev[currdev]->attr[curr].key;
+	}
+
+	return "UNKNOWN";
+}
+
+const char *udev_list_entry_get_value(struct udev_list_entry *list_entry)
+{
+	int curr, currdev = _entry_dev.curr;
+
+	switch (list_entry->entry_type) {
+	case TYPE_DEVICE:
+		return "";
+	case TYPE_PROP:
+		curr = _entry_prop.curr;
+		return _udev.dev[currdev]->prop[curr].val;
+	case TYPE_ATTR:
+		curr = _entry_attr.curr;
+		return _udev.dev[currdev]->attr[curr].val;
+	}
+
+	return "UNKNOWN";
+}
+
+struct udev_device *udev_device_new_from_syspath(struct udev *udev,
+						 const char *syspath)
+{
+	int i;
+
+	for (i = 0; i < sizeof(udev->dev); i++) {
+		if (!udev->dev[i])
+			return NULL;
+
+		if (strcmp(udev->dev[i]->syspath, syspath) == 0)
+			return udev->dev[i];
+	}
+
+	return NULL;
+}
+
+const char *udev_device_get_subsystem(struct udev_device *udev_device)
+{
+	return udev_device->subsystem;
+}
+
+const char *udev_device_get_syspath(struct udev_device *udev_device)
+{
+	return udev_device->syspath;
+}
+
+const char *udev_device_get_devnode(struct udev_device *udev_device)
+{
+	if (udev_device->devnode[0] == '\0')
+		return NULL;
+
+	return udev_device->devnode;
+}
+
+struct udev_list_entry *
+udev_device_get_properties_list_entry(struct udev_device *udev_device)
+{
+	_entry_prop.entry_type = TYPE_PROP;
+	_entry_prop.curr = 0;
+
+	return &_entry_prop;
+}
+
+struct udev_list_entry *
+udev_device_get_sysattr_list_entry(struct udev_device *udev_device)
+{
+	_entry_attr.entry_type = TYPE_ATTR;
+	_entry_attr.curr = 0;
+
+	return &_entry_attr;
+}
+
+const char *
+udev_device_get_sysattr_value(struct udev_device *udev_device, const char *sysattr)
+{
+	for (int i = 0; i < udev_device->attrs; i++)
+		if (strcmp(udev_device->attr[i].key, sysattr) == 0)
+			return udev_device->attr[i].val;
+
+	return "UNKNOWN";
+}
+
+const char *udev_device_get_sysname(struct udev_device *udev_device)
+{
+	return udev_device->syspath;
+}
+
+struct udev_device *udev_device_get_parent(struct udev_device *udev_device)
+{
+	return udev_device->parent;
+}
+
+struct udev_enumerate *udev_enumerate_unref(struct udev_enumerate *udev_enumerate)
+{
+	return NULL;
+}
+
+struct udev_device *udev_device_unref(struct udev_device *udev_device)
+{
+	return NULL;
+}
-- 
2.34.1

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [igt-dev] ✓ Fi.CI.BAT: success for Add codename in device selection (rev3)
  2022-07-14  4:17 [igt-dev] [PATCH i-g-t v3 0/6] Add codename in device selection Zbigniew Kempczyński
                   ` (5 preceding siblings ...)
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 6/6] lib/igt_device_scan: Simulate udev drm and pci device events Zbigniew Kempczyński
@ 2022-07-14  4:55 ` Patchwork
  2022-07-14  7:39 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
  7 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2022-07-14  4:55 UTC (permalink / raw)
  To: Zbigniew Kempczyński; +Cc: igt-dev

[-- Attachment #1: Type: text/plain, Size: 11283 bytes --]

== Series Details ==

Series: Add codename in device selection (rev3)
URL   : https://patchwork.freedesktop.org/series/106012/
State : success

== Summary ==

CI Bug Log - changes from IGT_6581 -> IGTPW_7515
====================================================

Summary
-------

  **SUCCESS**

  No regressions found.

  External URL: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/index.html

Participating hosts (33 -> 42)
------------------------------

  Additional (9): fi-kbl-soraka bat-adlm-1 bat-dg2-9 bat-adlp-6 bat-adlp-4 bat-jsl-3 bat-rpls-1 bat-rpls-2 bat-jsl-1 

Possible new issues
-------------------

  Here are the unknown changes that may have been introduced in IGTPW_7515:

### IGT changes ###

#### Suppressed ####

  The following results come from untrusted machines, tests, or statuses.
  They do not affect the overall result.

  * igt@kms_pipe_crc_basic@suspend-read-crc:
    - {bat-adlm-1}:       NOTRUN -> [SKIP][1]
   [1]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlm-1/igt@kms_pipe_crc_basic@suspend-read-crc.html

  
Known issues
------------

  Here are the changes found in IGTPW_7515 that come from known issues:

### IGT changes ###

#### Issues hit ####

  * igt@gem_exec_gttfill@basic:
    - fi-kbl-soraka:      NOTRUN -> [SKIP][2] ([fdo#109271]) +8 similar issues
   [2]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-kbl-soraka/igt@gem_exec_gttfill@basic.html

  * igt@gem_exec_suspend@basic-s3@smem:
    - fi-rkl-11600:       NOTRUN -> [INCOMPLETE][3] ([i915#6179])
   [3]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-rkl-11600/igt@gem_exec_suspend@basic-s3@smem.html

  * igt@gem_huc_copy@huc-copy:
    - fi-kbl-soraka:      NOTRUN -> [SKIP][4] ([fdo#109271] / [i915#2190])
   [4]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-kbl-soraka/igt@gem_huc_copy@huc-copy.html

  * igt@gem_lmem_swapping@basic:
    - fi-kbl-soraka:      NOTRUN -> [SKIP][5] ([fdo#109271] / [i915#4613]) +3 similar issues
   [5]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-kbl-soraka/igt@gem_lmem_swapping@basic.html

  * igt@gem_lmem_swapping@parallel-random-engines:
    - bat-adlp-4:         NOTRUN -> [SKIP][6] ([i915#4613]) +3 similar issues
   [6]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlp-4/igt@gem_lmem_swapping@parallel-random-engines.html

  * igt@gem_tiled_pread_basic:
    - bat-adlp-4:         NOTRUN -> [SKIP][7] ([i915#3282])
   [7]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlp-4/igt@gem_tiled_pread_basic.html

  * igt@i915_selftest@live@gem:
    - fi-blb-e6850:       NOTRUN -> [DMESG-FAIL][8] ([i915#4528])
   [8]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-blb-e6850/igt@i915_selftest@live@gem.html

  * igt@i915_selftest@live@gt_pm:
    - fi-kbl-soraka:      NOTRUN -> [DMESG-FAIL][9] ([i915#1886])
   [9]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-kbl-soraka/igt@i915_selftest@live@gt_pm.html
    - fi-icl-u2:          [PASS][10] -> [INCOMPLETE][11] ([i915#4890])
   [10]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/fi-icl-u2/igt@i915_selftest@live@gt_pm.html
   [11]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-icl-u2/igt@i915_selftest@live@gt_pm.html

  * igt@i915_selftest@live@hangcheck:
    - fi-hsw-g3258:       [PASS][12] -> [INCOMPLETE][13] ([i915#4785])
   [12]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/fi-hsw-g3258/igt@i915_selftest@live@hangcheck.html
   [13]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-hsw-g3258/igt@i915_selftest@live@hangcheck.html

  * igt@i915_selftest@live@requests:
    - bat-adlp-4:         NOTRUN -> [DMESG-FAIL][14] ([i915#5087])
   [14]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlp-4/igt@i915_selftest@live@requests.html

  * igt@i915_suspend@basic-s3-without-i915:
    - bat-adlp-4:         NOTRUN -> [SKIP][15] ([i915#5903])
   [15]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlp-4/igt@i915_suspend@basic-s3-without-i915.html

  * igt@kms_chamelium@common-hpd-after-suspend:
    - fi-bsw-n3050:       NOTRUN -> [SKIP][16] ([fdo#109271] / [fdo#111827])
   [16]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-bsw-n3050/igt@kms_chamelium@common-hpd-after-suspend.html

  * igt@kms_chamelium@dp-crc-fast:
    - bat-adlp-4:         NOTRUN -> [SKIP][17] ([fdo#111827]) +8 similar issues
   [17]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlp-4/igt@kms_chamelium@dp-crc-fast.html

  * igt@kms_chamelium@hdmi-hpd-fast:
    - fi-kbl-soraka:      NOTRUN -> [SKIP][18] ([fdo#109271] / [fdo#111827]) +7 similar issues
   [18]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-kbl-soraka/igt@kms_chamelium@hdmi-hpd-fast.html

  * igt@kms_cursor_legacy@basic-busy-flip-before-cursor:
    - bat-adlp-4:         NOTRUN -> [SKIP][19] ([i915#4103])
   [19]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlp-4/igt@kms_cursor_legacy@basic-busy-flip-before-cursor.html

  * igt@kms_force_connector_basic@force-load-detect:
    - bat-adlp-4:         NOTRUN -> [SKIP][20] ([i915#4093]) +3 similar issues
   [20]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlp-4/igt@kms_force_connector_basic@force-load-detect.html

  * igt@kms_setmode@basic-clone-single-crtc:
    - bat-adlp-4:         NOTRUN -> [SKIP][21] ([i915#3555] / [i915#4579])
   [21]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlp-4/igt@kms_setmode@basic-clone-single-crtc.html

  * igt@prime_vgem@basic-userptr:
    - bat-adlp-4:         NOTRUN -> [SKIP][22] ([fdo#109295] / [i915#3301] / [i915#3708])
   [22]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlp-4/igt@prime_vgem@basic-userptr.html

  * igt@prime_vgem@basic-write:
    - bat-adlp-4:         NOTRUN -> [SKIP][23] ([fdo#109295] / [i915#3291] / [i915#3708]) +2 similar issues
   [23]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/bat-adlp-4/igt@prime_vgem@basic-write.html

  * igt@runner@aborted:
    - fi-hsw-g3258:       NOTRUN -> [FAIL][24] ([fdo#109271] / [i915#4312] / [i915#6246])
   [24]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-hsw-g3258/igt@runner@aborted.html

  
#### Possible fixes ####

  * igt@i915_selftest@live@execlists:
    - fi-bsw-n3050:       [INCOMPLETE][25] ([i915#2940]) -> [PASS][26]
   [25]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/fi-bsw-n3050/igt@i915_selftest@live@execlists.html
   [26]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-bsw-n3050/igt@i915_selftest@live@execlists.html

  * igt@i915_selftest@live@requests:
    - fi-blb-e6850:       [DMESG-FAIL][27] ([i915#4528]) -> [PASS][28]
   [27]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/fi-blb-e6850/igt@i915_selftest@live@requests.html
   [28]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-blb-e6850/igt@i915_selftest@live@requests.html

  
#### Warnings ####

  * igt@i915_suspend@basic-s3-without-i915:
    - fi-rkl-11600:       [INCOMPLETE][29] ([i915#5982]) -> [FAIL][30] ([fdo#103375])
   [29]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/fi-rkl-11600/igt@i915_suspend@basic-s3-without-i915.html
   [30]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/fi-rkl-11600/igt@i915_suspend@basic-s3-without-i915.html

  
  {name}: This element is suppressed. This means it is ignored when computing
          the status of the difference (SUCCESS, WARNING, or FAILURE).

  [fdo#103375]: https://bugs.freedesktop.org/show_bug.cgi?id=103375
  [fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
  [fdo#109285]: https://bugs.freedesktop.org/show_bug.cgi?id=109285
  [fdo#109295]: https://bugs.freedesktop.org/show_bug.cgi?id=109295
  [fdo#111827]: https://bugs.freedesktop.org/show_bug.cgi?id=111827
  [i915#1072]: https://gitlab.freedesktop.org/drm/intel/issues/1072
  [i915#1155]: https://gitlab.freedesktop.org/drm/intel/issues/1155
  [i915#1845]: https://gitlab.freedesktop.org/drm/intel/issues/1845
  [i915#1849]: https://gitlab.freedesktop.org/drm/intel/issues/1849
  [i915#1886]: https://gitlab.freedesktop.org/drm/intel/issues/1886
  [i915#2190]: https://gitlab.freedesktop.org/drm/intel/issues/2190
  [i915#2582]: https://gitlab.freedesktop.org/drm/intel/issues/2582
  [i915#2867]: https://gitlab.freedesktop.org/drm/intel/issues/2867
  [i915#2940]: https://gitlab.freedesktop.org/drm/intel/issues/2940
  [i915#3003]: https://gitlab.freedesktop.org/drm/intel/issues/3003
  [i915#3282]: https://gitlab.freedesktop.org/drm/intel/issues/3282
  [i915#3291]: https://gitlab.freedesktop.org/drm/intel/issues/3291
  [i915#3301]: https://gitlab.freedesktop.org/drm/intel/issues/3301
  [i915#3555]: https://gitlab.freedesktop.org/drm/intel/issues/3555
  [i915#3595]: https://gitlab.freedesktop.org/drm/intel/issues/3595
  [i915#3637]: https://gitlab.freedesktop.org/drm/intel/issues/3637
  [i915#3708]: https://gitlab.freedesktop.org/drm/intel/issues/3708
  [i915#4077]: https://gitlab.freedesktop.org/drm/intel/issues/4077
  [i915#4079]: https://gitlab.freedesktop.org/drm/intel/issues/4079
  [i915#4083]: https://gitlab.freedesktop.org/drm/intel/issues/4083
  [i915#4093]: https://gitlab.freedesktop.org/drm/intel/issues/4093
  [i915#4103]: https://gitlab.freedesktop.org/drm/intel/issues/4103
  [i915#4212]: https://gitlab.freedesktop.org/drm/intel/issues/4212
  [i915#4213]: https://gitlab.freedesktop.org/drm/intel/issues/4213
  [i915#4215]: https://gitlab.freedesktop.org/drm/intel/issues/4215
  [i915#4258]: https://gitlab.freedesktop.org/drm/intel/issues/4258
  [i915#4312]: https://gitlab.freedesktop.org/drm/intel/issues/4312
  [i915#4528]: https://gitlab.freedesktop.org/drm/intel/issues/4528
  [i915#4579]: https://gitlab.freedesktop.org/drm/intel/issues/4579
  [i915#4613]: https://gitlab.freedesktop.org/drm/intel/issues/4613
  [i915#4785]: https://gitlab.freedesktop.org/drm/intel/issues/4785
  [i915#4873]: https://gitlab.freedesktop.org/drm/intel/issues/4873
  [i915#4890]: https://gitlab.freedesktop.org/drm/intel/issues/4890
  [i915#4983]: https://gitlab.freedesktop.org/drm/intel/issues/4983
  [i915#5087]: https://gitlab.freedesktop.org/drm/intel/issues/5087
  [i915#5174]: https://gitlab.freedesktop.org/drm/intel/issues/5174
  [i915#5190]: https://gitlab.freedesktop.org/drm/intel/issues/5190
  [i915#5274]: https://gitlab.freedesktop.org/drm/intel/issues/5274
  [i915#5537]: https://gitlab.freedesktop.org/drm/intel/issues/5537
  [i915#5763]: https://gitlab.freedesktop.org/drm/intel/issues/5763
  [i915#5903]: https://gitlab.freedesktop.org/drm/intel/issues/5903
  [i915#5982]: https://gitlab.freedesktop.org/drm/intel/issues/5982
  [i915#6179]: https://gitlab.freedesktop.org/drm/intel/issues/6179
  [i915#6246]: https://gitlab.freedesktop.org/drm/intel/issues/6246
  [i915#6367]: https://gitlab.freedesktop.org/drm/intel/issues/6367


Build changes
-------------

  * CI: CI-20190529 -> None
  * IGT: IGT_6581 -> IGTPW_7515

  CI-20190529: 20190529
  CI_DRM_11877: e55cefc370de5a38ee848aa96082d9d9f4cacdb9 @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_7515: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/index.html
  IGT_6581: 3c3a4cc75cfa7f6f34f2803ba68b0e8c5d1956e5 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/index.html

[-- Attachment #2: Type: text/html, Size: 11521 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [igt-dev] ✗ Fi.CI.IGT: failure for Add codename in device selection (rev3)
  2022-07-14  4:17 [igt-dev] [PATCH i-g-t v3 0/6] Add codename in device selection Zbigniew Kempczyński
                   ` (6 preceding siblings ...)
  2022-07-14  4:55 ` [igt-dev] ✓ Fi.CI.BAT: success for Add codename in device selection (rev3) Patchwork
@ 2022-07-14  7:39 ` Patchwork
  7 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2022-07-14  7:39 UTC (permalink / raw)
  To: Zbigniew Kempczyński; +Cc: igt-dev

[-- Attachment #1: Type: text/plain, Size: 48843 bytes --]

== Series Details ==

Series: Add codename in device selection (rev3)
URL   : https://patchwork.freedesktop.org/series/106012/
State : failure

== Summary ==

CI Bug Log - changes from IGT_6581_full -> IGTPW_7515_full
====================================================

Summary
-------

  **FAILURE**

  Serious unknown changes coming with IGTPW_7515_full absolutely need to be
  verified manually.
  
  If you think the reported changes have nothing to do with the changes
  introduced in IGTPW_7515_full, please notify your bug team to allow them
  to document this new failure mode, which will reduce false positives in CI.

  External URL: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/index.html

Participating hosts (9 -> 9)
------------------------------

  No changes in participating hosts

Possible new issues
-------------------

  Here are the unknown changes that may have been introduced in IGTPW_7515_full:

### IGT changes ###

#### Possible regressions ####

  * igt@kms_plane_cursor@pipe-d-viewport-size-256:
    - shard-tglb:         [PASS][1] -> [INCOMPLETE][2]
   [1]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-tglb7/igt@kms_plane_cursor@pipe-d-viewport-size-256.html
   [2]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb8/igt@kms_plane_cursor@pipe-d-viewport-size-256.html

  
#### Suppressed ####

  The following results come from untrusted machines, tests, or statuses.
  They do not affect the overall result.

  * igt@gem_exec_fair@basic-deadline:
    - {shard-rkl}:        [PASS][3] -> [FAIL][4]
   [3]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-4/igt@gem_exec_fair@basic-deadline.html
   [4]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-2/igt@gem_exec_fair@basic-deadline.html

  
Known issues
------------

  Here are the changes found in IGTPW_7515_full that come from known issues:

### IGT changes ###

#### Issues hit ####

  * igt@gem_ccs@ctrl-surf-copy-new-ctx:
    - shard-iclb:         NOTRUN -> [SKIP][5] ([i915#5327])
   [5]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb1/igt@gem_ccs@ctrl-surf-copy-new-ctx.html
    - shard-tglb:         NOTRUN -> [SKIP][6] ([i915#5325])
   [6]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb2/igt@gem_ccs@ctrl-surf-copy-new-ctx.html

  * igt@gem_create@create-massive:
    - shard-glk:          NOTRUN -> [DMESG-WARN][7] ([i915#4991])
   [7]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-glk3/igt@gem_create@create-massive.html

  * igt@gem_ctx_isolation@preservation-s3@rcs0:
    - shard-apl:          NOTRUN -> [DMESG-WARN][8] ([i915#180])
   [8]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl7/igt@gem_ctx_isolation@preservation-s3@rcs0.html

  * igt@gem_ctx_persistence@engines-queued:
    - shard-snb:          NOTRUN -> [SKIP][9] ([fdo#109271] / [i915#1099]) +1 similar issue
   [9]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-snb7/igt@gem_ctx_persistence@engines-queued.html

  * igt@gem_eio@in-flight-contexts-immediate:
    - shard-tglb:         [PASS][10] -> [TIMEOUT][11] ([i915#3063])
   [10]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-tglb1/igt@gem_eio@in-flight-contexts-immediate.html
   [11]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb7/igt@gem_eio@in-flight-contexts-immediate.html

  * igt@gem_eio@unwedge-stress:
    - shard-tglb:         [PASS][12] -> [FAIL][13] ([i915#5784])
   [12]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-tglb7/igt@gem_eio@unwedge-stress.html
   [13]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb3/igt@gem_eio@unwedge-stress.html

  * igt@gem_exec_balancer@parallel-keep-submit-fence:
    - shard-iclb:         [PASS][14] -> [SKIP][15] ([i915#4525])
   [14]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb2/igt@gem_exec_balancer@parallel-keep-submit-fence.html
   [15]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb3/igt@gem_exec_balancer@parallel-keep-submit-fence.html

  * igt@gem_exec_balancer@parallel-ordering:
    - shard-kbl:          NOTRUN -> [FAIL][16] ([i915#6117])
   [16]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl6/igt@gem_exec_balancer@parallel-ordering.html

  * igt@gem_exec_fair@basic-none@vcs0:
    - shard-apl:          [PASS][17] -> [FAIL][18] ([i915#2842])
   [17]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-apl7/igt@gem_exec_fair@basic-none@vcs0.html
   [18]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl4/igt@gem_exec_fair@basic-none@vcs0.html

  * igt@gem_exec_fair@basic-none@vcs1:
    - shard-iclb:         NOTRUN -> [FAIL][19] ([i915#2842]) +1 similar issue
   [19]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb1/igt@gem_exec_fair@basic-none@vcs1.html

  * igt@gem_exec_fair@basic-pace@vecs0:
    - shard-kbl:          [PASS][20] -> [FAIL][21] ([i915#2842]) +2 similar issues
   [20]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl7/igt@gem_exec_fair@basic-pace@vecs0.html
   [21]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl6/igt@gem_exec_fair@basic-pace@vecs0.html

  * igt@gem_exec_fair@basic-throttle@rcs0:
    - shard-iclb:         [PASS][22] -> [FAIL][23] ([i915#2842]) +1 similar issue
   [22]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb1/igt@gem_exec_fair@basic-throttle@rcs0.html
   [23]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb8/igt@gem_exec_fair@basic-throttle@rcs0.html

  * igt@gem_lmem_swapping@parallel-random-engines:
    - shard-apl:          NOTRUN -> [SKIP][24] ([fdo#109271] / [i915#4613]) +1 similar issue
   [24]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl7/igt@gem_lmem_swapping@parallel-random-engines.html

  * igt@gem_lmem_swapping@parallel-random-verify:
    - shard-glk:          NOTRUN -> [SKIP][25] ([fdo#109271] / [i915#4613])
   [25]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-glk9/igt@gem_lmem_swapping@parallel-random-verify.html

  * igt@gem_lmem_swapping@verify:
    - shard-kbl:          NOTRUN -> [SKIP][26] ([fdo#109271] / [i915#4613]) +3 similar issues
   [26]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl1/igt@gem_lmem_swapping@verify.html

  * igt@gem_pxp@regular-baseline-src-copy-readible:
    - shard-tglb:         NOTRUN -> [SKIP][27] ([i915#4270])
   [27]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb1/igt@gem_pxp@regular-baseline-src-copy-readible.html
    - shard-iclb:         NOTRUN -> [SKIP][28] ([i915#4270])
   [28]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb1/igt@gem_pxp@regular-baseline-src-copy-readible.html

  * igt@gem_workarounds@suspend-resume:
    - shard-apl:          [PASS][29] -> [DMESG-WARN][30] ([i915#180]) +1 similar issue
   [29]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-apl2/igt@gem_workarounds@suspend-resume.html
   [30]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl2/igt@gem_workarounds@suspend-resume.html

  * igt@gen7_exec_parse@chained-batch:
    - shard-tglb:         NOTRUN -> [SKIP][31] ([fdo#109289]) +1 similar issue
   [31]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb3/igt@gen7_exec_parse@chained-batch.html
    - shard-iclb:         NOTRUN -> [SKIP][32] ([fdo#109289]) +1 similar issue
   [32]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb7/igt@gen7_exec_parse@chained-batch.html

  * igt@gen9_exec_parse@shadow-peek:
    - shard-tglb:         NOTRUN -> [SKIP][33] ([i915#2527] / [i915#2856])
   [33]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb3/igt@gen9_exec_parse@shadow-peek.html
    - shard-iclb:         NOTRUN -> [SKIP][34] ([i915#2856])
   [34]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb1/igt@gen9_exec_parse@shadow-peek.html

  * igt@i915_pm_dc@dc6-dpms:
    - shard-kbl:          NOTRUN -> [FAIL][35] ([i915#454])
   [35]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl1/igt@i915_pm_dc@dc6-dpms.html

  * igt@kms_atomic@plane-primary-overlay-mutable-zpos:
    - shard-tglb:         NOTRUN -> [SKIP][36] ([i915#404])
   [36]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb5/igt@kms_atomic@plane-primary-overlay-mutable-zpos.html
    - shard-iclb:         NOTRUN -> [SKIP][37] ([i915#404])
   [37]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb5/igt@kms_atomic@plane-primary-overlay-mutable-zpos.html

  * igt@kms_big_fb@4-tiled-8bpp-rotate-0:
    - shard-tglb:         NOTRUN -> [SKIP][38] ([i915#5286])
   [38]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb2/igt@kms_big_fb@4-tiled-8bpp-rotate-0.html
    - shard-iclb:         NOTRUN -> [SKIP][39] ([i915#5286])
   [39]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_big_fb@4-tiled-8bpp-rotate-0.html

  * igt@kms_big_fb@yf-tiled-max-hw-stride-64bpp-rotate-180-async-flip:
    - shard-tglb:         NOTRUN -> [SKIP][40] ([fdo#111615])
   [40]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb2/igt@kms_big_fb@yf-tiled-max-hw-stride-64bpp-rotate-180-async-flip.html
    - shard-iclb:         NOTRUN -> [SKIP][41] ([fdo#110723])
   [41]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_big_fb@yf-tiled-max-hw-stride-64bpp-rotate-180-async-flip.html

  * igt@kms_ccs@pipe-a-bad-pixel-format-y_tiled_ccs:
    - shard-tglb:         NOTRUN -> [SKIP][42] ([i915#3689])
   [42]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb2/igt@kms_ccs@pipe-a-bad-pixel-format-y_tiled_ccs.html

  * igt@kms_ccs@pipe-a-missing-ccs-buffer-y_tiled_gen12_rc_ccs:
    - shard-iclb:         NOTRUN -> [SKIP][43] ([fdo#109278]) +4 similar issues
   [43]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb8/igt@kms_ccs@pipe-a-missing-ccs-buffer-y_tiled_gen12_rc_ccs.html

  * igt@kms_ccs@pipe-a-random-ccs-data-y_tiled_gen12_mc_ccs:
    - shard-kbl:          NOTRUN -> [SKIP][44] ([fdo#109271] / [i915#3886]) +3 similar issues
   [44]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl1/igt@kms_ccs@pipe-a-random-ccs-data-y_tiled_gen12_mc_ccs.html

  * igt@kms_ccs@pipe-b-bad-aux-stride-y_tiled_gen12_mc_ccs:
    - shard-apl:          NOTRUN -> [SKIP][45] ([fdo#109271] / [i915#3886]) +2 similar issues
   [45]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl8/igt@kms_ccs@pipe-b-bad-aux-stride-y_tiled_gen12_mc_ccs.html

  * igt@kms_ccs@pipe-c-bad-pixel-format-yf_tiled_ccs:
    - shard-tglb:         NOTRUN -> [SKIP][46] ([fdo#111615] / [i915#3689])
   [46]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb1/igt@kms_ccs@pipe-c-bad-pixel-format-yf_tiled_ccs.html

  * igt@kms_ccs@pipe-c-ccs-on-another-bo-y_tiled_gen12_mc_ccs:
    - shard-glk:          NOTRUN -> [SKIP][47] ([fdo#109271] / [i915#3886]) +1 similar issue
   [47]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-glk6/igt@kms_ccs@pipe-c-ccs-on-another-bo-y_tiled_gen12_mc_ccs.html

  * igt@kms_cdclk@mode-transition:
    - shard-glk:          NOTRUN -> [SKIP][48] ([fdo#109271]) +71 similar issues
   [48]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-glk8/igt@kms_cdclk@mode-transition.html
    - shard-iclb:         NOTRUN -> [SKIP][49] ([i915#3742])
   [49]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb5/igt@kms_cdclk@mode-transition.html
    - shard-tglb:         NOTRUN -> [SKIP][50] ([i915#3742])
   [50]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb5/igt@kms_cdclk@mode-transition.html

  * igt@kms_chamelium@hdmi-edid-change-during-suspend:
    - shard-snb:          NOTRUN -> [SKIP][51] ([fdo#109271] / [fdo#111827]) +4 similar issues
   [51]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-snb7/igt@kms_chamelium@hdmi-edid-change-during-suspend.html

  * igt@kms_color_chamelium@pipe-a-gamma:
    - shard-kbl:          NOTRUN -> [SKIP][52] ([fdo#109271] / [fdo#111827]) +19 similar issues
   [52]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl1/igt@kms_color_chamelium@pipe-a-gamma.html

  * igt@kms_color_chamelium@pipe-b-degamma:
    - shard-tglb:         NOTRUN -> [SKIP][53] ([fdo#109284] / [fdo#111827]) +1 similar issue
   [53]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb3/igt@kms_color_chamelium@pipe-b-degamma.html
    - shard-glk:          NOTRUN -> [SKIP][54] ([fdo#109271] / [fdo#111827]) +3 similar issues
   [54]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-glk6/igt@kms_color_chamelium@pipe-b-degamma.html
    - shard-iclb:         NOTRUN -> [SKIP][55] ([fdo#109284] / [fdo#111827]) +2 similar issues
   [55]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_color_chamelium@pipe-b-degamma.html

  * igt@kms_color_chamelium@pipe-d-ctm-red-to-blue:
    - shard-apl:          NOTRUN -> [SKIP][56] ([fdo#109271] / [fdo#111827]) +8 similar issues
   [56]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl1/igt@kms_color_chamelium@pipe-d-ctm-red-to-blue.html

  * igt@kms_cursor_crc@cursor-rapid-movement@pipe-b-dp-1-32x10:
    - shard-apl:          NOTRUN -> [SKIP][57] ([fdo#109271]) +170 similar issues
   [57]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl1/igt@kms_cursor_crc@cursor-rapid-movement@pipe-b-dp-1-32x10.html

  * igt@kms_cursor_legacy@2x-flip-vs-cursor-atomic:
    - shard-tglb:         NOTRUN -> [SKIP][58] ([fdo#109274] / [fdo#111825])
   [58]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb1/igt@kms_cursor_legacy@2x-flip-vs-cursor-atomic.html
    - shard-iclb:         NOTRUN -> [SKIP][59] ([fdo#109274]) +1 similar issue
   [59]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb4/igt@kms_cursor_legacy@2x-flip-vs-cursor-atomic.html

  * igt@kms_cursor_legacy@cursor-vs-flip@toggle:
    - shard-iclb:         [PASS][60] -> [FAIL][61] ([i915#5072])
   [60]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb2/igt@kms_cursor_legacy@cursor-vs-flip@toggle.html
   [61]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb7/igt@kms_cursor_legacy@cursor-vs-flip@toggle.html

  * igt@kms_cursor_legacy@flip-vs-cursor@atomic-transitions-varying-size:
    - shard-apl:          [PASS][62] -> [FAIL][63] ([i915#2346])
   [62]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-apl7/igt@kms_cursor_legacy@flip-vs-cursor@atomic-transitions-varying-size.html
   [63]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl4/igt@kms_cursor_legacy@flip-vs-cursor@atomic-transitions-varying-size.html

  * igt@kms_draw_crc@draw-method-xrgb2101010-mmap-wc-4tiled:
    - shard-tglb:         NOTRUN -> [SKIP][64] ([i915#5287])
   [64]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb5/igt@kms_draw_crc@draw-method-xrgb2101010-mmap-wc-4tiled.html
    - shard-iclb:         NOTRUN -> [SKIP][65] ([i915#5287])
   [65]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb5/igt@kms_draw_crc@draw-method-xrgb2101010-mmap-wc-4tiled.html

  * igt@kms_flip@2x-busy-flip:
    - shard-tglb:         NOTRUN -> [SKIP][66] ([fdo#109274] / [fdo#111825] / [i915#3637])
   [66]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb5/igt@kms_flip@2x-busy-flip.html

  * igt@kms_flip_scaled_crc@flip-64bpp-4tile-to-32bpp-4tile-upscaling@pipe-a-valid-mode:
    - shard-iclb:         NOTRUN -> [SKIP][67] ([i915#2672]) +4 similar issues
   [67]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb6/igt@kms_flip_scaled_crc@flip-64bpp-4tile-to-32bpp-4tile-upscaling@pipe-a-valid-mode.html

  * igt@kms_flip_scaled_crc@flip-64bpp-ytile-to-16bpp-ytile-downscaling@pipe-a-default-mode:
    - shard-iclb:         NOTRUN -> [SKIP][68] ([i915#3555])
   [68]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_flip_scaled_crc@flip-64bpp-ytile-to-16bpp-ytile-downscaling@pipe-a-default-mode.html

  * igt@kms_flip_scaled_crc@flip-64bpp-ytile-to-32bpp-ytilegen12rcccs-upscaling@pipe-a-default-mode:
    - shard-iclb:         NOTRUN -> [SKIP][69] ([i915#2672] / [i915#3555])
   [69]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_flip_scaled_crc@flip-64bpp-ytile-to-32bpp-ytilegen12rcccs-upscaling@pipe-a-default-mode.html

  * igt@kms_frontbuffer_tracking@fbcpsr-2p-primscrn-shrfb-pgflip-blt:
    - shard-iclb:         NOTRUN -> [SKIP][70] ([fdo#109280]) +7 similar issues
   [70]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb5/igt@kms_frontbuffer_tracking@fbcpsr-2p-primscrn-shrfb-pgflip-blt.html

  * igt@kms_frontbuffer_tracking@fbcpsr-rgb565-draw-mmap-gtt:
    - shard-kbl:          NOTRUN -> [SKIP][71] ([fdo#109271]) +241 similar issues
   [71]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl1/igt@kms_frontbuffer_tracking@fbcpsr-rgb565-draw-mmap-gtt.html

  * igt@kms_frontbuffer_tracking@psr-2p-scndscrn-pri-indfb-draw-pwrite:
    - shard-tglb:         NOTRUN -> [SKIP][72] ([fdo#109280] / [fdo#111825]) +7 similar issues
   [72]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb5/igt@kms_frontbuffer_tracking@psr-2p-scndscrn-pri-indfb-draw-pwrite.html

  * igt@kms_plane_alpha_blend@pipe-a-alpha-basic:
    - shard-kbl:          NOTRUN -> [FAIL][73] ([fdo#108145] / [i915#265]) +2 similar issues
   [73]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl4/igt@kms_plane_alpha_blend@pipe-a-alpha-basic.html

  * igt@kms_plane_alpha_blend@pipe-b-alpha-basic:
    - shard-glk:          NOTRUN -> [FAIL][74] ([fdo#108145] / [i915#265])
   [74]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-glk9/igt@kms_plane_alpha_blend@pipe-b-alpha-basic.html

  * igt@kms_plane_lowres@tiling-yf:
    - shard-tglb:         NOTRUN -> [SKIP][75] ([fdo#112054])
   [75]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb5/igt@kms_plane_lowres@tiling-yf.html

  * igt@kms_plane_lowres@tiling-yf@pipe-a-edp-1:
    - shard-iclb:         NOTRUN -> [SKIP][76] ([i915#3536]) +2 similar issues
   [76]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb5/igt@kms_plane_lowres@tiling-yf@pipe-a-edp-1.html

  * igt@kms_plane_scaling@plane-downscale-with-modifiers-factor-0-25@pipe-b-edp-1:
    - shard-iclb:         NOTRUN -> [SKIP][77] ([i915#5176]) +2 similar issues
   [77]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_plane_scaling@plane-downscale-with-modifiers-factor-0-25@pipe-b-edp-1.html

  * igt@kms_plane_scaling@plane-downscale-with-modifiers-factor-0-25@pipe-d-edp-1:
    - shard-tglb:         NOTRUN -> [SKIP][78] ([i915#5176]) +3 similar issues
   [78]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb1/igt@kms_plane_scaling@plane-downscale-with-modifiers-factor-0-25@pipe-d-edp-1.html

  * igt@kms_plane_scaling@planes-downscale-factor-0-5@pipe-a-edp-1:
    - shard-iclb:         [PASS][79] -> [SKIP][80] ([i915#5235]) +2 similar issues
   [79]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb8/igt@kms_plane_scaling@planes-downscale-factor-0-5@pipe-a-edp-1.html
   [80]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_plane_scaling@planes-downscale-factor-0-5@pipe-a-edp-1.html

  * igt@kms_plane_scaling@planes-upscale-20x20-downscale-factor-0-5@pipe-b-edp-1:
    - shard-iclb:         NOTRUN -> [SKIP][81] ([i915#5235]) +2 similar issues
   [81]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_plane_scaling@planes-upscale-20x20-downscale-factor-0-5@pipe-b-edp-1.html

  * igt@kms_psr2_sf@overlay-plane-move-continuous-sf:
    - shard-apl:          NOTRUN -> [SKIP][82] ([fdo#109271] / [i915#658]) +1 similar issue
   [82]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl1/igt@kms_psr2_sf@overlay-plane-move-continuous-sf.html

  * igt@kms_psr2_sf@overlay-primary-update-sf-dmg-area:
    - shard-tglb:         NOTRUN -> [SKIP][83] ([i915#2920])
   [83]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb5/igt@kms_psr2_sf@overlay-primary-update-sf-dmg-area.html
    - shard-glk:          NOTRUN -> [SKIP][84] ([fdo#109271] / [i915#658]) +1 similar issue
   [84]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-glk2/igt@kms_psr2_sf@overlay-primary-update-sf-dmg-area.html
    - shard-iclb:         NOTRUN -> [SKIP][85] ([fdo#111068] / [i915#658])
   [85]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb3/igt@kms_psr2_sf@overlay-primary-update-sf-dmg-area.html

  * igt@kms_psr2_su@page_flip-xrgb8888:
    - shard-iclb:         [PASS][86] -> [SKIP][87] ([fdo#109642] / [fdo#111068] / [i915#658])
   [86]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb2/igt@kms_psr2_su@page_flip-xrgb8888.html
   [87]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb3/igt@kms_psr2_su@page_flip-xrgb8888.html
    - shard-kbl:          NOTRUN -> [SKIP][88] ([fdo#109271] / [i915#658]) +2 similar issues
   [88]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl4/igt@kms_psr2_su@page_flip-xrgb8888.html

  * igt@kms_psr@psr2_cursor_plane_move:
    - shard-iclb:         [PASS][89] -> [SKIP][90] ([fdo#109441]) +1 similar issue
   [89]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb2/igt@kms_psr@psr2_cursor_plane_move.html
   [90]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb6/igt@kms_psr@psr2_cursor_plane_move.html

  * igt@kms_psr@psr2_sprite_plane_move:
    - shard-iclb:         NOTRUN -> [SKIP][91] ([fdo#109441])
   [91]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb1/igt@kms_psr@psr2_sprite_plane_move.html
    - shard-tglb:         NOTRUN -> [FAIL][92] ([i915#132] / [i915#3467])
   [92]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb1/igt@kms_psr@psr2_sprite_plane_move.html

  * igt@kms_psr_stress_test@invalidate-primary-flip-overlay:
    - shard-tglb:         [PASS][93] -> [SKIP][94] ([i915#5519])
   [93]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-tglb1/igt@kms_psr_stress_test@invalidate-primary-flip-overlay.html
   [94]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb5/igt@kms_psr_stress_test@invalidate-primary-flip-overlay.html
    - shard-iclb:         [PASS][95] -> [SKIP][96] ([i915#5519])
   [95]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb8/igt@kms_psr_stress_test@invalidate-primary-flip-overlay.html
   [96]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb5/igt@kms_psr_stress_test@invalidate-primary-flip-overlay.html

  * igt@kms_rotation_crc@primary-4-tiled-reflect-x-180:
    - shard-iclb:         NOTRUN -> [SKIP][97] ([i915#5289])
   [97]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb4/igt@kms_rotation_crc@primary-4-tiled-reflect-x-180.html
    - shard-tglb:         NOTRUN -> [SKIP][98] ([i915#5289])
   [98]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb1/igt@kms_rotation_crc@primary-4-tiled-reflect-x-180.html

  * igt@kms_vblank@pipe-c-query-busy-hang:
    - shard-snb:          NOTRUN -> [SKIP][99] ([fdo#109271]) +132 similar issues
   [99]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-snb7/igt@kms_vblank@pipe-c-query-busy-hang.html

  * igt@kms_vblank@pipe-d-wait-idle:
    - shard-kbl:          NOTRUN -> [SKIP][100] ([fdo#109271] / [i915#533])
   [100]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl1/igt@kms_vblank@pipe-d-wait-idle.html

  * igt@kms_writeback@writeback-invalid-parameters:
    - shard-kbl:          NOTRUN -> [SKIP][101] ([fdo#109271] / [i915#2437])
   [101]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl7/igt@kms_writeback@writeback-invalid-parameters.html

  * igt@nouveau_crc@pipe-b-source-outp-inactive:
    - shard-tglb:         NOTRUN -> [SKIP][102] ([i915#2530])
   [102]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb7/igt@nouveau_crc@pipe-b-source-outp-inactive.html
    - shard-iclb:         NOTRUN -> [SKIP][103] ([i915#2530])
   [103]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb6/igt@nouveau_crc@pipe-b-source-outp-inactive.html

  * igt@prime_nv_api@i915_nv_import_twice:
    - shard-tglb:         NOTRUN -> [SKIP][104] ([fdo#109291]) +1 similar issue
   [104]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglb2/igt@prime_nv_api@i915_nv_import_twice.html
    - shard-iclb:         NOTRUN -> [SKIP][105] ([fdo#109291]) +1 similar issue
   [105]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb4/igt@prime_nv_api@i915_nv_import_twice.html

  * igt@sysfs_clients@busy:
    - shard-apl:          NOTRUN -> [SKIP][106] ([fdo#109271] / [i915#2994])
   [106]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl7/igt@sysfs_clients@busy.html
    - shard-kbl:          NOTRUN -> [SKIP][107] ([fdo#109271] / [i915#2994]) +1 similar issue
   [107]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl4/igt@sysfs_clients@busy.html

  
#### Possible fixes ####

  * igt@fbdev@eof:
    - {shard-rkl}:        [SKIP][108] ([i915#2582]) -> [PASS][109]
   [108]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-4/igt@fbdev@eof.html
   [109]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-2/igt@fbdev@eof.html

  * igt@gem_exec_balancer@parallel-balancer:
    - shard-iclb:         [SKIP][110] ([i915#4525]) -> [PASS][111]
   [110]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb8/igt@gem_exec_balancer@parallel-balancer.html
   [111]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@gem_exec_balancer@parallel-balancer.html

  * igt@gem_exec_fair@basic-none@vcs1:
    - shard-kbl:          [FAIL][112] ([i915#2842]) -> [PASS][113] +4 similar issues
   [112]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl7/igt@gem_exec_fair@basic-none@vcs1.html
   [113]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl7/igt@gem_exec_fair@basic-none@vcs1.html

  * igt@gem_exec_fair@basic-none@vecs0:
    - shard-apl:          [FAIL][114] ([i915#2842]) -> [PASS][115]
   [114]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-apl7/igt@gem_exec_fair@basic-none@vecs0.html
   [115]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl4/igt@gem_exec_fair@basic-none@vecs0.html

  * igt@gem_exec_reloc@basic-wc:
    - {shard-rkl}:        [SKIP][116] ([i915#3281]) -> [PASS][117] +8 similar issues
   [116]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-6/igt@gem_exec_reloc@basic-wc.html
   [117]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-5/igt@gem_exec_reloc@basic-wc.html

  * igt@gem_tiled_partial_pwrite_pread@writes:
    - {shard-rkl}:        [SKIP][118] ([i915#3282]) -> [PASS][119] +1 similar issue
   [118]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-4/igt@gem_tiled_partial_pwrite_pread@writes.html
   [119]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-5/igt@gem_tiled_partial_pwrite_pread@writes.html

  * igt@gen9_exec_parse@allowed-all:
    - shard-glk:          [DMESG-WARN][120] ([i915#5566] / [i915#716]) -> [PASS][121]
   [120]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-glk1/igt@gen9_exec_parse@allowed-all.html
   [121]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-glk5/igt@gen9_exec_parse@allowed-all.html

  * igt@gen9_exec_parse@allowed-single:
    - shard-kbl:          [DMESG-WARN][122] ([i915#5566] / [i915#716]) -> [PASS][123]
   [122]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl4/igt@gen9_exec_parse@allowed-single.html
   [123]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl6/igt@gen9_exec_parse@allowed-single.html

  * igt@gen9_exec_parse@bb-start-param:
    - {shard-rkl}:        [SKIP][124] ([i915#2527]) -> [PASS][125] +1 similar issue
   [124]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-1/igt@gen9_exec_parse@bb-start-param.html
   [125]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-5/igt@gen9_exec_parse@bb-start-param.html

  * igt@i915_hangman@gt-engine-error@bcs0:
    - {shard-rkl}:        [SKIP][126] ([i915#6258]) -> [PASS][127]
   [126]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-5/igt@i915_hangman@gt-engine-error@bcs0.html
   [127]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-1/igt@i915_hangman@gt-engine-error@bcs0.html

  * igt@i915_pm_dc@dc6-psr:
    - shard-iclb:         [FAIL][128] ([i915#454]) -> [PASS][129]
   [128]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb3/igt@i915_pm_dc@dc6-psr.html
   [129]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@i915_pm_dc@dc6-psr.html

  * igt@i915_pm_dc@dc9-dpms:
    - {shard-rkl}:        [SKIP][130] ([i915#3361]) -> [PASS][131]
   [130]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-5/igt@i915_pm_dc@dc9-dpms.html
   [131]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-4/igt@i915_pm_dc@dc9-dpms.html
    - shard-apl:          [SKIP][132] ([fdo#109271]) -> [PASS][133]
   [132]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-apl1/igt@i915_pm_dc@dc9-dpms.html
   [133]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl1/igt@i915_pm_dc@dc9-dpms.html

  * igt@i915_pm_rc6_residency@rc6-idle@vcs0:
    - shard-kbl:          [WARN][134] ([i915#6405]) -> [PASS][135]
   [134]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl4/igt@i915_pm_rc6_residency@rc6-idle@vcs0.html
   [135]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl4/igt@i915_pm_rc6_residency@rc6-idle@vcs0.html

  * igt@i915_selftest@live@gt_pm:
    - {shard-tglu}:       [DMESG-FAIL][136] ([i915#3987]) -> [PASS][137]
   [136]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-tglu-4/igt@i915_selftest@live@gt_pm.html
   [137]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglu-8/igt@i915_selftest@live@gt_pm.html

  * igt@i915_selftest@live@hangcheck:
    - shard-snb:          [INCOMPLETE][138] ([i915#3921]) -> [PASS][139]
   [138]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-snb4/igt@i915_selftest@live@hangcheck.html
   [139]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-snb4/igt@i915_selftest@live@hangcheck.html

  * igt@kms_big_fb@y-tiled-32bpp-rotate-180:
    - {shard-rkl}:        [SKIP][140] ([i915#1845] / [i915#4098]) -> [PASS][141] +5 similar issues
   [140]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-5/igt@kms_big_fb@y-tiled-32bpp-rotate-180.html
   [141]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-6/igt@kms_big_fb@y-tiled-32bpp-rotate-180.html

  * igt@kms_draw_crc@draw-method-xrgb8888-mmap-cpu-untiled:
    - {shard-rkl}:        [SKIP][142] ([fdo#111314] / [i915#4098] / [i915#4369]) -> [PASS][143]
   [142]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-1/igt@kms_draw_crc@draw-method-xrgb8888-mmap-cpu-untiled.html
   [143]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-6/igt@kms_draw_crc@draw-method-xrgb8888-mmap-cpu-untiled.html

  * igt@kms_flip@2x-flip-vs-expired-vblank-interruptible@ab-hdmi-a1-hdmi-a2:
    - shard-glk:          [FAIL][144] ([i915#79]) -> [PASS][145]
   [144]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-glk7/igt@kms_flip@2x-flip-vs-expired-vblank-interruptible@ab-hdmi-a1-hdmi-a2.html
   [145]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-glk5/igt@kms_flip@2x-flip-vs-expired-vblank-interruptible@ab-hdmi-a1-hdmi-a2.html

  * igt@kms_flip@flip-vs-suspend-interruptible@a-hdmi-a1:
    - {shard-tglu}:       [DMESG-WARN][146] -> [PASS][147]
   [146]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-tglu-4/igt@kms_flip@flip-vs-suspend-interruptible@a-hdmi-a1.html
   [147]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-tglu-8/igt@kms_flip@flip-vs-suspend-interruptible@a-hdmi-a1.html

  * igt@kms_flip@flip-vs-suspend@a-dp1:
    - shard-apl:          [DMESG-WARN][148] ([i915#180]) -> [PASS][149] +2 similar issues
   [148]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-apl3/igt@kms_flip@flip-vs-suspend@a-dp1.html
   [149]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-apl1/igt@kms_flip@flip-vs-suspend@a-dp1.html

  * igt@kms_frontbuffer_tracking@fbc-suspend:
    - shard-kbl:          [DMESG-WARN][150] ([i915#180]) -> [PASS][151] +4 similar issues
   [150]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl4/igt@kms_frontbuffer_tracking@fbc-suspend.html
   [151]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl1/igt@kms_frontbuffer_tracking@fbc-suspend.html

  * igt@kms_frontbuffer_tracking@psr-1p-primscrn-spr-indfb-draw-blt:
    - {shard-rkl}:        [SKIP][152] ([i915#1849] / [i915#4098]) -> [PASS][153] +4 similar issues
   [152]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-2/igt@kms_frontbuffer_tracking@psr-1p-primscrn-spr-indfb-draw-blt.html
   [153]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-6/igt@kms_frontbuffer_tracking@psr-1p-primscrn-spr-indfb-draw-blt.html

  * igt@kms_hdr@bpc-switch-dpms@pipe-a-dp-1:
    - shard-kbl:          [FAIL][154] ([i915#1188]) -> [PASS][155] +1 similar issue
   [154]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl7/igt@kms_hdr@bpc-switch-dpms@pipe-a-dp-1.html
   [155]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl6/igt@kms_hdr@bpc-switch-dpms@pipe-a-dp-1.html

  * igt@kms_plane_alpha_blend@pipe-b-constant-alpha-min:
    - {shard-rkl}:        [SKIP][156] ([i915#1849] / [i915#4070] / [i915#4098]) -> [PASS][157]
   [156]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-1/igt@kms_plane_alpha_blend@pipe-b-constant-alpha-min.html
   [157]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-6/igt@kms_plane_alpha_blend@pipe-b-constant-alpha-min.html

  * igt@kms_plane_scaling@plane-downscale-with-pixel-format-factor-0-5@pipe-a-edp-1:
    - shard-iclb:         [SKIP][158] ([i915#5176]) -> [PASS][159] +2 similar issues
   [158]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb2/igt@kms_plane_scaling@plane-downscale-with-pixel-format-factor-0-5@pipe-a-edp-1.html
   [159]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb5/igt@kms_plane_scaling@plane-downscale-with-pixel-format-factor-0-5@pipe-a-edp-1.html

  * igt@kms_properties@crtc-properties-legacy:
    - {shard-rkl}:        [SKIP][160] ([i915#1849]) -> [PASS][161]
   [160]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-1/igt@kms_properties@crtc-properties-legacy.html
   [161]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-6/igt@kms_properties@crtc-properties-legacy.html

  * igt@kms_psr@primary_render:
    - {shard-rkl}:        [SKIP][162] ([i915#1072]) -> [PASS][163]
   [162]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-5/igt@kms_psr@primary_render.html
   [163]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-6/igt@kms_psr@primary_render.html

  * igt@kms_psr@psr2_sprite_blt:
    - shard-iclb:         [SKIP][164] ([fdo#109441]) -> [PASS][165] +1 similar issue
   [164]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb7/igt@kms_psr@psr2_sprite_blt.html
   [165]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_psr@psr2_sprite_blt.html

  * igt@kms_universal_plane@disable-primary-vs-flip-pipe-a:
    - {shard-rkl}:        [SKIP][166] ([i915#1845] / [i915#4070] / [i915#4098]) -> [PASS][167]
   [166]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-1/igt@kms_universal_plane@disable-primary-vs-flip-pipe-a.html
   [167]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-6/igt@kms_universal_plane@disable-primary-vs-flip-pipe-a.html

  * igt@prime_vgem@basic-read:
    - {shard-rkl}:        [SKIP][168] ([fdo#109295] / [i915#3291] / [i915#3708]) -> [PASS][169]
   [168]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-rkl-2/igt@prime_vgem@basic-read.html
   [169]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-rkl-5/igt@prime_vgem@basic-read.html

  
#### Warnings ####

  * igt@kms_fbcon_fbt@fbc-suspend:
    - shard-kbl:          [INCOMPLETE][170] ([i915#180] / [i915#4939]) -> [FAIL][171] ([i915#4767])
   [170]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl6/igt@kms_fbcon_fbt@fbc-suspend.html
   [171]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl6/igt@kms_fbcon_fbt@fbc-suspend.html

  * igt@kms_psr2_sf@cursor-plane-move-continuous-exceed-sf:
    - shard-iclb:         [SKIP][172] ([i915#2920]) -> [SKIP][173] ([i915#658]) +2 similar issues
   [172]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb2/igt@kms_psr2_sf@cursor-plane-move-continuous-exceed-sf.html
   [173]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb5/igt@kms_psr2_sf@cursor-plane-move-continuous-exceed-sf.html

  * igt@kms_psr2_sf@overlay-plane-move-continuous-exceed-sf:
    - shard-iclb:         [SKIP][174] ([i915#658]) -> [SKIP][175] ([i915#2920])
   [174]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb8/igt@kms_psr2_sf@overlay-plane-move-continuous-exceed-sf.html
   [175]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_psr2_sf@overlay-plane-move-continuous-exceed-sf.html

  * igt@kms_psr2_sf@overlay-plane-update-continuous-sf:
    - shard-iclb:         [SKIP][176] ([fdo#111068] / [i915#658]) -> [SKIP][177] ([i915#2920])
   [176]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb4/igt@kms_psr2_sf@overlay-plane-update-continuous-sf.html
   [177]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_psr2_sf@overlay-plane-update-continuous-sf.html

  * igt@kms_psr2_su@page_flip-nv12:
    - shard-iclb:         [SKIP][178] ([fdo#109642] / [fdo#111068] / [i915#658]) -> [FAIL][179] ([i915#5939])
   [178]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-iclb1/igt@kms_psr2_su@page_flip-nv12.html
   [179]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-iclb2/igt@kms_psr2_su@page_flip-nv12.html

  * igt@runner@aborted:
    - shard-kbl:          ([FAIL][180], [FAIL][181], [FAIL][182], [FAIL][183], [FAIL][184], [FAIL][185], [FAIL][186], [FAIL][187], [FAIL][188]) ([fdo#109271] / [i915#180] / [i915#3002] / [i915#4312] / [i915#5257] / [i915#716] / [i915#92]) -> ([FAIL][189], [FAIL][190], [FAIL][191]) ([i915#3002] / [i915#4312] / [i915#5257])
   [180]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl6/igt@runner@aborted.html
   [181]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl7/igt@runner@aborted.html
   [182]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl4/igt@runner@aborted.html
   [183]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl4/igt@runner@aborted.html
   [184]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl1/igt@runner@aborted.html
   [185]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl7/igt@runner@aborted.html
   [186]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl6/igt@runner@aborted.html
   [187]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl4/igt@runner@aborted.html
   [188]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_6581/shard-kbl6/igt@runner@aborted.html
   [189]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl6/igt@runner@aborted.html
   [190]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl6/igt@runner@aborted.html
   [191]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/shard-kbl7/igt@runner@aborted.html

  
  {name}: This element is suppressed. This means it is ignored when computing
          the status of the difference (SUCCESS, WARNING, or FAILURE).

  [fdo#103375]: https://bugs.freedesktop.org/show_bug.cgi?id=103375
  [fdo#108145]: https://bugs.freedesktop.org/show_bug.cgi?id=108145
  [fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
  [fdo#109274]: https://bugs.freedesktop.org/show_bug.cgi?id=109274
  [fdo#109278]: https://bugs.freedesktop.org/show_bug.cgi?id=109278
  [fdo#109280]: https://bugs.freedesktop.org/show_bug.cgi?id=109280
  [fdo#109283]: https://bugs.freedesktop.org/show_bug.cgi?id=109283
  [fdo#109284]: https://bugs.freedesktop.org/show_bug.cgi?id=109284
  [fdo#109285]: https://bugs.freedesktop.org/show_bug.cgi?id=109285
  [fdo#109289]: https://bugs.freedesktop.org/show_bug.cgi?id=109289
  [fdo#109291]: https://bugs.freedesktop.org/show_bug.cgi?id=109291
  [fdo#109295]: https://bugs.freedesktop.org/show_bug.cgi?id=109295
  [fdo#109308]: https://bugs.freedesktop.org/show_bug.cgi?id=109308
  [fdo#109314]: https://bugs.freedesktop.org/show_bug.cgi?id=109314
  [fdo#109441]: https://bugs.freedesktop.org/show_bug.cgi?id=109441
  [fdo#109506]: https://bugs.freedesktop.org/show_bug.cgi?id=109506
  [fdo#109642]: https://bugs.freedesktop.org/show_bug.cgi?id=109642
  [fdo#110189]: https://bugs.freedesktop.org/show_bug.cgi?id=110189
  [fdo#110723]: https://bugs.freedesktop.org/show_bug.cgi?id=110723
  [fdo#111068]: https://bugs.freedesktop.org/show_bug.cgi?id=111068
  [fdo#111314]: https://bugs.freedesktop.org/show_bug.cgi?id=111314
  [fdo#111614]: https://bugs.freedesktop.org/show_bug.cgi?id=111614
  [fdo#111615]: https://bugs.freedesktop.org/show_bug.cgi?id=111615
  [fdo#111656]: https://bugs.freedesktop.org/show_bug.cgi?id=111656
  [fdo#111825]: https://bugs.freedesktop.org/show_bug.cgi?id=111825
  [fdo#111827]: https://bugs.freedesktop.org/show_bug.cgi?id=111827
  [fdo#112054]: https://bugs.freedesktop.org/show_bug.cgi?id=112054
  [i915#1063]: https://gitlab.freedesktop.org/drm/intel/issues/1063
  [i915#1072]: https://gitlab.freedesktop.org/drm/intel/issues/1072
  [i915#1099]: https://gitlab.freedesktop.org/drm/intel/issues/1099
  [i915#1155]: https://gitlab.freedesktop.org/drm/intel/issues/1155
  [i915#1188]: https://gitlab.freedesktop.org/drm/intel/issues/1188
  [i915#132]: https://gitlab.freedesktop.org/drm/intel/issues/132
  [i915#1397]: https://gitlab.freedesktop.org/drm/intel/issues/1397
  [i915#1769]: https://gitlab.freedesktop.org/drm/intel/issues/1769
  [i915#180]: https://gitlab.freedesktop.org/drm/intel/issues/180
  [i915#1825]: https://gitlab.freedesktop.org/drm/intel/issues/1825
  [i915#1845]: https://gitlab.freedesktop.org/drm/intel/issues/1845
  [i915#1849]: https://gitlab.freedesktop.org/drm/intel/issues/1849
  [i915#1902]: https://gitlab.freedesktop.org/drm/intel/issues/1902
  [i915#2190]: https://gitlab.freedesktop.org/drm/intel/issues/2190
  [i915#2346]: https://gitlab.freedesktop.org/drm/intel/issues/2346
  [i915#2410]: https://gitlab.freedesktop.org/drm/intel/issues/2410
  [i915#2437]: https://gitlab.freedesktop.org/drm/intel/issues/2437
  [i915#2527]: https://gitlab.freedesktop.org/drm/intel/issues/2527
  [i915#2530]: https://gitlab.freedesktop.org/drm/intel/issues/2530
  [i915#2582]: https://gitlab.freedesktop.org/drm/intel/issues/2582
  [i915#265]: https://gitlab.freedesktop.org/drm/intel/issues/265
  [i915#2672]: https://gitlab.freedesktop.org/drm/intel/issues/2672
  [i915#2681]: https://gitlab.freedesktop.org/drm/intel/issues/2681
  [i915#2842]: https://gitlab.freedesktop.org/drm/intel/issues/2842
  [i915#2856]: https://gitlab.freedesktop.org/drm/intel/issues/2856
  [i915#2920]: https://gitlab.freedesktop.org/drm/intel/issues/2920
  [i915#2994]: https://gitlab.freedesktop.org/drm/intel/issues/2994
  [i915#3002]: https://gitlab.freedesktop.org/drm/intel/issues/3002
  [i915#3012]: https://gitlab.freedesktop.org/drm/intel/issues/3012
  [i915#3063]: https://gitlab.freedesktop.org/drm/intel/issues/3063
  [i915#3116]: https://gitlab.freedesktop.org/drm/intel/issues/3116
  [i915#3281]: https://gitlab.freedesktop.org/drm/intel/issues/3281
  [i915#3282]: https://gitlab.freedesktop.org/drm/intel/issues/3282
  [i915#3291]: https://gitlab.freedesktop.org/drm/intel/issues/3291
  [i915#3297]: https://gitlab.freedesktop.org/drm/intel/issues/3297
  [i915#3299]: https://gitlab.freedesktop.org/drm/intel/issues/3299
  [i915#3359]: https://gitlab.freedesktop.org/drm/intel/issues/3359
  [i915#3361]: https://gitlab.freedesktop.org/drm/intel/issues/3361
  [i915#3467]: https://gitlab.freedesktop.org/drm/intel/issues/3467
  [i915#3469]: https://gitlab.freedesktop.org/drm/intel/issues/3469
  [i915#3536]: https://gitlab.freedesktop.org/drm/intel/issues/3536
  [i915#3555]: https://gitlab.freedesktop.org/drm/intel/issues/3555
  [i915#3558]: https://gitlab.freedesktop.org/drm/intel/issues/3558
  [i915#3637]: https://gitlab.freedesktop.org/drm/intel/issues/3637
  [i915#3689]: https://gitlab.freedesktop.org/drm/intel/issues/3689
  [i915#3708]: https://gitlab.freedesktop.org/drm/intel/issues/3708
  [i915#3734]: https://gitlab.freedesktop.org/drm/intel/issues/3734
  [i915#3742]: https://gitlab.freedesktop.org/drm/intel/issues/3742
  [i915#3804]: https://gitlab.freedesktop.org/drm/intel/issues/3804
  [i915#3825]: https://gitlab.freedesktop.org/drm/intel/issues/3825
  [i915#3828]: https://gitlab.freedesktop.org/drm/intel/issues/3828
  [i915#3886]: https://gitlab.freedesktop.org/drm/intel/issues/3886
  [i915#3921]: https://gitlab.freedesktop.org/drm/intel/issues/3921
  [i915#3955]: https://gitlab.freedesktop.org/drm/intel/issues/3955
  [i915#3966]: https://gitlab.freedesktop.org/drm/intel/issues/3966
  [i915#3987]: https://gitlab.freedesktop.org/drm/intel/issues/3987
  [i915#4016]: https://gitlab.freedesktop.org/drm/intel/issues/4016
  [i915#404]: https://gitlab.freedesktop.org/drm/intel/issues/404
  [i915#4070]: https://gitlab.freedesktop.org/drm/intel/issues/4070
  [i915#4098]: https://gitlab.freedesktop.org/drm/intel/issues/4098
  [i915#4103]: https://gitlab.freedesktop.org/drm/intel/issues/4103
  [i915#4270]: https://gitlab.freedesktop.org/drm/intel/issues/4270
  [i915#4281]: https://gitlab.freedesktop.org/drm/intel/issues/4281
  [i915#4312]: https://gitlab.freedesktop.org/drm/intel/issues/4312
  [i915#4369]: https://gitlab.freedesktop.org/drm/intel/issues/4369
  [i915#4462]: https://gitlab.freedesktop.org/drm/intel/issues/4462
  [i915#4525]: https://gitlab.freedesktop.org/drm/intel/issues/4525
  [i915#454]: https://gitlab.freedesktop.org/drm/intel/issues/454
  [i915#4613]: https://gitlab.freedesktop.org/drm/intel/issues/4613
  [i915#4767]: https://gitlab.freedesktop.org/drm/intel/issues/4767
  [i915#4939]: https://gitlab.freedesktop.org/drm/intel/issues/4939
  [i915#4941]: https://gitlab.freedesktop.org/drm/intel/issues/4941
  [i915#4991]: https://gitlab.freedesktop.org/drm/intel/issues/4991
  [i915#5072]: https://gitlab.freedesktop.org/drm/intel/issues/5072
  [i915#5176]: https://gitlab.freedesktop.org/drm/intel/issues/5176
  [i915#5235]: https://gitlab.freedesktop.org/drm/intel/issues/5235
  [i915#5257]: https://gitlab.freedesktop.org/drm/intel/issues/5257
  [i915#5286]: https://gitlab.freedesktop.org/drm/intel/issues/5286
  [i915#5287]: https://gitlab.freedesktop.org/drm/intel/issues/5287
  [i915#5288]: https://gitlab.freedesktop.org/drm/intel/issues/5288
  [i915#5289]: https://gitlab.freedesktop.org/drm/intel/issues/5289
  [i915#5325]: https://gitlab.freedesktop.org/drm/intel/issues/5325
  [i915#5327]: https://gitlab.freedesktop.org/drm/intel/issues/5327
  [i915#533]: https://gitlab.freedesktop.org/drm/intel/issues/533
  [i915#5519]: https://gitlab.freedesktop.org/drm/intel/issues/5519
  [i915#5566]: https://gitlab.freedesktop.org/drm/intel/issues/5566
  [i915#5784]: https://gitlab.freedesktop.org/drm/intel/issues/5784
  [i915#5939]: https://gitlab.freedesktop.org/drm/intel/issues/5939
  [i915#6095]: https://gitlab.freedesktop.org/drm/intel/issues/6095
  [i915#6117]: https://gitlab.freedesktop.org/drm/intel/issues/6117
  [i915#6248]: https://gitlab.freedesktop.org/drm/intel/issues/6248
  [i915#6252]: https://gitlab.freedesktop.org/drm/intel/issues/6252
  [i915#6258]: https://gitlab.freedesktop.org/drm/intel/issues/6258
  [i915#6334]: https://gitlab.freedesktop.org/drm/intel/issues/6334
  [i915#6335]: https://gitlab.freedesktop.org/drm/intel/issues/6335
  [i915#6405]: https://gitlab.freedesktop.org/drm/intel/issues/6405
  [i915#6433]: https://gitlab.freedesktop.org/drm/intel/issues/6433
  [i915#658]: https://gitlab.freedesktop.org/drm/intel/issues/658
  [i915#716]: https://gitlab.freedesktop.org/drm/intel/issues/716
  [i915#79]: https://gitlab.freedesktop.org/drm/intel/issues/79
  [i915#92]: https://gitlab.freedesktop.org/drm/intel/issues/92


Build changes
-------------

  * CI: CI-20190529 -> None
  * IGT: IGT_6581 -> IGTPW_7515

  CI-20190529: 20190529
  CI_DRM_11877: e55cefc370de5a38ee848aa96082d9d9f4cacdb9 @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_7515: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/index.html
  IGT_6581: 3c3a4cc75cfa7f6f34f2803ba68b0e8c5d1956e5 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_7515/index.html

[-- Attachment #2: Type: text/html, Size: 57020 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [igt-dev] [PATCH i-g-t v3 6/6] lib/igt_device_scan: Simulate udev drm and pci device events
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 6/6] lib/igt_device_scan: Simulate udev drm and pci device events Zbigniew Kempczyński
@ 2022-07-15 16:52   ` Kamil Konieczny
  2022-07-18  6:46     ` Zbigniew Kempczyński
  0 siblings, 1 reply; 12+ messages in thread
From: Kamil Konieczny @ 2022-07-15 16:52 UTC (permalink / raw)
  To: igt-dev

Hi Zbigniew,

On 2022-07-14 at 06:17:33 +0200, Zbigniew Kempczyński wrote:
> For all udev_*() calls used in device scan add its static counterparts.
> Instead of transplanting real udev data structures (private ones) some
> primitive replacement were added. Devices are added directly from code
> - such implementation was a little bit faster than parsing some config
> files (especially pci slot manipulation to provide some properties which
> slightly differs).
> 
> Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
> ---
>  lib/igt_device_scan.c          |   7 +
>  lib/igt_device_scan_simulate.c | 450 +++++++++++++++++++++++++++++++++
>  2 files changed, 457 insertions(+)
>  create mode 100644 lib/igt_device_scan_simulate.c
> 
> diff --git a/lib/igt_device_scan.c b/lib/igt_device_scan.c
> index aad7966764..f4e7659e42 100644
> --- a/lib/igt_device_scan.c
> +++ b/lib/igt_device_scan.c
> @@ -904,6 +904,13 @@ static void index_pci_devices(void)
>   * Function sorts all found devices to keep same order of bus devices
>   * for providing predictable search.
>   */
> +
> +#ifdef SIMULATE_UDEV_DEVICES
--------- ^
> +
> +#include "igt_device_scan_simulate.c"
---------------------------- ^

I am not convinced about name "simulate", because there is
already use of this for HW simulation. May we use "test" here ?
Or some other name ?

> +
> +#endif
> +
>  static void scan_drm_devices(void)
>  {
>  	struct udev *udev;
> diff --git a/lib/igt_device_scan_simulate.c b/lib/igt_device_scan_simulate.c
> new file mode 100644
> index 0000000000..5108f55924
> --- /dev/null
> +++ b/lib/igt_device_scan_simulate.c
> @@ -0,0 +1,450 @@
> +/*
> + * Example: Skylake
> +1656514333.437262: --------------------
> +1656514333.437263: SYSPATH: /sys/devices/pci0000:00/0000:00:02.0/drm/card0
> +1656514333.437294: SUBSYSTEM: drm
> +1656514333.437377: prop: CURRENT_TAGS, val: :seat:mutter-device-disable-kms-modifiers:master-of-seat:uaccess:
> +1656514333.437378: prop: DEVLINKS, val: /dev/dri/by-path/pci-0000:00:02.0-card
> +1656514333.437378: prop: DEVNAME, val: /dev/dri/card0
> +1656514333.437379: prop: DEVPATH, val: /devices/pci0000:00/0000:00:02.0/drm/card0
> +1656514333.437379: prop: DEVTYPE, val: drm_minor
> +1656514333.437380: prop: ID_FOR_SEAT, val: drm-pci-0000_00_02_0
> +1656514333.437380: prop: ID_PATH, val: pci-0000:00:02.0
> +1656514333.437382: prop: ID_PATH_TAG, val: pci-0000_00_02_0
> +1656514333.437383: prop: MAJOR, val: 226
> +1656514333.437383: prop: MINOR, val: 0
> +1656514333.437383: prop: SUBSYSTEM, val: drm
> +1656514333.437384: prop: TAGS, val: :seat:mutter-device-disable-kms-modifiers:master-of-seat:uaccess:
> +1656514333.437384: prop: USEC_INITIALIZED, val: 31377470
> +1656514333.438273: attr: dev, val: 226:0
> +1656406120.387751: attr: subsystem, val: drm
> +
> +1656514333.440217: --------------------
> +1656514333.440217: parent: 0000:00:02.0
> +1656514333.440223: subsystem: pci
> +1656514333.440224: syspath: /sys/devices/pci0000:00/0000:00:02.0
> +1656514333.440297: prop: DEVPATH, val: /devices/pci0000:00/0000:00:02.0
> +1656514333.440298: prop: DRIVER, val: i915
> +1656514333.440298: prop: ID_MODEL_FROM_DATABASE, val: Iris Graphics 540
> +1656514333.440299: prop: ID_PCI_CLASS_FROM_DATABASE, val: Display controller
> +1656514333.440299: prop: ID_PCI_INTERFACE_FROM_DATABASE, val: VGA controller
> +1656514333.440300: prop: ID_PCI_SUBCLASS_FROM_DATABASE, val: VGA compatible controller
> +1656514333.440300: prop: ID_VENDOR_FROM_DATABASE, val: Intel Corporation
> +1656514333.440301: prop: MODALIAS, val: pci:v00008086d00001926sv00008086sd00002063bc03sc00i00
> +1656514333.440302: prop: PCI_CLASS, val: 30000
> +1656514333.440302: prop: PCI_ID, val: 8086:1926
> +1656514333.440303: prop: PCI_SLOT_NAME, val: 0000:00:02.0
> +1656514333.440303: prop: PCI_SUBSYS_ID, val: 8086:2063
> +1656514333.440304: prop: SUBSYSTEM, val: pci
> +1656514333.440304: prop: SWITCHEROO_CONTROL_PRODUCT_NAME, val: Iris(R) Graphics 540
> +1656514333.440305: prop: SWITCHEROO_CONTROL_VENDOR_NAME, val: Intel(R)
> +1656514333.440306: prop: USEC_INITIALIZED, val: 6111540
> +1656514333.440692: attr: class, val: 0x030000
> +1656514333.440750: attr: device, val: 0x1926
> +1656514333.441116: attr: subsystem, val: pci
> +1656514333.441130: attr: subsystem_device, val: 0x2063
> +1656514333.441141: attr: subsystem_vendor, val: 0x8086
> +1656514333.441162: attr: vendor, val: 0x8086
> +
> +1656514333.441271: --------------------
> +1656514333.441272: SYSPATH: /sys/devices/pci0000:00/0000:00:02.0/drm/renderD128
> +1656514333.441305: SUBSYSTEM: drm
> +1656514333.441390: prop: CURRENT_TAGS, val: :seat:mutter-device-disable-kms-modifiers:uaccess:
> +1656514333.441391: prop: DEVLINKS, val: /dev/dri/by-path/pci-0000:00:02.0-render
> +1656514333.441391: prop: DEVNAME, val: /dev/dri/renderD128
> +1656514333.441392: prop: DEVPATH, val: /devices/pci0000:00/0000:00:02.0/drm/renderD128
> +1656514333.441392: prop: DEVTYPE, val: drm_minor
> +1656514333.441393: prop: ID_FOR_SEAT, val: drm-pci-0000_00_02_0
> +1656514333.441393: prop: ID_PATH, val: pci-0000:00:02.0
> +1656514333.441395: prop: ID_PATH_TAG, val: pci-0000_00_02_0
> +1656514333.441395: prop: MAJOR, val: 226
> +1656514333.441396: prop: MINOR, val: 128
> +1656514333.441396: prop: SUBSYSTEM, val: drm
> +1656514333.441396: prop: TAGS, val: :seat:mutter-device-disable-kms-modifiers:uaccess:
> +1656514333.441397: prop: USEC_INITIALIZED, val: 31377515
> +1656514333.441525: attr: dev, val: 226:128
> +1656514333.441657: attr: subsystem, val: drm
> +*/
> +
> +enum entry_type {
> +	TYPE_DEVICE,
> +	TYPE_PROP,
> +	TYPE_ATTR,
> +};
> +
> +struct udev_list_entry {
> +	enum entry_type entry_type;
> +	int curr;
> +} _entry_dev, _entry_prop, _entry_attr;
> +
> +struct keyval {
> +	char key[NAME_MAX];
> +	char val[NAME_MAX];
> +};
> +
> +#define MAXDEVS 16
> +#define MAXPROPS 16
> +#define MAXATTRS 8
> +struct udev_device {
> +	struct udev_device *parent;
> +	char syspath[NAME_MAX];
> +	char devnode[NAME_MAX];
> +	char subsystem[8];
> +	struct keyval prop[MAXPROPS];
> +	struct udev_list_entry *prop_head;
> +	struct keyval attr[MAXATTRS];
> +	struct udev_list_entry *attr_head;
> +	int props;
> +	int attrs;
> +};
> +
> +struct udev {
> +	struct udev_device *dev[MAXDEVS];
> +} _udev;
> +
> +struct udev_enumerate {
> +	struct udev *udev;
> +} _udev_enumerate;
> +
> +static void print_udev_device(const struct udev_device *dev)
> +{
> +//#define DEBUG_SCAN_SIMULATE
> +#ifdef DEBUG_SCAN_SIMULATE

Isn't this a little too redundand ? You already have this code
included only when user defines name in other file, so maybe
here just use igt_debug() and drop this ifdef/endif ?

> +	int i;
> +
> +	printf("[%s]\n", dev->syspath);
> +
> +	printf("props:\n");
> +	for (i = 0; i < dev->props; i++)
> +		printf("   %s: %s\n", dev->prop[i].key, dev->prop[i].val);
> +
> +	printf("attrs:\n");
> +	for (i = 0; i < dev->attrs; i++)
> +		printf("   %s: %s\n", dev->attr[i].key, dev->attr[i].val);
> +#endif
> +}
> +
> +#define __ADD_PROP(_dev, _key, args...) do { \
--------------------- ^
You use some global vars with underscore, so maybe here use
longer names without '_' ? For example prop_dev, prop_key or
add_dev, add_key ? Or use double underscore '__' ?

> +	struct keyval *kv; \
> +	igt_assert(dev->props <= MAXPROPS); \
------------------ ^
Here and below in second macro you should use _dev.

> +	kv = &(dev)->prop[(dev)->props]; \

Same here.

> +	strncpy(kv->key, (_key), NAME_MAX); \
> +	snprintf(kv->val, NAME_MAX, args); \
> +	(dev)->props++; \

Same here.

> +	} while (0)
> +
> +#define __ADD_ATTR(_dev, _key, args...) do { \

Same note about names used in macro.

> +	struct keyval *kv; \
> +	igt_assert(dev->attrs <= MAXATTRS); \

Same here.

> +	kv = &(dev)->attr[(dev)->attrs]; \

Same here.

> +	strncpy(kv->key, (_key), NAME_MAX); \
> +	snprintf(kv->val, NAME_MAX, args); \
> +	(dev)->attrs++; \

Same here.

> +	} while (0)
> +
> +static struct udev_device *
> +create_pci_udev_device(struct udev *udev,
> +		       const char *syspath, const char *bdf,
> +		       uint16_t vendor, uint16_t device, uint16_t subsystem)
> +{
> +	struct udev_device *dev;
> +	char bus[13];
> +
> +	igt_assert(strlen(bdf) == 12);
> +
> +	dev = calloc(1, sizeof(*dev));
> +	igt_assert(dev);
> +
> +	dev->parent = dev;
> +	snprintf(dev->syspath, NAME_MAX, "%s", syspath);
> +	strncpy(dev->subsystem, "pci", 4);
> +
> +	/* avoid compiler warning when copying less than 12 */
> +	strncpy(bus, bdf, 13);
> +	bus[7] = '\0';
> +
> +	__ADD_PROP(dev, "DEVPATH", "/devices/pci%s/%s", bus, bdf);
> +	__ADD_PROP(dev, "DRIVER", "i915");
> +	__ADD_PROP(dev, "PCI_CLASS", "30000");
> +	__ADD_PROP(dev, "PCI_ID", "%04x:%04x", vendor, device);
> +	__ADD_PROP(dev, "PCI_SLOT_NAME", "%s", bdf);
> +	__ADD_PROP(dev, "PCI_SUBSYS_ID", "%04x:%04x", vendor, subsystem);
> +	__ADD_PROP(dev, "SUBSYSTEM", "pci");
> +
> +	__ADD_ATTR(dev, "class", "0x030000");
> +	__ADD_ATTR(dev, "device", "0x%04x", device);
> +	__ADD_ATTR(dev, "subsystem", "pci");
> +	__ADD_ATTR(dev, "subsystem_device", "0x%04x", subsystem);
> +	__ADD_ATTR(dev, "subsystem_vendor", "0x%04x", vendor);
> +	__ADD_ATTR(dev, "vendor", "0x%04x", vendor);
> +
> +	return dev;
> +}
> +
> +static struct udev_device *
> +create_drm_udev_device(struct udev *udev, struct udev_device *parent,
> +		       const char *syspath, const char *bdf, int card,
> +		       int major, int minor)
> +{
> +	struct udev_device *dev;
> +	const char *name = card < 128 ? "card" : "render";
> +	const char *drmname = card < 128 ? "card" : "renderD";
> +	char bus[13];
> +
> +	igt_assert(strlen(bdf) == 12);
> +
> +	dev = calloc(1, sizeof(*dev));
> +	igt_assert(dev);
> +
> +	dev->parent = parent;
> +	snprintf(dev->syspath, NAME_MAX, "%s", syspath);
> +	strncpy(dev->subsystem, "drm", 4);
> +	snprintf(dev->devnode, NAME_MAX, "/dev/dri/%s%d", drmname, card);
> +
> +	/* avoid compiler warning when copying less than 12 */
> +	strncpy(bus, bdf, 13);
> +	bus[7] = '\0';
> +
> +	__ADD_PROP(dev, "DEVLINKS", "/dev/dri/by-path/pci-%s-%s", bdf, name);
> +	__ADD_PROP(dev, "DEVNAME", "/dev/dri/%s%d", drmname, card);
> +	__ADD_PROP(dev, "DEVPATH", "/devices/pci%s/%s/drm/%s%d", bus, bdf,
> +		   drmname, card);
> +	__ADD_PROP(dev, "DEVTYPE", "drm_minor");
> +	__ADD_PROP(dev, "ID_PATH", "pci-%s", bdf);
> +	__ADD_PROP(dev, "MAJOR", "%d", major);
> +	__ADD_PROP(dev, "MINOR", "%d", minor);
> +	__ADD_PROP(dev, "SUBSYSTEM", "drm");
> +
> +	__ADD_ATTR(dev, "dev", "%d:%d", major, minor);
> +	__ADD_ATTR(dev, "subsystem", "drm");
> +
> +	return dev;
> +}
> +
> +static struct udev_device **add_intel_dev(struct udev *udev, struct udev_device **dev,
> +					  const char *pci_slot, uint16_t pci_device)
> +{
> +	struct udev_device **parent;
> +	char bd[13], path[NAME_MAX];
> +	static int card;
> +
> +	strncpy(bd, pci_slot, 13);
> +	bd[7] = 0;
> +
> +	parent = dev;
> +
> +	snprintf(path, NAME_MAX, "/sys/devices/pci%s/%s", bd, pci_slot);
> +	*dev++ = create_pci_udev_device(udev, path, pci_slot,
> +					0x8086, pci_device, 0x2063);
> +
> +	snprintf(path, NAME_MAX, "/sys/devices/pci%s/%s/drm/card%d",
> +		 bd, pci_slot, card);
> +	*dev++ = create_drm_udev_device(udev, *parent, path, pci_slot,
> +					card, 226, card);
> +
> +	snprintf(path, NAME_MAX, "/sys/devices/pci%s/%s/drm/renderD%d",
> +		 bd, pci_slot, card + 128);
> +	*dev++ = create_drm_udev_device(udev, *parent, path, pci_slot,
> +					card + 128, 226, card + 128);
> +
> +	card++;
> +
> +	return dev;
> +}
> +
> +struct udev *udev_new(void)
> +{
> +	struct udev *udev = &_udev;
> +	struct udev_device **dev = udev->dev;
> +
> +	memset(dev, 0, sizeof(_udev.dev));
> +
> +	dev = add_intel_dev(udev, dev, "0000:00:02.0", 0x1926); /* skl */
> +	dev = add_intel_dev(udev, dev, "0000:01:00.0", 0x56a1); /* dg2 */
> +	dev = add_intel_dev(udev, dev, "0000:02:02.1", 0x9a40); /* tgl */
> +	dev = add_intel_dev(udev, dev, "0000:03:01.0", 0x56a0); /* dg2 */
> +	dev = add_intel_dev(udev, dev, "0000:04:02.0", 0x56a2); /* dg2 */
> +
> +	dev = udev->dev;
> +	while (*dev)
> +		print_udev_device(*dev++);
> +
> +	return &_udev;
> +}
> +
> +struct udev_enumerate *udev_enumerate_new(struct udev *udev)
> +{
> +	_udev_enumerate.udev = udev;
> +
> +	return &_udev_enumerate;
> +}
> +
> +int udev_enumerate_add_match_subsystem(struct udev_enumerate *udev_enumerate,
> +				       const char *subsystem)
> +{
> +	return 0;
> +}
> +
> +int udev_enumerate_add_match_property(struct udev_enumerate *udev_enumerate,
> +				      const char *property, const char *value)
> +{
> +	return 0;
> +}
> +
> +int udev_enumerate_scan_devices(struct udev_enumerate *udev_enumerate)
> +{
> +	return 0;
> +}
> +
> +struct udev_list_entry *
> +udev_enumerate_get_list_entry(struct udev_enumerate *udev_enumerate)
> +{
> +

Remove empty line.

Regards,
Kamil

> +	_entry_dev.entry_type = TYPE_DEVICE;
> +	_entry_dev.curr = 0;
> +
> +	return &_entry_dev;
> +}
> +
> +struct udev_list_entry *
> +udev_list_entry_get_next(struct udev_list_entry *list_entry)
> +{
> +	int curr, currdev = _entry_dev.curr;
> +
> +	switch (list_entry->entry_type) {
> +	case TYPE_DEVICE:
> +		if (_udev.dev[++list_entry->curr])
> +			return list_entry;
> +		break;
> +	case TYPE_PROP:
> +		curr = ++list_entry->curr;
> +		if (curr < _udev.dev[currdev]->props)
> +			return list_entry;
> +		break;
> +	case TYPE_ATTR:
> +		curr = ++list_entry->curr;
> +		if (curr < _udev.dev[currdev]->attrs)
> +			return list_entry;
> +		break;
> +	}
> +
> +	return NULL;
> +}
> +
> +const char *udev_list_entry_get_name(struct udev_list_entry *list_entry)
> +{
> +	int curr, currdev = _entry_dev.curr;
> +
> +	switch (list_entry->entry_type) {
> +	case TYPE_DEVICE:
> +		return _udev.dev[list_entry->curr]->syspath;
> +	case TYPE_PROP:
> +		curr = _entry_prop.curr;
> +		return _udev.dev[currdev]->prop[curr].key;
> +	case TYPE_ATTR:
> +		curr = _entry_attr.curr;
> +		return _udev.dev[currdev]->attr[curr].key;
> +	}
> +
> +	return "UNKNOWN";
> +}
> +
> +const char *udev_list_entry_get_value(struct udev_list_entry *list_entry)
> +{
> +	int curr, currdev = _entry_dev.curr;
> +
> +	switch (list_entry->entry_type) {
> +	case TYPE_DEVICE:
> +		return "";
> +	case TYPE_PROP:
> +		curr = _entry_prop.curr;
> +		return _udev.dev[currdev]->prop[curr].val;
> +	case TYPE_ATTR:
> +		curr = _entry_attr.curr;
> +		return _udev.dev[currdev]->attr[curr].val;
> +	}
> +
> +	return "UNKNOWN";
> +}
> +
> +struct udev_device *udev_device_new_from_syspath(struct udev *udev,
> +						 const char *syspath)
> +{
> +	int i;
> +
> +	for (i = 0; i < sizeof(udev->dev); i++) {
> +		if (!udev->dev[i])
> +			return NULL;
> +
> +		if (strcmp(udev->dev[i]->syspath, syspath) == 0)
> +			return udev->dev[i];
> +	}
> +
> +	return NULL;
> +}
> +
> +const char *udev_device_get_subsystem(struct udev_device *udev_device)
> +{
> +	return udev_device->subsystem;
> +}
> +
> +const char *udev_device_get_syspath(struct udev_device *udev_device)
> +{
> +	return udev_device->syspath;
> +}
> +
> +const char *udev_device_get_devnode(struct udev_device *udev_device)
> +{
> +	if (udev_device->devnode[0] == '\0')
> +		return NULL;
> +
> +	return udev_device->devnode;
> +}
> +
> +struct udev_list_entry *
> +udev_device_get_properties_list_entry(struct udev_device *udev_device)
> +{
> +	_entry_prop.entry_type = TYPE_PROP;
> +	_entry_prop.curr = 0;
> +
> +	return &_entry_prop;
> +}
> +
> +struct udev_list_entry *
> +udev_device_get_sysattr_list_entry(struct udev_device *udev_device)
> +{
> +	_entry_attr.entry_type = TYPE_ATTR;
> +	_entry_attr.curr = 0;
> +
> +	return &_entry_attr;
> +}
> +
> +const char *
> +udev_device_get_sysattr_value(struct udev_device *udev_device, const char *sysattr)
> +{
> +	for (int i = 0; i < udev_device->attrs; i++)
> +		if (strcmp(udev_device->attr[i].key, sysattr) == 0)
> +			return udev_device->attr[i].val;
> +
> +	return "UNKNOWN";
> +}
> +
> +const char *udev_device_get_sysname(struct udev_device *udev_device)
> +{
> +	return udev_device->syspath;
> +}
> +
> +struct udev_device *udev_device_get_parent(struct udev_device *udev_device)
> +{
> +	return udev_device->parent;
> +}
> +
> +struct udev_enumerate *udev_enumerate_unref(struct udev_enumerate *udev_enumerate)
> +{
> +	return NULL;
> +}
> +
> +struct udev_device *udev_device_unref(struct udev_device *udev_device)
> +{
> +	return NULL;
> +}
> -- 
> 2.34.1
> 

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [igt-dev] [PATCH i-g-t v3 1/6] lib/igt_device_scan: Migrate pci assignment
  2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 1/6] lib/igt_device_scan: Migrate pci assignment Zbigniew Kempczyński
@ 2022-07-15 16:54   ` Kamil Konieczny
  0 siblings, 0 replies; 12+ messages in thread
From: Kamil Konieczny @ 2022-07-15 16:54 UTC (permalink / raw)
  To: igt-dev

Hi Zbigniew,

On 2022-07-14 at 06:17:28 +0200, Zbigniew Kempczyński wrote:
> Core function of scanning drm devices is scan_drm_devices(). It goes
> over all drm subsystem devices acquiring pci (parent) device from udev
> during dedicated call for drm device.
> 
> Extending device selection to multi-gpu setup requires access to such
> machine or simulate udev calls (really replace current udev calls to
> say linker to use static versions of overridden udev functions).
> 
> Change migrates some core pci assignment to place where new igt_device is
> registered. It doesn't change code logic, only place where initialization
> is done making my simulation code happy.

Reviewed-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>

> 
> Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
> ---
>  lib/igt_device_scan.c | 11 ++++++-----
>  1 file changed, 6 insertions(+), 5 deletions(-)
> 
> diff --git a/lib/igt_device_scan.c b/lib/igt_device_scan.c
> index 5d98381f06..83a488aa7c 100644
> --- a/lib/igt_device_scan.c
> +++ b/lib/igt_device_scan.c
> @@ -513,6 +513,11 @@ static struct igt_device *igt_device_new_from_udev(struct udev_device *dev)
>  	get_props(dev, idev);
>  	get_attrs(dev, idev);
>  
> +	if (is_pci_subsystem(idev)) {
> +		set_vendor_device(idev);
> +		set_pci_slot_name(idev);
> +	}
> +
>  	return idev;
>  }
>  
> @@ -671,10 +676,6 @@ static void update_or_add_parent(struct udev_device *dev,
>  	parent_idev = igt_device_find(subsystem, syspath);
>  	if (!parent_idev) {
>  		parent_idev = igt_device_new_from_udev(parent_dev);
> -		if (is_pci_subsystem(parent_idev)) {
> -			set_vendor_device(parent_idev);
> -			set_pci_slot_name(parent_idev);
> -		}
>  		igt_list_add_tail(&parent_idev->link, &igt_devs.all);
>  	}
>  	devname = udev_device_get_devnode(dev);
> @@ -804,8 +805,8 @@ static void scan_drm_devices(void)
>  		path = udev_list_entry_get_name(dev_list_entry);
>  		udev_dev = udev_device_new_from_syspath(udev, path);
>  		idev = igt_device_new_from_udev(udev_dev);
> -		update_or_add_parent(udev_dev, idev);
>  		igt_list_add_tail(&idev->link, &igt_devs.all);
> +		update_or_add_parent(udev_dev, idev);
>  
>  		udev_device_unref(udev_dev);
>  	}
> -- 
> 2.34.1
> 

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [igt-dev] [PATCH i-g-t v3 6/6] lib/igt_device_scan: Simulate udev drm and pci device events
  2022-07-15 16:52   ` Kamil Konieczny
@ 2022-07-18  6:46     ` Zbigniew Kempczyński
  0 siblings, 0 replies; 12+ messages in thread
From: Zbigniew Kempczyński @ 2022-07-18  6:46 UTC (permalink / raw)
  To: Kamil Konieczny, igt-dev

On Fri, Jul 15, 2022 at 06:52:33PM +0200, Kamil Konieczny wrote:
> Hi Zbigniew,
> 
> On 2022-07-14 at 06:17:33 +0200, Zbigniew Kempczyński wrote:
> > For all udev_*() calls used in device scan add its static counterparts.
> > Instead of transplanting real udev data structures (private ones) some
> > primitive replacement were added. Devices are added directly from code
> > - such implementation was a little bit faster than parsing some config
> > files (especially pci slot manipulation to provide some properties which
> > slightly differs).
> > 
> > Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
> > ---
> >  lib/igt_device_scan.c          |   7 +
> >  lib/igt_device_scan_simulate.c | 450 +++++++++++++++++++++++++++++++++
> >  2 files changed, 457 insertions(+)
> >  create mode 100644 lib/igt_device_scan_simulate.c
> > 
> > diff --git a/lib/igt_device_scan.c b/lib/igt_device_scan.c
> > index aad7966764..f4e7659e42 100644
> > --- a/lib/igt_device_scan.c
> > +++ b/lib/igt_device_scan.c
> > @@ -904,6 +904,13 @@ static void index_pci_devices(void)
> >   * Function sorts all found devices to keep same order of bus devices
> >   * for providing predictable search.
> >   */
> > +
> > +#ifdef SIMULATE_UDEV_DEVICES
> --------- ^
> > +
> > +#include "igt_device_scan_simulate.c"
> ---------------------------- ^
> 
> I am not convinced about name "simulate", because there is
> already use of this for HW simulation. May we use "test" here ?
> Or some other name ?

But this is true. I replace udev events to simulated ones. I wondered
to provide separate function which feeds igt_device list but this way
I wouldn't test production code.

> 
> > +
> > +#endif
> > +
> >  static void scan_drm_devices(void)
> >  {
> >  	struct udev *udev;
> > diff --git a/lib/igt_device_scan_simulate.c b/lib/igt_device_scan_simulate.c
> > new file mode 100644
> > index 0000000000..5108f55924
> > --- /dev/null
> > +++ b/lib/igt_device_scan_simulate.c
> > @@ -0,0 +1,450 @@
> > +/*
> > + * Example: Skylake
> > +1656514333.437262: --------------------
> > +1656514333.437263: SYSPATH: /sys/devices/pci0000:00/0000:00:02.0/drm/card0
> > +1656514333.437294: SUBSYSTEM: drm
> > +1656514333.437377: prop: CURRENT_TAGS, val: :seat:mutter-device-disable-kms-modifiers:master-of-seat:uaccess:
> > +1656514333.437378: prop: DEVLINKS, val: /dev/dri/by-path/pci-0000:00:02.0-card
> > +1656514333.437378: prop: DEVNAME, val: /dev/dri/card0
> > +1656514333.437379: prop: DEVPATH, val: /devices/pci0000:00/0000:00:02.0/drm/card0
> > +1656514333.437379: prop: DEVTYPE, val: drm_minor
> > +1656514333.437380: prop: ID_FOR_SEAT, val: drm-pci-0000_00_02_0
> > +1656514333.437380: prop: ID_PATH, val: pci-0000:00:02.0
> > +1656514333.437382: prop: ID_PATH_TAG, val: pci-0000_00_02_0
> > +1656514333.437383: prop: MAJOR, val: 226
> > +1656514333.437383: prop: MINOR, val: 0
> > +1656514333.437383: prop: SUBSYSTEM, val: drm
> > +1656514333.437384: prop: TAGS, val: :seat:mutter-device-disable-kms-modifiers:master-of-seat:uaccess:
> > +1656514333.437384: prop: USEC_INITIALIZED, val: 31377470
> > +1656514333.438273: attr: dev, val: 226:0
> > +1656406120.387751: attr: subsystem, val: drm
> > +
> > +1656514333.440217: --------------------
> > +1656514333.440217: parent: 0000:00:02.0
> > +1656514333.440223: subsystem: pci
> > +1656514333.440224: syspath: /sys/devices/pci0000:00/0000:00:02.0
> > +1656514333.440297: prop: DEVPATH, val: /devices/pci0000:00/0000:00:02.0
> > +1656514333.440298: prop: DRIVER, val: i915
> > +1656514333.440298: prop: ID_MODEL_FROM_DATABASE, val: Iris Graphics 540
> > +1656514333.440299: prop: ID_PCI_CLASS_FROM_DATABASE, val: Display controller
> > +1656514333.440299: prop: ID_PCI_INTERFACE_FROM_DATABASE, val: VGA controller
> > +1656514333.440300: prop: ID_PCI_SUBCLASS_FROM_DATABASE, val: VGA compatible controller
> > +1656514333.440300: prop: ID_VENDOR_FROM_DATABASE, val: Intel Corporation
> > +1656514333.440301: prop: MODALIAS, val: pci:v00008086d00001926sv00008086sd00002063bc03sc00i00
> > +1656514333.440302: prop: PCI_CLASS, val: 30000
> > +1656514333.440302: prop: PCI_ID, val: 8086:1926
> > +1656514333.440303: prop: PCI_SLOT_NAME, val: 0000:00:02.0
> > +1656514333.440303: prop: PCI_SUBSYS_ID, val: 8086:2063
> > +1656514333.440304: prop: SUBSYSTEM, val: pci
> > +1656514333.440304: prop: SWITCHEROO_CONTROL_PRODUCT_NAME, val: Iris(R) Graphics 540
> > +1656514333.440305: prop: SWITCHEROO_CONTROL_VENDOR_NAME, val: Intel(R)
> > +1656514333.440306: prop: USEC_INITIALIZED, val: 6111540
> > +1656514333.440692: attr: class, val: 0x030000
> > +1656514333.440750: attr: device, val: 0x1926
> > +1656514333.441116: attr: subsystem, val: pci
> > +1656514333.441130: attr: subsystem_device, val: 0x2063
> > +1656514333.441141: attr: subsystem_vendor, val: 0x8086
> > +1656514333.441162: attr: vendor, val: 0x8086
> > +
> > +1656514333.441271: --------------------
> > +1656514333.441272: SYSPATH: /sys/devices/pci0000:00/0000:00:02.0/drm/renderD128
> > +1656514333.441305: SUBSYSTEM: drm
> > +1656514333.441390: prop: CURRENT_TAGS, val: :seat:mutter-device-disable-kms-modifiers:uaccess:
> > +1656514333.441391: prop: DEVLINKS, val: /dev/dri/by-path/pci-0000:00:02.0-render
> > +1656514333.441391: prop: DEVNAME, val: /dev/dri/renderD128
> > +1656514333.441392: prop: DEVPATH, val: /devices/pci0000:00/0000:00:02.0/drm/renderD128
> > +1656514333.441392: prop: DEVTYPE, val: drm_minor
> > +1656514333.441393: prop: ID_FOR_SEAT, val: drm-pci-0000_00_02_0
> > +1656514333.441393: prop: ID_PATH, val: pci-0000:00:02.0
> > +1656514333.441395: prop: ID_PATH_TAG, val: pci-0000_00_02_0
> > +1656514333.441395: prop: MAJOR, val: 226
> > +1656514333.441396: prop: MINOR, val: 128
> > +1656514333.441396: prop: SUBSYSTEM, val: drm
> > +1656514333.441396: prop: TAGS, val: :seat:mutter-device-disable-kms-modifiers:uaccess:
> > +1656514333.441397: prop: USEC_INITIALIZED, val: 31377515
> > +1656514333.441525: attr: dev, val: 226:128
> > +1656514333.441657: attr: subsystem, val: drm
> > +*/
> > +
> > +enum entry_type {
> > +	TYPE_DEVICE,
> > +	TYPE_PROP,
> > +	TYPE_ATTR,
> > +};
> > +
> > +struct udev_list_entry {
> > +	enum entry_type entry_type;
> > +	int curr;
> > +} _entry_dev, _entry_prop, _entry_attr;
> > +
> > +struct keyval {
> > +	char key[NAME_MAX];
> > +	char val[NAME_MAX];
> > +};
> > +
> > +#define MAXDEVS 16
> > +#define MAXPROPS 16
> > +#define MAXATTRS 8
> > +struct udev_device {
> > +	struct udev_device *parent;
> > +	char syspath[NAME_MAX];
> > +	char devnode[NAME_MAX];
> > +	char subsystem[8];
> > +	struct keyval prop[MAXPROPS];
> > +	struct udev_list_entry *prop_head;
> > +	struct keyval attr[MAXATTRS];
> > +	struct udev_list_entry *attr_head;
> > +	int props;
> > +	int attrs;
> > +};
> > +
> > +struct udev {
> > +	struct udev_device *dev[MAXDEVS];
> > +} _udev;
> > +
> > +struct udev_enumerate {
> > +	struct udev *udev;
> > +} _udev_enumerate;
> > +
> > +static void print_udev_device(const struct udev_device *dev)
> > +{
> > +//#define DEBUG_SCAN_SIMULATE

Unfortunatelly // left in series sent.

> > +#ifdef DEBUG_SCAN_SIMULATE
> 
> Isn't this a little too redundand ? You already have this code
> included only when user defines name in other file, so maybe
> here just use igt_debug() and drop this ifdef/endif ?

My intention is to have this disabled on production code. Even with
SIMULATE_UDEV_DEVICES I want to have this disabled from default.

I won't insist to merge this patch. I use this to verify device scan
functions works I expect. This is far away from being perfect (I think
to provide devices template from files, not from the code) so I may
drop it. Code I want to merge was already reviewed so this one may be
send in the future with better shape. 

> 
> > +	int i;
> > +
> > +	printf("[%s]\n", dev->syspath);
> > +
> > +	printf("props:\n");
> > +	for (i = 0; i < dev->props; i++)
> > +		printf("   %s: %s\n", dev->prop[i].key, dev->prop[i].val);
> > +
> > +	printf("attrs:\n");
> > +	for (i = 0; i < dev->attrs; i++)
> > +		printf("   %s: %s\n", dev->attr[i].key, dev->attr[i].val);
> > +#endif
> > +}
> > +
> > +#define __ADD_PROP(_dev, _key, args...) do { \
> --------------------- ^
> You use some global vars with underscore, so maybe here use
> longer names without '_' ? For example prop_dev, prop_key or
> add_dev, add_key ? Or use double underscore '__' ?

I don't want to clash do double __ looks good for me. 

> 
> > +	struct keyval *kv; \
> > +	igt_assert(dev->props <= MAXPROPS); \
> ------------------ ^
> Here and below in second macro you should use _dev.

You're right. Thanks for spotting this.

> 
> > +	kv = &(dev)->prop[(dev)->props]; \
> 
> Same here.
> 
> > +	strncpy(kv->key, (_key), NAME_MAX); \
> > +	snprintf(kv->val, NAME_MAX, args); \
> > +	(dev)->props++; \
> 
> Same here.
> 
> > +	} while (0)
> > +
> > +#define __ADD_ATTR(_dev, _key, args...) do { \
> 
> Same note about names used in macro.
> 
> > +	struct keyval *kv; \
> > +	igt_assert(dev->attrs <= MAXATTRS); \
> 
> Same here.
> 
> > +	kv = &(dev)->attr[(dev)->attrs]; \
> 
> Same here.
> 
> > +	strncpy(kv->key, (_key), NAME_MAX); \
> > +	snprintf(kv->val, NAME_MAX, args); \
> > +	(dev)->attrs++; \
> 
> Same here.
> 
> > +	} while (0)
> > +
> > +static struct udev_device *
> > +create_pci_udev_device(struct udev *udev,
> > +		       const char *syspath, const char *bdf,
> > +		       uint16_t vendor, uint16_t device, uint16_t subsystem)
> > +{
> > +	struct udev_device *dev;
> > +	char bus[13];
> > +
> > +	igt_assert(strlen(bdf) == 12);
> > +
> > +	dev = calloc(1, sizeof(*dev));
> > +	igt_assert(dev);
> > +
> > +	dev->parent = dev;
> > +	snprintf(dev->syspath, NAME_MAX, "%s", syspath);
> > +	strncpy(dev->subsystem, "pci", 4);
> > +
> > +	/* avoid compiler warning when copying less than 12 */
> > +	strncpy(bus, bdf, 13);
> > +	bus[7] = '\0';
> > +
> > +	__ADD_PROP(dev, "DEVPATH", "/devices/pci%s/%s", bus, bdf);
> > +	__ADD_PROP(dev, "DRIVER", "i915");
> > +	__ADD_PROP(dev, "PCI_CLASS", "30000");
> > +	__ADD_PROP(dev, "PCI_ID", "%04x:%04x", vendor, device);
> > +	__ADD_PROP(dev, "PCI_SLOT_NAME", "%s", bdf);
> > +	__ADD_PROP(dev, "PCI_SUBSYS_ID", "%04x:%04x", vendor, subsystem);
> > +	__ADD_PROP(dev, "SUBSYSTEM", "pci");
> > +
> > +	__ADD_ATTR(dev, "class", "0x030000");
> > +	__ADD_ATTR(dev, "device", "0x%04x", device);
> > +	__ADD_ATTR(dev, "subsystem", "pci");
> > +	__ADD_ATTR(dev, "subsystem_device", "0x%04x", subsystem);
> > +	__ADD_ATTR(dev, "subsystem_vendor", "0x%04x", vendor);
> > +	__ADD_ATTR(dev, "vendor", "0x%04x", vendor);
> > +
> > +	return dev;
> > +}
> > +
> > +static struct udev_device *
> > +create_drm_udev_device(struct udev *udev, struct udev_device *parent,
> > +		       const char *syspath, const char *bdf, int card,
> > +		       int major, int minor)
> > +{
> > +	struct udev_device *dev;
> > +	const char *name = card < 128 ? "card" : "render";
> > +	const char *drmname = card < 128 ? "card" : "renderD";
> > +	char bus[13];
> > +
> > +	igt_assert(strlen(bdf) == 12);
> > +
> > +	dev = calloc(1, sizeof(*dev));
> > +	igt_assert(dev);
> > +
> > +	dev->parent = parent;
> > +	snprintf(dev->syspath, NAME_MAX, "%s", syspath);
> > +	strncpy(dev->subsystem, "drm", 4);
> > +	snprintf(dev->devnode, NAME_MAX, "/dev/dri/%s%d", drmname, card);
> > +
> > +	/* avoid compiler warning when copying less than 12 */
> > +	strncpy(bus, bdf, 13);
> > +	bus[7] = '\0';
> > +
> > +	__ADD_PROP(dev, "DEVLINKS", "/dev/dri/by-path/pci-%s-%s", bdf, name);
> > +	__ADD_PROP(dev, "DEVNAME", "/dev/dri/%s%d", drmname, card);
> > +	__ADD_PROP(dev, "DEVPATH", "/devices/pci%s/%s/drm/%s%d", bus, bdf,
> > +		   drmname, card);
> > +	__ADD_PROP(dev, "DEVTYPE", "drm_minor");
> > +	__ADD_PROP(dev, "ID_PATH", "pci-%s", bdf);
> > +	__ADD_PROP(dev, "MAJOR", "%d", major);
> > +	__ADD_PROP(dev, "MINOR", "%d", minor);
> > +	__ADD_PROP(dev, "SUBSYSTEM", "drm");
> > +
> > +	__ADD_ATTR(dev, "dev", "%d:%d", major, minor);
> > +	__ADD_ATTR(dev, "subsystem", "drm");
> > +
> > +	return dev;
> > +}
> > +
> > +static struct udev_device **add_intel_dev(struct udev *udev, struct udev_device **dev,
> > +					  const char *pci_slot, uint16_t pci_device)
> > +{
> > +	struct udev_device **parent;
> > +	char bd[13], path[NAME_MAX];
> > +	static int card;
> > +
> > +	strncpy(bd, pci_slot, 13);
> > +	bd[7] = 0;
> > +
> > +	parent = dev;
> > +
> > +	snprintf(path, NAME_MAX, "/sys/devices/pci%s/%s", bd, pci_slot);
> > +	*dev++ = create_pci_udev_device(udev, path, pci_slot,
> > +					0x8086, pci_device, 0x2063);
> > +
> > +	snprintf(path, NAME_MAX, "/sys/devices/pci%s/%s/drm/card%d",
> > +		 bd, pci_slot, card);
> > +	*dev++ = create_drm_udev_device(udev, *parent, path, pci_slot,
> > +					card, 226, card);
> > +
> > +	snprintf(path, NAME_MAX, "/sys/devices/pci%s/%s/drm/renderD%d",
> > +		 bd, pci_slot, card + 128);
> > +	*dev++ = create_drm_udev_device(udev, *parent, path, pci_slot,
> > +					card + 128, 226, card + 128);
> > +
> > +	card++;
> > +
> > +	return dev;
> > +}
> > +
> > +struct udev *udev_new(void)
> > +{
> > +	struct udev *udev = &_udev;
> > +	struct udev_device **dev = udev->dev;
> > +
> > +	memset(dev, 0, sizeof(_udev.dev));
> > +
> > +	dev = add_intel_dev(udev, dev, "0000:00:02.0", 0x1926); /* skl */
> > +	dev = add_intel_dev(udev, dev, "0000:01:00.0", 0x56a1); /* dg2 */
> > +	dev = add_intel_dev(udev, dev, "0000:02:02.1", 0x9a40); /* tgl */
> > +	dev = add_intel_dev(udev, dev, "0000:03:01.0", 0x56a0); /* dg2 */
> > +	dev = add_intel_dev(udev, dev, "0000:04:02.0", 0x56a2); /* dg2 */
> > +
> > +	dev = udev->dev;
> > +	while (*dev)
> > +		print_udev_device(*dev++);
> > +
> > +	return &_udev;
> > +}
> > +
> > +struct udev_enumerate *udev_enumerate_new(struct udev *udev)
> > +{
> > +	_udev_enumerate.udev = udev;
> > +
> > +	return &_udev_enumerate;
> > +}
> > +
> > +int udev_enumerate_add_match_subsystem(struct udev_enumerate *udev_enumerate,
> > +				       const char *subsystem)
> > +{
> > +	return 0;
> > +}
> > +
> > +int udev_enumerate_add_match_property(struct udev_enumerate *udev_enumerate,
> > +				      const char *property, const char *value)
> > +{
> > +	return 0;
> > +}
> > +
> > +int udev_enumerate_scan_devices(struct udev_enumerate *udev_enumerate)
> > +{
> > +	return 0;
> > +}
> > +
> > +struct udev_list_entry *
> > +udev_enumerate_get_list_entry(struct udev_enumerate *udev_enumerate)
> > +{
> > +
> 
> Remove empty line.

Ack, thanks for the review. I will fix and resend.

--
Zbigniew

> 
> Regards,
> Kamil
> 
> > +	_entry_dev.entry_type = TYPE_DEVICE;
> > +	_entry_dev.curr = 0;
> > +
> > +	return &_entry_dev;
> > +}
> > +
> > +struct udev_list_entry *
> > +udev_list_entry_get_next(struct udev_list_entry *list_entry)
> > +{
> > +	int curr, currdev = _entry_dev.curr;
> > +
> > +	switch (list_entry->entry_type) {
> > +	case TYPE_DEVICE:
> > +		if (_udev.dev[++list_entry->curr])
> > +			return list_entry;
> > +		break;
> > +	case TYPE_PROP:
> > +		curr = ++list_entry->curr;
> > +		if (curr < _udev.dev[currdev]->props)
> > +			return list_entry;
> > +		break;
> > +	case TYPE_ATTR:
> > +		curr = ++list_entry->curr;
> > +		if (curr < _udev.dev[currdev]->attrs)
> > +			return list_entry;
> > +		break;
> > +	}
> > +
> > +	return NULL;
> > +}
> > +
> > +const char *udev_list_entry_get_name(struct udev_list_entry *list_entry)
> > +{
> > +	int curr, currdev = _entry_dev.curr;
> > +
> > +	switch (list_entry->entry_type) {
> > +	case TYPE_DEVICE:
> > +		return _udev.dev[list_entry->curr]->syspath;
> > +	case TYPE_PROP:
> > +		curr = _entry_prop.curr;
> > +		return _udev.dev[currdev]->prop[curr].key;
> > +	case TYPE_ATTR:
> > +		curr = _entry_attr.curr;
> > +		return _udev.dev[currdev]->attr[curr].key;
> > +	}
> > +
> > +	return "UNKNOWN";
> > +}
> > +
> > +const char *udev_list_entry_get_value(struct udev_list_entry *list_entry)
> > +{
> > +	int curr, currdev = _entry_dev.curr;
> > +
> > +	switch (list_entry->entry_type) {
> > +	case TYPE_DEVICE:
> > +		return "";
> > +	case TYPE_PROP:
> > +		curr = _entry_prop.curr;
> > +		return _udev.dev[currdev]->prop[curr].val;
> > +	case TYPE_ATTR:
> > +		curr = _entry_attr.curr;
> > +		return _udev.dev[currdev]->attr[curr].val;
> > +	}
> > +
> > +	return "UNKNOWN";
> > +}
> > +
> > +struct udev_device *udev_device_new_from_syspath(struct udev *udev,
> > +						 const char *syspath)
> > +{
> > +	int i;
> > +
> > +	for (i = 0; i < sizeof(udev->dev); i++) {
> > +		if (!udev->dev[i])
> > +			return NULL;
> > +
> > +		if (strcmp(udev->dev[i]->syspath, syspath) == 0)
> > +			return udev->dev[i];
> > +	}
> > +
> > +	return NULL;
> > +}
> > +
> > +const char *udev_device_get_subsystem(struct udev_device *udev_device)
> > +{
> > +	return udev_device->subsystem;
> > +}
> > +
> > +const char *udev_device_get_syspath(struct udev_device *udev_device)
> > +{
> > +	return udev_device->syspath;
> > +}
> > +
> > +const char *udev_device_get_devnode(struct udev_device *udev_device)
> > +{
> > +	if (udev_device->devnode[0] == '\0')
> > +		return NULL;
> > +
> > +	return udev_device->devnode;
> > +}
> > +
> > +struct udev_list_entry *
> > +udev_device_get_properties_list_entry(struct udev_device *udev_device)
> > +{
> > +	_entry_prop.entry_type = TYPE_PROP;
> > +	_entry_prop.curr = 0;
> > +
> > +	return &_entry_prop;
> > +}
> > +
> > +struct udev_list_entry *
> > +udev_device_get_sysattr_list_entry(struct udev_device *udev_device)
> > +{
> > +	_entry_attr.entry_type = TYPE_ATTR;
> > +	_entry_attr.curr = 0;
> > +
> > +	return &_entry_attr;
> > +}
> > +
> > +const char *
> > +udev_device_get_sysattr_value(struct udev_device *udev_device, const char *sysattr)
> > +{
> > +	for (int i = 0; i < udev_device->attrs; i++)
> > +		if (strcmp(udev_device->attr[i].key, sysattr) == 0)
> > +			return udev_device->attr[i].val;
> > +
> > +	return "UNKNOWN";
> > +}
> > +
> > +const char *udev_device_get_sysname(struct udev_device *udev_device)
> > +{
> > +	return udev_device->syspath;
> > +}
> > +
> > +struct udev_device *udev_device_get_parent(struct udev_device *udev_device)
> > +{
> > +	return udev_device->parent;
> > +}
> > +
> > +struct udev_enumerate *udev_enumerate_unref(struct udev_enumerate *udev_enumerate)
> > +{
> > +	return NULL;
> > +}
> > +
> > +struct udev_device *udev_device_unref(struct udev_device *udev_device)
> > +{
> > +	return NULL;
> > +}
> > -- 
> > 2.34.1
> > 

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2022-07-18  6:46 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-14  4:17 [igt-dev] [PATCH i-g-t v3 0/6] Add codename in device selection Zbigniew Kempczyński
2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 1/6] lib/igt_device_scan: Migrate pci assignment Zbigniew Kempczyński
2022-07-15 16:54   ` Kamil Konieczny
2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 2/6] lib/igt_device_scan: Introduce codename for platform selection Zbigniew Kempczyński
2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 3/6] tools/lsgpu: Add codename switch (-c) Zbigniew Kempczyński
2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 4/6] lib/igt_device_scan: Align microseconds to six leading zeros Zbigniew Kempczyński
2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 5/6] lib/igt_device_scan: Add discrete/integrated pseudo-codenames Zbigniew Kempczyński
2022-07-14  4:17 ` [igt-dev] [PATCH i-g-t v3 6/6] lib/igt_device_scan: Simulate udev drm and pci device events Zbigniew Kempczyński
2022-07-15 16:52   ` Kamil Konieczny
2022-07-18  6:46     ` Zbigniew Kempczyński
2022-07-14  4:55 ` [igt-dev] ✓ Fi.CI.BAT: success for Add codename in device selection (rev3) Patchwork
2022-07-14  7:39 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.