Resolves Inconsistent HWDRM Error Codes From AMD GPUs [chromium/src : main]

0 views
Skip to first unread message

Dale Curtis (Gerrit)

unread,
Aug 26, 2025, 7:18:49 PM (11 days ago) Aug 26
to Tochukwu Ibe-Ekeocha, Sangbaek Park, chromium...@chromium.org, feature-me...@chromium.org
Attention needed from Sangbaek Park, Tochukwu Ibe-Ekeocha and Xiaohan Wang

Dale Curtis voted and added 1 comment

Votes added by Dale Curtis

Code-Review+1

1 comment

File media/renderers/win/media_foundation_renderer.cc
Line 1267, Patchset 1 (Latest): gpu::GPUInfo gpu_info;
Dale Curtis . unresolved

This may be expensive to collect?

Open in Gerrit

Related details

Attention is currently required from:
  • Sangbaek Park
  • Tochukwu Ibe-Ekeocha
  • Xiaohan Wang
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Ib8c8694837659579d3c495d8ad4e9676767e3ce4
Gerrit-Change-Number: 6885895
Gerrit-PatchSet: 1
Gerrit-Owner: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
Gerrit-Reviewer: Dale Curtis <dalec...@chromium.org>
Gerrit-Reviewer: Sangbaek Park <sangba...@chromium.org>
Gerrit-Reviewer: Xiaohan Wang <xhw...@chromium.org>
Gerrit-Attention: Xiaohan Wang <xhw...@chromium.org>
Gerrit-Attention: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
Gerrit-Attention: Sangbaek Park <sangba...@chromium.org>
Gerrit-Comment-Date: Tue, 26 Aug 2025 23:18:26 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
satisfied_requirement
unsatisfied_requirement
open
diffy

Xiaohan Wang (Gerrit)

unread,
Aug 26, 2025, 7:32:46 PM (11 days ago) Aug 26
to Tochukwu Ibe-Ekeocha, Dale Curtis, Sangbaek Park, chromium...@chromium.org, feature-me...@chromium.org
Attention needed from Sangbaek Park and Tochukwu Ibe-Ekeocha

Xiaohan Wang added 1 comment

Patchset-level comments
File-level comment, Patchset 1 (Latest):
Xiaohan Wang . resolved

I'll defer to @sangba...@chromium.org for the review.

Open in Gerrit

Related details

Attention is currently required from:
  • Sangbaek Park
  • Tochukwu Ibe-Ekeocha
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Ib8c8694837659579d3c495d8ad4e9676767e3ce4
Gerrit-Change-Number: 6885895
Gerrit-PatchSet: 1
Gerrit-Owner: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
Gerrit-Reviewer: Dale Curtis <dalec...@chromium.org>
Gerrit-Reviewer: Sangbaek Park <sangba...@chromium.org>
Gerrit-Reviewer: Xiaohan Wang <xhw...@chromium.org>
Gerrit-Attention: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
Gerrit-Attention: Sangbaek Park <sangba...@chromium.org>
Gerrit-Comment-Date: Tue, 26 Aug 2025 23:32:34 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Sangbaek Park (Gerrit)

unread,
Aug 27, 2025, 2:20:00 PM (11 days ago) Aug 27
to Tochukwu Ibe-Ekeocha, Dale Curtis, chromium...@chromium.org, feature-me...@chromium.org
Attention needed from Tochukwu Ibe-Ekeocha

Sangbaek Park added 1 comment

File media/renderers/win/media_foundation_renderer.cc
Line 1267, Patchset 1 (Latest): gpu::GPUInfo gpu_info;
Dale Curtis . unresolved

This may be expensive to collect?

Sangbaek Park

Maybe this saves some?
```
#include "content/public/browser/gpu_data_manager.h"
const gpu::GPUInfo& gpu_info = content::GpuDataManager::GetInstance()->GetGPUInfo();
```

Open in Gerrit

Related details

Attention is currently required from:
  • Tochukwu Ibe-Ekeocha
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Ib8c8694837659579d3c495d8ad4e9676767e3ce4
Gerrit-Change-Number: 6885895
Gerrit-PatchSet: 1
Gerrit-Owner: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
Gerrit-Reviewer: Dale Curtis <dalec...@chromium.org>
Gerrit-Reviewer: Sangbaek Park <sangba...@chromium.org>
Gerrit-Reviewer: Xiaohan Wang <xhw...@chromium.org>
Gerrit-Attention: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
Gerrit-Comment-Date: Wed, 27 Aug 2025 18:19:46 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Dale Curtis <dalec...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Tochukwu Ibe-Ekeocha (Gerrit)

unread,
Sep 3, 2025, 1:18:51 PM (4 days ago) Sep 3
to Dale Curtis, Sangbaek Park, chromium...@chromium.org, feature-me...@chromium.org
Attention needed from Dale Curtis and Sangbaek Park

Tochukwu Ibe-Ekeocha added 1 comment

File media/renderers/win/media_foundation_renderer.cc
Line 1267, Patchset 1: gpu::GPUInfo gpu_info;
Dale Curtis . resolved

