[PATCH i-g-t v2] tests/intel/gem_exec_capture: Check for partial register captures
John.C.Harrison at Intel.com
John.C.Harrison at Intel.com
Thu Feb 29 19:55:21 UTC 2024
From: John Harrison <John.C.Harrison at Intel.com>
If there is an error in the register list provided to GuC by the KMD
then GuC will refuse to capture the invalid entries. This is reported
as a 'partial-capture' when decoding the register state. Check for
this and flag it as an error.
v2: Keep includes in alphabetical order (review feedback from Kamil).
Signed-off-by: John Harrison <John.C.Harrison at Intel.com>
Reviewed-by: Kamil Konieczny <kamil.konieczny at linux.intel.com>
---
tests/intel/gem_exec_capture.c | 16 +++++++++++++++-
1 file changed, 15 insertions(+), 1 deletion(-)
diff --git a/tests/intel/gem_exec_capture.c b/tests/intel/gem_exec_capture.c
index d231c53b98e1..065357f2589b 100644
--- a/tests/intel/gem_exec_capture.c
+++ b/tests/intel/gem_exec_capture.c
@@ -21,9 +21,10 @@
* IN THE SOFTWARE.
*/
+#include <ctype.h>
+#include <sched.h>
#include <sys/poll.h>
#include <zlib.h>
-#include <sched.h>
#include "i915/gem.h"
#include "i915/gem_create.h"
@@ -184,6 +185,19 @@ static int check_error_state(int dir, struct offset *obj_offsets, int obj_count,
igt_assert(errno != ENOMEM);
igt_debug("%.*s\n", error_dump_limit, error);
+ /*
+ * global --- GuC Error Capture on rcs0 command stream:
+ * Coverage: partial-capture
+ * Coverage: full-capture
+ */
+ for (str = error; (str = strstr(str, "Coverage: ")); ) {
+ str += 10;
+ while (isspace(*str))
+ str++;
+
+ igt_assert(strncmp(str, "full-capture", 12) == 0);
+ }
+
/* render ring --- user = 0x00000000 ffffd000 */
for (str = error; (str = strstr(str, "--- user = ")); ) {
uint32_t *data = NULL;
--
2.43.0
More information about the igt-dev
mailing list