All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t 1/2] lib/amdgpu: add oversized invalid packet length error handling
@ 2026-04-08  2:47 Jesse Zhang
  2026-04-08  2:47 ` [PATCH i-g-t 2/2] tests/amdgpu: add string mapping for oversized packet length error Jesse Zhang
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Jesse Zhang @ 2026-04-08  2:47 UTC (permalink / raw)
  To: igt-dev; +Cc: Vitaly Prosyak, Alex Deucher, Christian Koenig, Jesse Zhang

Add a dedicated cmd error type for oversized packet length and handle
it in gfx_ring_bad_write_linear().

- add CMD_STREAM_EXEC_INVALID_PACKET_LENGTH_OVERSIZE to cmd_error_type
- in gfx_ring_bad_write_linear(), map this error to:
  stream_length = ring_context->write_length * 2
- keep existing invalid-short-length path unchanged

Signed-off-by: Jesse Zhang <Jesse.Zhang@amd.com>
---
 lib/amdgpu/amd_ip_blocks.c | 2 ++
 lib/amdgpu/amd_ip_blocks.h | 1 +
 2 files changed, 3 insertions(+)

diff --git a/lib/amdgpu/amd_ip_blocks.c b/lib/amdgpu/amd_ip_blocks.c
index f0376a3e7..80aa5569c 100644
--- a/lib/amdgpu/amd_ip_blocks.c
+++ b/lib/amdgpu/amd_ip_blocks.c
@@ -284,6 +284,8 @@ gfx_ring_bad_write_linear(const struct amdgpu_ip_funcs *func,
 	  */
 	if (cmd_error == CMD_STREAM_EXEC_INVALID_PACKET_LENGTH)
 		stream_length = ring_context->write_length / 16;
+	else if (cmd_error == CMD_STREAM_EXEC_INVALID_PACKET_LENGTH_OVERSIZE)
+		stream_length = ring_context->write_length * 2;
 	else
 		stream_length = ring_context->write_length;
 
diff --git a/lib/amdgpu/amd_ip_blocks.h b/lib/amdgpu/amd_ip_blocks.h
index 6bc8c3706..eb118c68a 100644
--- a/lib/amdgpu/amd_ip_blocks.h
+++ b/lib/amdgpu/amd_ip_blocks.h
@@ -146,6 +146,7 @@ enum  cmd_error_type {
 	CMD_STREAM_EXEC_SUCCESS,
 	CMD_STREAM_EXEC_INVALID_OPCODE,
 	CMD_STREAM_EXEC_INVALID_PACKET_LENGTH,
+	CMD_STREAM_EXEC_INVALID_PACKET_LENGTH_OVERSIZE,
 	CMD_STREAM_EXEC_INVALID_PACKET_EOP_QUEUE,
 	CMD_STREAM_TRANS_BAD_REG_ADDRESS,
 	CMD_STREAM_TRANS_BAD_MEM_ADDRESS,
-- 
2.49.0


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

end of thread, other threads:[~2026-04-09  7:48 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-08  2:47 [PATCH i-g-t 1/2] lib/amdgpu: add oversized invalid packet length error handling Jesse Zhang
2026-04-08  2:47 ` [PATCH i-g-t 2/2] tests/amdgpu: add string mapping for oversized packet length error Jesse Zhang
2026-04-08 22:46 ` [PATCH i-g-t 1/2] lib/amdgpu: add oversized invalid packet length error handling vitaly prosyak
2026-04-09  7:48 ` ✗ Fi.CI.BAT: failure for series starting with [i-g-t,1/2] " 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.