This may be expensive to collect?

Sangbaek Park

Maybe this saves some?
```
#include "content/public/browser/gpu_data_manager.h"
const gpu::GPUInfo& gpu_info = content::GpuDataManager::GetInstance()->GetGPUInfo();
```

Tochukwu Ibe-Ekeocha

Looks like in order to use GpuDataManager I would need to add a dependency on the `/content` layer into `/media`. Currently no such dependency exists. After testing `gpu::CollectBasicGraphicsInfo` a couple times using `TimeDelta`, it seems to be taking `<= ~4ms` to get the info. Keeping in mind that this only runs when we are in an error state, do you think this cost outweighs is significant enough to consinder adding the `/content` layer as a dependency to `/media`?

Open in Gerrit

Related details

Attention is currently required from:
  • Dale Curtis
  • Sangbaek Park
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Ib8c8694837659579d3c495d8ad4e9676767e3ce4
Gerrit-Change-Number: 6885895
Gerrit-PatchSet: 5
Gerrit-Owner: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
Gerrit-Reviewer: Dale Curtis <dalec...@chromium.org>
Gerrit-Reviewer: Sangbaek Park <sangba...@chromium.org>
Gerrit-Reviewer: Xiaohan Wang <xhw...@chromium.org>
Gerrit-Attention: Dale Curtis <dalec...@chromium.org>
Gerrit-Attention: Sangbaek Park <sangba...@chromium.org>
Gerrit-Comment-Date: Wed, 03 Sep 2025 17:18:39 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Dale Curtis <dalec...@chromium.org>
Comment-In-Reply-To: Sangbaek Park <sangba...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Dale Curtis (Gerrit)

unread,
Sep 3, 2025, 2:30:33 PM (4 days ago) Sep 3
to Tochukwu Ibe-Ekeocha, Sangbaek Park, chromium...@chromium.org, feature-me...@chromium.org
Attention needed from Sangbaek Park and Tochukwu Ibe-Ekeocha

Dale Curtis added 3 comments

