Skip to contentSkip to conversation

drm/amdgpu/mes_v12_1: initial support for mes_v12_1

PATCH New Alex Deucher 1 participant 2 messages Nov 24, 2025

Subsystems (2)
lore
Share & tools
lore

Alex Deucher

author maintainer
#0 lore raw

PATCH 1/2 drm/amdgpu/mes_v12_1: initial support for mes_v12_1

From: Jack Xiao <[email protected]>

Duplicated and rename mes ip version name to v12_1_0. Fix to access correct ring pipe by xcc_id. Fix to access correct instance registers by xcc_id. Fix to access correct index registers by grbm/xcc_id.

v2: rebase (Alex)

---
 drivers/gpu/drm/amd/amdgpu/Makefile    |    1 +
 drivers/gpu/drm/amd/amdgpu/mes_v12_1.c | 1760 ++++++++++++++++++++++++
 drivers/gpu/drm/amd/amdgpu/mes_v12_1.h |   29 +
 3 files changed, 1790 insertions(+)
 create mode 100644 drivers/gpu/drm/amd/amdgpu/mes_v12_1.c
 create mode 100644 drivers/gpu/drm/amd/amdgpu/mes_v12_1.h
drivers/gpu/drm/amd/amdgpu/Makefile +1 -0
index 139ceafa164a4..367f2da5f5100 100644
@@ -179,6 +179,7 @@ amdgpu-y += \
 	amdgpu_mes.o \
 	mes_v11_0.o \
 	mes_v12_0.o \
+	mes_v12_1.o
 
 # add GFX userqueue support
 amdgpu-y += mes_userqueue.o
drivers/gpu/drm/amd/amdgpu/mes_v12_1.c new file +1760 -0

1,760 lines not on this page · raw message

drivers/gpu/drm/amd/amdgpu/mes_v12_1.h new file +29 -0
new file mode 100644
index 0000000000000..cfc048f652b07
@@ -0,0 +1,29 @@
+/*
+ * Copyright 2025 Advanced Micro Devices, Inc.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the "Software"),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
+ * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
+ * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+ * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ *
+ */
+
+#ifndef __MES_V12_1_H__
+#define __MES_V12_1_H__
+
+extern const struct amdgpu_ip_block_version mes_v12_1_ip_block;
+
+#endif
Signature · 1 line
2.51.1
author maintainer
#1 lore raw

PATCH 2/2 drm/amdgpu: Add mes v12_1_0 to discovery list

From: Jack Xiao <[email protected]>

Include mes v12_1_0 in the discovery list for mes IP blocks.

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c | 8 ++++++++
 1 file changed, 8 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +8 -0
index c43509f95b89d..0b94a23d03b68 100644
@@ -99,6 +99,7 @@
 #include "amdgpu_vkms.h"
 #include "mes_v11_0.h"
 #include "mes_v12_0.h"
+#include "mes_v12_1.h"
 #include "smuio_v11_0.h"
 #include "smuio_v11_0_6.h"
 #include "smuio_v13_0.h"
@@ -2566,6 +2567,13 @@ static int amdgpu_discovery_set_mes_ip_blocks(struct amdgpu_device *adev)
 		if (amdgpu_uni_mes)
 			adev->enable_uni_mes = true;
 		break;
+	case IP_VERSION(12, 1, 0):
+		amdgpu_device_ip_block_add(adev, &mes_v12_1_ip_block);
+		adev->enable_mes = true;
+		adev->enable_mes_kiq = true;
+		if (amdgpu_uni_mes)
+			adev->enable_uni_mes = true;
+		break;
 	default:
 		break;
 	}
Signature · 1 line
2.51.1