<!DOCTYPE html><html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<p>Hi Alex,</p>
Thanks for the suggestion!<br>
What I am thinking is "<span style="white-space: pre-wrap">DRM_DEV_INFO" should not be the one we want - as it is more like a debug message.</span><br>
<blockquote> [drm:jpeg_v5_0_0_hw_init [amdgpu]] JPEG decode
initialized successfully.<br>
</blockquote>
<span style="white-space: pre-wrap">instead I prefer to use this format:</span><br>
<span style="white-space: pre-wrap"> "amdgpu 0000:43:00.0: amdgpu: </span><span style="white-space: pre-wrap">JPEG decode initialized successfully."</span><br>
<p><span style="white-space: pre-wrap"></span><span style="white-space: pre-wrap">but again I dislike it as well as there are 2 </span><span style="white-space: pre-wrap">"amdgpu"</span><span style="white-space: pre-wrap">s in the same message.</span></p>
<span style="white-space: pre-wrap">To make it consistent the "</span><span style="white-space: pre-wrap">DRM_INFO" is used everywhere in the amdgpu code.</span><br>
<span style="white-space: pre-wrap">only the following jpeg code uses DRM_DEV_INFO and one file for vcn. All other jpeg versions have already changed to </span><span style="white-space: pre-wrap">DRM_INFO.</span><br>
<blockquote><span style="white-space: pre-wrap"> grep -r DRM_DEV_INFO *</span><br>
<span style="white-space: pre-wrap"> amdgpu/jpeg_v4_0_3.c: DRM_DEV_INFO(adev->dev, "JPEG decode initialized successfully.\n");</span><br>
<span style="white-space: pre-wrap"> amdgpu/jpeg_v4_0_3.c: DRM_DEV_INFO(adev->dev, "JPEG decode is enabled in VM mode\n");</span><br>
<span style="white-space: pre-wrap"> amdgpu/vcn_v4_0_3.c: DRM_DEV_INFO(adev->dev, "VCN decode initialized successfully(under %s).\n",</span><br>
<span style="white-space: pre-wrap"> amdgpu/vcn_v4_0_3.c: DRM_DEV_INFO(adev->dev, "VCN decode is enabled in VM mode\n");</span><br>
<span style="white-space: pre-wrap"> amdgpu/jpeg_v4_0_5.c: DRM_DEV_INFO(adev->dev, "JPEG decode initialized successfully under DPG Mode");</span><br>
<span style="white-space: pre-wrap"> amdgpu/jpeg_v4_0_5.c: DRM_DEV_INFO(adev->dev, "JPEG%d decode is enabled in VM mode\n", i);</span><br>
<span style="white-space: pre-wrap"> amdgpu/jpeg_v5_0_0.c: DRM_DEV_INFO(adev->dev, "JPEG decode initialized successfully under DPG Mode");</span><br>
<span style="white-space: pre-wrap"> amdgpu/jpeg_v5_0_0.c: DRM_DEV_INFO(adev->dev, "JPEG%d decode is enabled in VM mode\n", i);</span><br>
<span style="white-space: pre-wrap"> amdgpu/jpeg_v4_0.c: DRM_DEV_INFO(adev->dev, "JPEG decode initialized successfully.\n");</span><br>
<span style="white-space: pre-wrap"> amdgpu/jpeg_v4_0.c: DRM_DEV_INFO(adev->dev, "JPEG decode is enabled in VM mode\n");</span><span style="white-space: pre-wrap"></span><br>
<span style="white-space: pre-wrap"></span><br>
</blockquote>
<div class="moz-cite-prefix">If the rest of code in amdgpu uses <span style="white-space: pre-wrap">DRM_INFO why should we make VCN and JPEG special?</span></div>
<div class="moz-cite-prefix"><span style="white-space: pre-wrap">
</span></div>
<div class="moz-cite-prefix"><span style="white-space: pre-wrap">To address the identification of which GPUs - we need to check the kernel message after each IP DISCOVERY.</span></div>
<div class="moz-cite-prefix"><span style="white-space: pre-wrap">I do not see a reason to mess them up.</span></div>
<div class="moz-cite-prefix"><span style="white-space: pre-wrap">
</span></div>
<div class="moz-cite-prefix"><span style="white-space: pre-wrap">Regards,</span></div>
<div class="moz-cite-prefix"><span style="white-space: pre-wrap">
</span></div>
<div class="moz-cite-prefix"><span style="white-space: pre-wrap">David
</span></div>
<div class="moz-cite-prefix">On 2024-05-09 16:59, Alex Deucher
wrote:<br>
</div>
<blockquote type="cite" cite="mid:CADnq5_MMDTkoAnj+174wu_X762FvUc27_7RkzU+KDLrCrO55pw@mail.gmail.com">
<pre class="moz-quote-pre" wrap="">On Thu, May 9, 2024 at 4:57 PM David (Ming Qiang) Wu <a class="moz-txt-link-rfc2396E" href="mailto:David.Wu3@amd.com"><David.Wu3@amd.com></a> wrote:
</pre>
<blockquote type="cite">
<pre class="moz-quote-pre" wrap="">
amdgpu jpeg kernel message is different than others such as vcn:
[drm:jpeg_v5_0_0_hw_init [amdgpu]] JPEG decode initialized successfully.
This patch is to make them consistent.
The message after the change is:
[drm] JPEG decode initialized successfully.
</pre>
</blockquote>
<pre class="moz-quote-pre" wrap="">
Please convert the others to DRM_DEV_INFO instead. Otherwise we can't
tell which GPUs these messages refer to on multi-GPU systems.
Alex
</pre>
<blockquote type="cite">
<pre class="moz-quote-pre" wrap="">
Signed-off-by: David (Ming Qiang) Wu <a class="moz-txt-link-rfc2396E" href="mailto:David.Wu3@amd.com"><David.Wu3@amd.com></a>
---
drivers/gpu/drm/amd/amdgpu/jpeg_v5_0_0.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/jpeg_v5_0_0.c b/drivers/gpu/drm/amd/amdgpu/jpeg_v5_0_0.c
index 64c856bfe0cb..4be0668ab97d 100644
--- a/drivers/gpu/drm/amd/amdgpu/jpeg_v5_0_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/jpeg_v5_0_0.c
@@ -145,7 +145,7 @@ static int jpeg_v5_0_0_hw_init(void *handle)
if (r)
return r;
- DRM_DEV_INFO(adev->dev, "JPEG decode initialized successfully.\n");
+ DRM_INFO("JPEG decode initialized successfully.\n");
return 0;
}
@@ -549,7 +549,7 @@ static const struct amdgpu_ring_funcs jpeg_v5_0_0_dec_ring_vm_funcs = {
static void jpeg_v5_0_0_set_dec_ring_funcs(struct amdgpu_device *adev)
{
adev->jpeg.inst->ring_dec->funcs = &jpeg_v5_0_0_dec_ring_vm_funcs;
- DRM_DEV_INFO(adev->dev, "JPEG decode is enabled in VM mode\n");
+ DRM_INFO("JPEG decode is enabled in VM mode\n");
}
static const struct amdgpu_irq_src_funcs jpeg_v5_0_0_irq_funcs = {
--
2.34.1
</pre>
</blockquote>
</blockquote>
</body>
</html>