File media/renderers/win/media_foundation_renderer.cc
Line 121, Patchset 5 (Latest): if (!d3d11_device) {
Dale Curtis . unresolved

DCHECK instead since you check it below.

Line 1267, Patchset 1: gpu::GPUInfo gpu_info;
Dale Curtis . resolved

This may be expensive to collect?

Sangbaek Park

Maybe this saves some?
```
#include "content/public/browser/gpu_data_manager.h"
const gpu::GPUInfo& gpu_info = content::GpuDataManager::GetInstance()->GetGPUInfo();
```

Tochukwu Ibe-Ekeocha

Looks like in order to use GpuDataManager I would need to add a dependency on the `/content` layer into `/media`. Currently no such dependency exists. After testing `gpu::CollectBasicGraphicsInfo` a couple times using `TimeDelta`, it seems to be taking `<= ~4ms` to get the info. Keeping in mind that this only runs when we are in an error state, do you think this cost outweighs is significant enough to consinder adding the `/content` layer as a dependency to `/media`?

Dale Curtis

//media can't depend on //content since that'd be a layering violation.

Line 1297, Patchset 5 (Latest): if (d3d11_device) {
Dale Curtis . unresolved

Have you seen this fail? The impl in CollectBasicGraphicsInfo() looks similar, so I'd assume it would fail the same way if this does.

Open in Gerrit

Related details

Attention is currently required from:
  • Sangbaek Park
  • Tochukwu Ibe-Ekeocha
Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ib8c8694837659579d3c495d8ad4e9676767e3ce4
    Gerrit-Change-Number: 6885895
    Gerrit-PatchSet: 5
    Gerrit-Owner: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
    Gerrit-Reviewer: Dale Curtis <dalec...@chromium.org>
    Gerrit-Reviewer: Sangbaek Park <sangba...@chromium.org>
    Gerrit-Reviewer: Xiaohan Wang <xhw...@chromium.org>
    Gerrit-Attention: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
    Gerrit-Attention: Sangbaek Park <sangba...@chromium.org>
    Gerrit-Comment-Date: Wed, 03 Sep 2025 18:30:24 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Dale Curtis <dalec...@chromium.org>
    Comment-In-Reply-To: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
    Comment-In-Reply-To: Sangbaek Park <sangba...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Tochukwu Ibe-Ekeocha (Gerrit)

    unread,
    Sep 4, 2025, 8:56:45 PM (2 days ago) Sep 4
    to Dale Curtis, Sangbaek Park, chromium...@chromium.org, feature-me...@chromium.org
    Attention needed from Dale Curtis and Sangbaek Park

    Tochukwu Ibe-Ekeocha added 1 comment

    File media/renderers/win/media_foundation_renderer.cc
    Dale Curtis . unresolved

    Have you seen this fail? The impl in CollectBasicGraphicsInfo() looks similar, so I'd assume it would fail the same way if this does.

    Tochukwu Ibe-Ekeocha

    The idea of using CollectBasicGraphicsInfo as a fall back is to try and account for any cases where the dxgi_device_manager_ may not be properly initialized when `MediaFoundationRenderer::OnError` is called like if this error occurs during initialization or audio-only playback. Not 100% sure that these are valid edge cases, but I figured better safe than sorry.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Dale Curtis
    • Sangbaek Park
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ib8c8694837659579d3c495d8ad4e9676767e3ce4
    Gerrit-Change-Number: 6885895
    Gerrit-PatchSet: 5
    Gerrit-Owner: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
    Gerrit-Reviewer: Dale Curtis <dalec...@chromium.org>
    Gerrit-Reviewer: Sangbaek Park <sangba...@chromium.org>
    Gerrit-Reviewer: Xiaohan Wang <xhw...@chromium.org>
    Gerrit-Attention: Dale Curtis <dalec...@chromium.org>
    Gerrit-Attention: Sangbaek Park <sangba...@chromium.org>
    Gerrit-Comment-Date: Fri, 05 Sep 2025 00:56:35 +0000
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Tochukwu Ibe-Ekeocha (Gerrit)

    unread,
    Sep 4, 2025, 9:02:39 PM (2 days ago) Sep 4
    to Dale Curtis, Sangbaek Park, chromium...@chromium.org, feature-me...@chromium.org
    Attention needed from Dale Curtis and Sangbaek Park

    Tochukwu Ibe-Ekeocha added 1 comment

    File media/renderers/win/media_foundation_renderer.cc
    Line 121, Patchset 5: if (!d3d11_device) {
    Dale Curtis . resolved

    DCHECK instead since you check it below.

    Tochukwu Ibe-Ekeocha

    changed

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Dale Curtis
    • Sangbaek Park
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ib8c8694837659579d3c495d8ad4e9676767e3ce4
    Gerrit-Change-Number: 6885895
    Gerrit-PatchSet: 6
    Gerrit-Owner: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
    Gerrit-Reviewer: Dale Curtis <dalec...@chromium.org>
    Gerrit-Reviewer: Sangbaek Park <sangba...@chromium.org>
    Gerrit-Reviewer: Xiaohan Wang <xhw...@chromium.org>
    Gerrit-Attention: Dale Curtis <dalec...@chromium.org>
    Gerrit-Attention: Sangbaek Park <sangba...@chromium.org>
    Gerrit-Comment-Date: Fri, 05 Sep 2025 01:02:30 +0000
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Dale Curtis (Gerrit)

    unread,
    Sep 5, 2025, 1:08:21 PM (2 days ago) Sep 5
    to Tochukwu Ibe-Ekeocha, Sangbaek Park, chromium...@chromium.org, feature-me...@chromium.org
    Attention needed from Sangbaek Park and Tochukwu Ibe-Ekeocha

    Dale Curtis added 2 comments

    File media/renderers/win/media_foundation_renderer.cc
    Line 52, Patchset 6 (Latest):constexpr uint32_t KAmdVendorId = 0x1002;
    Dale Curtis . unresolved

    `kAmdVendorId`

    Line 1297, Patchset 5: if (d3d11_device) {
    Dale Curtis . unresolved

    Have you seen this fail? The impl in CollectBasicGraphicsInfo() looks similar, so I'd assume it would fail the same way if this does.

    Tochukwu Ibe-Ekeocha

    The idea of using CollectBasicGraphicsInfo as a fall back is to try and account for any cases where the dxgi_device_manager_ may not be properly initialized when `MediaFoundationRenderer::OnError` is called like if this error occurs during initialization or audio-only playback. Not 100% sure that these are valid edge cases, but I figured better safe than sorry.

    Dale Curtis

    Is it possible to get this display related error code during audio only playback?

    If so this seems fine, I just meant CollectBasicGraphicsInfo() basically does what GetVendorIdFromD3D11Device() does in terms of asking the DXGI device, so if GetVendorIdFromD3D11Device() fails or a DXGI device is in a bad state, I'm not sure it'll work any better.

    I'd probably just ignore this case for now unless you really think it can happen, but defer to your expertise.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Sangbaek Park
    • Tochukwu Ibe-Ekeocha
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ib8c8694837659579d3c495d8ad4e9676767e3ce4
    Gerrit-Change-Number: 6885895
    Gerrit-PatchSet: 6
    Gerrit-Owner: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
    Gerrit-Reviewer: Dale Curtis <dalec...@chromium.org>
    Gerrit-Reviewer: Sangbaek Park <sangba...@chromium.org>
    Gerrit-Reviewer: Xiaohan Wang <xhw...@chromium.org>
    Gerrit-Attention: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
    Gerrit-Attention: Sangbaek Park <sangba...@chromium.org>
    Gerrit-Comment-Date: Fri, 05 Sep 2025 17:08:11 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Dale Curtis <dalec...@chromium.org>
    Comment-In-Reply-To: Tochukwu Ibe-Ekeocha <tibee...@microsoft.com>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy
    Reply all
    Reply to author
    Forward
    0 new messages