Commit a53da2fb authored by John Harrison's avatar John Harrison Committed by Thomas Hellström
Browse files

drm/xe: Revert some changes that break a mesa debug tool



There is a mesa debug tool for decoding devcoredump files. Recent
changes to improve the devcoredump output broke that tool. So revert
the changes until the tool can be extended to support the new fields.

Signed-off-by: default avatarJohn Harrison <John.C.Harrison@Intel.com>
Fixes: c28fd6c3 ("drm/xe/devcoredump: Improve section headings and add tile info")
Fixes: ec1455ce ("drm/xe/devcoredump: Add ASCII85 dump helper function")
Cc: John Harrison <John.C.Harrison@Intel.com>
Cc: Julia Filipchuk <julia.filipchuk@intel.com>
Cc: Lucas De Marchi <lucas.demarchi@intel.com>
Cc: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Cc: intel-xe@lists.freedesktop.org
Reviewed-by: default avatarJonathan Cavitt <jonathan.cavitt@intel.com>
Reviewed-by: default avatarJosé Roberto de Souza <jose.souza@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20241213172833.1733376-1-John.C.Harrison@Intel.com


Signed-off-by: default avatarRodrigo Vivi <rodrigo.vivi@intel.com>
(cherry picked from commit 70fb86a8)
Signed-off-by: default avatarThomas Hellström <thomas.hellstrom@linux.intel.com>
parent 4bbf9020
Loading
Loading
Loading
Loading
+14 −1
Original line number Diff line number Diff line
@@ -109,7 +109,11 @@ static ssize_t __xe_devcoredump_read(char *buffer, size_t count,
	drm_puts(&p, "\n**** GuC CT ****\n");
	xe_guc_ct_snapshot_print(ss->guc.ct, &p);

	drm_puts(&p, "\n**** Contexts ****\n");
	/*
	 * Don't add a new section header here because the mesa debug decoder
	 * tool expects the context information to be in the 'GuC CT' section.
	 */
	/* drm_puts(&p, "\n**** Contexts ****\n"); */
	xe_guc_exec_queue_snapshot_print(ss->ge, &p);

	drm_puts(&p, "\n**** Job ****\n");
@@ -363,6 +367,15 @@ void xe_print_blob_ascii85(struct drm_printer *p, const char *prefix,
	char buff[ASCII85_BUFSZ], *line_buff;
	size_t line_pos = 0;

	/*
	 * Splitting blobs across multiple lines is not compatible with the mesa
	 * debug decoder tool. Note that even dropping the explicit '\n' below
	 * doesn't help because the GuC log is so big some underlying implementation
	 * still splits the lines at 512K characters. So just bail completely for
	 * the moment.
	 */
	return;

#define DMESG_MAX_LINE_LEN	800
#define MIN_SPACE		(ASCII85_BUFSZ + 2)		/* 85 + "\n\0" */